summaryrefslogtreecommitdiff
path: root/drivers/acpi/glue.c
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2021-09-18 15:56:17 +0300
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2021-09-27 18:01:25 +0300
commitc4d19838d8c42828c7e39e4432ea5b33f02dac27 (patch)
tree7659c700b778bb0424a7bdb2593b4bbf01a60220 /drivers/acpi/glue.c
parent4795448117824cc4900d696f17d1516c56371045 (diff)
downloadlinux-c4d19838d8c42828c7e39e4432ea5b33f02dac27.tar.xz
ACPI: glue: Drop cleanup callback from struct acpi_bus_type
Since PCI was the only user of the ->cleanup callback in struct acpi_bus_type and it is not using struct acpi_bus_type any more, drop that callback from there and update acpi_device_notify_remove() accordingly. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Tested-by: Ferry Toth <fntoth@gmail.com>
Diffstat (limited to 'drivers/acpi/glue.c')
-rw-r--r--drivers/acpi/glue.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/acpi/glue.c b/drivers/acpi/glue.c
index 68768d6c8a47..49aaf18243f6 100644
--- a/drivers/acpi/glue.c
+++ b/drivers/acpi/glue.c
@@ -337,16 +337,10 @@ void acpi_device_notify_remove(struct device *dev)
if (!adev)
return;
- if (dev_is_pci(dev)) {
+ if (dev_is_pci(dev))
pci_acpi_cleanup(dev, adev);
- } else {
- struct acpi_bus_type *type = acpi_get_bus_type(dev);
-
- if (type && type->cleanup)
- type->cleanup(dev);
- else if (adev->handler && adev->handler->unbind)
- adev->handler->unbind(dev);
- }
+ else if (adev->handler && adev->handler->unbind)
+ adev->handler->unbind(dev);
acpi_unbind_one(dev);
}