diff options
Diffstat (limited to 'drivers/acpi/scan.c')
-rw-r--r-- | drivers/acpi/scan.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c index a0dfdffe54d4..d842569395a9 100644 --- a/drivers/acpi/scan.c +++ b/drivers/acpi/scan.c | |||
@@ -29,6 +29,15 @@ extern struct acpi_device *acpi_root; | |||
29 | 29 | ||
30 | static const char *dummy_hid = "device"; | 30 | static const char *dummy_hid = "device"; |
31 | 31 | ||
32 | /* | ||
33 | * The following ACPI IDs are known to be suitable for representing as | ||
34 | * platform devices. | ||
35 | */ | ||
36 | static const struct acpi_device_id acpi_platform_device_ids[] = { | ||
37 | |||
38 | { } | ||
39 | }; | ||
40 | |||
32 | static LIST_HEAD(acpi_device_list); | 41 | static LIST_HEAD(acpi_device_list); |
33 | static LIST_HEAD(acpi_bus_id_list); | 42 | static LIST_HEAD(acpi_bus_id_list); |
34 | DEFINE_MUTEX(acpi_device_lock); | 43 | DEFINE_MUTEX(acpi_device_lock); |
@@ -1513,8 +1522,13 @@ static acpi_status acpi_bus_check_add(acpi_handle handle, u32 lvl, | |||
1513 | */ | 1522 | */ |
1514 | device = NULL; | 1523 | device = NULL; |
1515 | acpi_bus_get_device(handle, &device); | 1524 | acpi_bus_get_device(handle, &device); |
1516 | if (ops->acpi_op_add && !device) | 1525 | if (ops->acpi_op_add && !device) { |
1517 | acpi_add_single_object(&device, handle, type, sta, ops); | 1526 | acpi_add_single_object(&device, handle, type, sta, ops); |
1527 | /* Is the device a known good platform device? */ | ||
1528 | if (device | ||
1529 | && !acpi_match_device_ids(device, acpi_platform_device_ids)) | ||
1530 | acpi_create_platform_device(device); | ||
1531 | } | ||
1518 | 1532 | ||
1519 | if (!device) | 1533 | if (!device) |
1520 | return AE_CTRL_DEPTH; | 1534 | return AE_CTRL_DEPTH; |