aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/acpi/glue.c12
-rw-r--r--drivers/ide/ide-acpi.c11
-rw-r--r--include/acpi/acpi_bus.h1
3 files changed, 11 insertions, 13 deletions
diff --git a/drivers/acpi/glue.c b/drivers/acpi/glue.c
index 896351b9d483..0c789224d40d 100644
--- a/drivers/acpi/glue.c
+++ b/drivers/acpi/glue.c
@@ -151,18 +151,6 @@ struct acpi_device *acpi_find_child_device(struct acpi_device *parent,
151} 151}
152EXPORT_SYMBOL_GPL(acpi_find_child_device); 152EXPORT_SYMBOL_GPL(acpi_find_child_device);
153 153
154acpi_handle acpi_get_child(acpi_handle handle, u64 addr)
155{
156 struct acpi_device *adev;
157
158 if (!handle || acpi_bus_get_device(handle, &adev))
159 return NULL;
160
161 adev = acpi_find_child_device(adev, addr, false);
162 return adev ? adev->handle : NULL;
163}
164EXPORT_SYMBOL_GPL(acpi_get_child);
165
166static void acpi_physnode_link_name(char *buf, unsigned int node_id) 154static void acpi_physnode_link_name(char *buf, unsigned int node_id)
167{ 155{
168 if (node_id > 0) 156 if (node_id > 0)
diff --git a/drivers/ide/ide-acpi.c b/drivers/ide/ide-acpi.c
index 333d4053e727..b6940992a6ff 100644
--- a/drivers/ide/ide-acpi.c
+++ b/drivers/ide/ide-acpi.c
@@ -97,6 +97,17 @@ bool ide_port_acpi(ide_hwif_t *hwif)
97 return ide_noacpi == 0 && hwif->acpidata; 97 return ide_noacpi == 0 && hwif->acpidata;
98} 98}
99 99
100static acpi_handle acpi_get_child(acpi_handle handle, u64 addr)
101{
102 struct acpi_device *adev;
103
104 if (!handle || acpi_bus_get_device(handle, &adev))
105 return NULL;
106
107 adev = acpi_find_child_device(adev, addr, false);
108 return adev ? adev->handle : NULL;
109}
110
100/** 111/**
101 * ide_get_dev_handle - finds acpi_handle and PCI device.function 112 * ide_get_dev_handle - finds acpi_handle and PCI device.function
102 * @dev: device to locate 113 * @dev: device to locate
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index a50898e67a68..7135fe3d6daa 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -434,7 +434,6 @@ struct acpi_pci_root {
434 434
435struct acpi_device *acpi_find_child_device(struct acpi_device *parent, 435struct acpi_device *acpi_find_child_device(struct acpi_device *parent,
436 u64 address, bool check_children); 436 u64 address, bool check_children);
437acpi_handle acpi_get_child(acpi_handle handle, u64 addr);
438int acpi_is_root_bridge(acpi_handle); 437int acpi_is_root_bridge(acpi_handle);
439struct acpi_pci_root *acpi_pci_find_root(acpi_handle handle); 438struct acpi_pci_root *acpi_pci_find_root(acpi_handle handle);
440 439