android_kernel_xiaomi_sdm845/include/acpi
Andy Shevchenko e5cdbe4190 ACPI: scan: Use unique number for instance_no
[ Upstream commit eb50aaf960e3bedfef79063411ffd670da94b84b ]

The decrementation of acpi_device_bus_id->instance_no
in acpi_device_del() is incorrect, because it may cause
a duplicate instance number to be allocated next time
a device with the same acpi_device_bus_id is added.

Replace above mentioned approach by using IDA framework.

While at it, define the instance range to be [0, 4096).

Fixes: e49bd2dd5a ("ACPI: use PNPID:instance_no as bus_id of ACPI device")
Fixes: ca9dc8d42b ("ACPI / scan: Fix acpi_bus_id_list bookkeeping")
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: 4.10+ <stable@vger.kernel.org> # 4.10+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-03-30 14:41:41 +02:00
..
platform
acbuffer.h
acconfig.h ACPICA: Reference Counts: increase max to 0x4000 for large servers 2019-03-19 13:14:07 +01:00
acexcep.h
acnames.h
acoutput.h
acpi_bus.h ACPI: scan: Use unique number for instance_no 2021-03-30 14:41:41 +02:00
acpi_drivers.h
acpi_io.h
acpi_lpat.h
acpi_numa.h
acpi.h
acpiosxf.h
acpixf.h
acrestyp.h
actbl1.h
actbl2.h
actbl3.h
actbl.h
actypes.h ACPICA: Introduce ACPI_ACCESS_BYTE_WIDTH() macro 2020-03-11 07:53:05 +01:00
acuuid.h
apei.h
button.h
cppc_acpi.h
ghes.h
hed.h
pcc.h
pdc_intel.h
processor.h
reboot.h
video.h