ACPI: Drop the second argument of acpi_bus_scan()
After the removal of acpi_start_single_object() and acpi_bus_start()
the second argument of acpi_bus_scan() is not necessary any more,
so drop it and update acpi_bus_check_add() accordingly.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Yinghai Lu <yinghai@kernel.org>
Acked-by: Toshi Kani <toshi.kani@hp.com>
diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c
index 25095bf..eb54f98 100644
--- a/drivers/acpi/scan.c
+++ b/drivers/acpi/scan.c
@@ -1551,8 +1551,8 @@
return 0;
}
-static acpi_status acpi_bus_check_add(acpi_handle handle, u32 lvl,
- void *context, void **return_value)
+static acpi_status acpi_bus_check_add(acpi_handle handle, u32 lvl_not_used,
+ void *not_used, void **return_value)
{
struct acpi_device *device = NULL;
int type;
@@ -1584,7 +1584,7 @@
if (!device)
return AE_CTRL_DEPTH;
- device->add_type = context ? ACPI_BUS_ADD_START : ACPI_BUS_ADD_MATCH;
+ device->add_type = ACPI_BUS_ADD_START;
acpi_hot_add_bind(device);
out:
@@ -1621,18 +1621,16 @@
return status;
}
-static int acpi_bus_scan(acpi_handle handle, bool start,
- struct acpi_device **child)
+static int acpi_bus_scan(acpi_handle handle, struct acpi_device **child)
{
void *device = NULL;
acpi_status status;
int ret = -ENODEV;
- status = acpi_bus_check_add(handle, 0, (void *)start, &device);
+ status = acpi_bus_check_add(handle, 0, NULL, &device);
if (ACPI_SUCCESS(status))
acpi_walk_namespace(ACPI_TYPE_ANY, handle, ACPI_UINT32_MAX,
- acpi_bus_check_add, NULL, (void *)start,
- &device);
+ acpi_bus_check_add, NULL, NULL, &device);
if (!device)
goto out;
@@ -1676,7 +1674,7 @@
{
int err;
- err = acpi_bus_scan(handle, false, ret);
+ err = acpi_bus_scan(handle, ret);
if (err)
return err;
@@ -1782,7 +1780,7 @@
/*
* Enumerate devices in the ACPI namespace.
*/
- result = acpi_bus_scan(ACPI_ROOT_OBJECT, true, &acpi_root);
+ result = acpi_bus_scan(ACPI_ROOT_OBJECT, &acpi_root);
if (!result)
result = acpi_bus_scan_fixed();