mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 19:30:30 +09:00
ACPI / scan: Do not use dummy HID for system bus ACPI nodes
commit 4f5f64cf0c upstream.
At one point acpi_device_set_id() checks if acpi_device_hid(device)
returns NULL, but that never happens, so system bus devices with an
empty list of PNP IDs are given the dummy HID ("device") instead of
the "system bus HID" ("LNXSYBUS"). Fix the code to use the right
check.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
42fac8ebfa
commit
611d6f03ec
@@ -1153,7 +1153,7 @@ static void acpi_device_set_id(struct acpi_device *device)
|
||||
acpi_add_id(device, ACPI_DOCK_HID);
|
||||
else if (!acpi_ibm_smbus_match(device))
|
||||
acpi_add_id(device, ACPI_SMBUS_IBM_HID);
|
||||
else if (!acpi_device_hid(device) &&
|
||||
else if (list_empty(&device->pnp.ids) &&
|
||||
ACPI_IS_ROOT_DEVICE(device->parent)) {
|
||||
acpi_add_id(device, ACPI_BUS_HID); /* \_SB, LNXSYBUS */
|
||||
strcpy(device->pnp.device_name, ACPI_BUS_DEVICE_NAME);
|
||||
|
||||
Reference in New Issue
Block a user