aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2012-12-22 18:03:03 -0500
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-01-03 07:09:42 -0500
commit3eec5f7a1955ead549020ec2f60235ea6a4a2252 (patch)
treea934e8946d70cc8330625e0aa1b30eb60df566c5 /drivers
parent38a9a67a281eeebcd7cccf87f0e371f58ae625e3 (diff)
ACPI: Drop ACPI device .bind() and .unbind() callbacks
Drop the .bind() and .unbind() that have no more users from struct acpi_device_ops and remove all of the code referring to them from drivers/acpi/scan.c. 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>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/acpi/scan.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c
index 3d44c705a3a2..f8a0d0f7d197 100644
--- a/drivers/acpi/scan.c
+++ b/drivers/acpi/scan.c
@@ -1385,29 +1385,11 @@ static int acpi_bus_remove(struct acpi_device *dev, int rmdevice)
1385 if (!rmdevice) 1385 if (!rmdevice)
1386 return 0; 1386 return 0;
1387 1387
1388 /*
1389 * unbind _ADR-Based Devices when hot removal
1390 */
1391 if (dev->flags.bus_address) {
1392 if ((dev->parent) && (dev->parent->ops.unbind))
1393 dev->parent->ops.unbind(dev);
1394 }
1395 acpi_device_unregister(dev, ACPI_BUS_REMOVAL_EJECT); 1388 acpi_device_unregister(dev, ACPI_BUS_REMOVAL_EJECT);
1396 1389
1397 return 0; 1390 return 0;
1398} 1391}
1399 1392
1400/*
1401 * acpi_hot_add_bind - Bind _ADR-based devices on hot-add.
1402 * @device: ACPI device node to bind.
1403 */
1404static void acpi_hot_add_bind(struct acpi_device *device)
1405{
1406 if (device->flags.bus_address
1407 && device->parent && device->parent->ops.bind)
1408 device->parent->ops.bind(device);
1409}
1410
1411static int acpi_add_single_object(struct acpi_device **child, 1393static int acpi_add_single_object(struct acpi_device **child,
1412 acpi_handle handle, int type, 1394 acpi_handle handle, int type,
1413 unsigned long long sta, bool match_driver) 1395 unsigned long long sta, bool match_driver)
@@ -1479,9 +1461,6 @@ static int acpi_add_single_object(struct acpi_device **child,
1479 device->flags.match_driver = match_driver; 1461 device->flags.match_driver = match_driver;
1480 result = acpi_device_register(device); 1462 result = acpi_device_register(device);
1481 1463
1482 if (device->flags.match_driver)
1483 acpi_hot_add_bind(device);
1484
1485end: 1464end:
1486 if (!result) { 1465 if (!result) {
1487 acpi_get_name(handle, ACPI_FULL_PATHNAME, &buffer); 1466 acpi_get_name(handle, ACPI_FULL_PATHNAME, &buffer);
@@ -1584,7 +1563,6 @@ static acpi_status acpi_bus_check_add(acpi_handle handle, u32 lvl_not_used,
1584 return AE_CTRL_DEPTH; 1563 return AE_CTRL_DEPTH;
1585 1564
1586 device->flags.match_driver = true; 1565 device->flags.match_driver = true;
1587 acpi_hot_add_bind(device);
1588 1566
1589 out: 1567 out:
1590 if (!*return_value) 1568 if (!*return_value)