android_kernel_xiaomi_sm8350/include/acpi
Lin Ming a5fe1a03f7 ACPICA: fix leak of acpi_os_validate_address
http://bugzilla.kernel.org/show_bug.cgi?id=13620

If the dynamic region is created and added to resource list over and over again,
it has the potential to be a memory leak by growing the list every time.

This patch fixes the memory leak, as below

1) add a new field "count" to struct acpi_res_list.

   When inserting, if the region(addr, len) is already in the resource
   list, we just increase "count", otherwise, the region is inserted
   with count=1.

   When deleting, the "count" is decreased, if it's decreased to 0,
   the region is deleted from the resource list.

   With "count", the region with same address and length can only be
   inserted to the resource list once, so prevent potential memory leak.

2) add a new function acpi_os_invalidate_address, which is called when
   region is deleted.

Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
2009-08-27 13:10:35 -04:00
..
platform ACPICA: Linux OSL: cleanup/update/merge 2009-05-27 00:30:50 -04:00
acexcep.h ACPICA: Fix parameter validation for acpi_read/write 2009-03-26 16:38:25 -04:00
acnames.h
acoutput.h ACPICA: Restructure includes into public/private 2008-12-31 01:15:40 -05:00
acpi_bus.h Merge branch 'bjorn-notify' into release 2009-06-24 01:22:20 -04:00
acpi_drivers.h Merge branches 'acerhdf', 'acpi-pci-bind', 'bjorn-pci-root', 'bugzilla-12904', 'bugzilla-13121', 'bugzilla-13396', 'bugzilla-13533', 'bugzilla-13612', 'c3_lock', 'hid-cleanups', 'misc-2.6.31', 'pdc-leak-fix', 'pnpacpi', 'power_nocheck', 'thinkpad_acpi', 'video' and 'wmi' into release 2009-06-24 01:19:50 -04:00
acpi_numa.h
acpi.h ACPICA: Restructure includes into public/private 2008-12-31 01:15:40 -05:00
acpiosxf.h ACPICA: fix leak of acpi_os_validate_address 2009-08-27 13:10:35 -04:00
acpixf.h ACPICA: Update version to 20090521. 2009-05-27 00:41:34 -04:00
acrestyp.h ACPICA: Restructure includes into public/private 2008-12-31 01:15:40 -05:00
actbl1.h ACPI: update x2apic comments 2009-04-03 20:10:26 -04:00
actbl.h ACPICA: Update FADT flag definitions 2009-03-26 16:38:21 -04:00
actypes.h ACPICA: Cleanup byte/word/dword extraction macros, fix possible warnings 2009-05-27 00:30:49 -04:00
container.h
pdc_intel.h ACPI: Enable bit 11 in _PDC to advertise hw coord 2009-02-07 00:41:14 -05:00
processor.h ACPI: pdc init related memory leak with physical CPU hotplug 2009-06-20 00:50:52 -04:00
reboot.h
video.h ACPI: Add the reference count to avoid unloading ACPI video bus twice 2009-06-23 23:38:41 -04:00