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
ACPICA: OSL: Add support to exclude stdarg.h
2018-04-13 19:48:28 +02:00
acbuffer.h
ACPICA: Additional 2016 copyright changes
2016-01-15 22:18:09 +01:00
acconfig.h
ACPICA: Reference Counts: increase max to 0x4000 for large servers
2019-03-19 13:14:07 +01:00
acexcep.h
ACPICA: Additional 2016 copyright changes
2016-01-15 22:18:09 +01:00
acnames.h
ACPICA: Additional 2016 copyright changes
2016-01-15 22:18:09 +01:00
acoutput.h
ACPICA: Fix deconstification warnings (-Wcast-qual) with function traces.
2016-08-13 03:09:31 +02:00
acpi.h
ACPICA: Additional 2016 copyright changes
2016-01-15 22:18:09 +01:00
acpi_bus.h
ACPI: scan: Use unique number for instance_no
2021-03-30 14:41:41 +02:00
acpi_drivers.h
Revert "ACPI, PCI, IRQ: remove redundant code in acpi_irq_penalty_init()"
2016-07-02 01:38:34 +02:00
acpi_io.h
treewide: replace obsolete _refok by __ref
2016-08-02 17:31:41 -04:00
acpi_lpat.h
ACPI / LPAT: Common table processing functions
2015-01-29 21:02:10 +08:00
acpi_numa.h
ACPI / NUMA: move bad_srat() and srat_disabled() to drivers/acpi/numa.c
2016-05-30 14:27:08 +02:00
acpiosxf.h
ACPICA: Clib: Eliminate acpi_os_XXXFile()/acpi_log_error and link clibrary fxxx()/errno/perror() instead
2016-08-13 03:12:32 +02:00
acpixf.h
ACPICA: Update version to 20160831
2016-09-10 02:43:03 +02:00
acrestyp.h
ACPICA: ACPI 6.0, tools/iasl: Add support for new resource descriptors
2016-05-05 15:22:26 +02:00
actbl.h
Revert "ACPICA: FADT support cleanup"
2016-11-14 20:56:17 +01:00
actbl1.h
ACPICA: ACPI 6.1: Add full support for this version of ACPI spec
2016-04-05 03:53:31 +02:00
actbl2.h
ACPICA: iasl: Fix IORT SMMU GSI disassembling
2018-03-24 11:00:16 +01:00
actbl3.h
ACPICA: ACPI 6.1: Support for new PCCT subtable
2016-05-05 15:22:26 +02:00
actypes.h
ACPICA: Introduce ACPI_ACCESS_BYTE_WIDTH() macro
2020-03-11 07:53:05 +01:00
acuuid.h
ACPICA: Additional 2016 copyright changes
2016-01-15 22:18:09 +01:00
apei.h
acpi, apei, ghes: Factor out ioremap virtual memory for IRQ and NMI context.
2014-07-22 15:05:06 -07:00
button.h
ACPI: Eliminate CONFIG_.*{, _MODULE} #ifdef in favor of IS_ENABLED()
2015-09-15 03:05:45 +02:00
cppc_acpi.h
ACPI / CPPC: Add prefix cppc to cpudata structure name
2016-09-08 23:02:15 +02:00
ghes.h
ACPICA: Restore error table definitions to reduce code differences between Linux and ACPICA upstream.
2014-06-16 22:33:50 +02:00
hed.h
pcc.h
mailbox: PCC: Fix return value of pcc_mbox_request_channel()
2016-10-17 14:26:49 +02:00
pdc_intel.h
processor.h
ACPI/processor: Convert to hotplug state machine
2016-09-19 21:44:29 +02:00
reboot.h
video.h
ACPI / video: Dummy acpi_video_register should return error code
2016-06-25 02:56:59 +02:00