aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYinghai Lu <yinghai@kernel.org>2012-09-17 22:16:11 -0700
committerYinghai Lu <yinghai@kernel.org>2012-09-17 22:16:11 -0700
commita0999cb2f82c90ab2cba253ef46bcfdb6fbd68fe (patch)
tree294cd4659f9b5cb2e9dce761e4e81aba0a5b3fd3
parentab9fd4ccbfb6120a4a4adf9833487d656b0501d3 (diff)
downloadlinux-yinghai-a0999cb2f82c90ab2cba253ef46bcfdb6fbd68fe.tar.gz
PCI, ACPI: Pass device instead of handle when config root bridge
So we can avoid one calling of acpi_pci_find_root(). Signed-off-by: Yinghai Lu <yinghai@kernel.org>
-rw-r--r--drivers/acpi/pci_root_hp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/acpi/pci_root_hp.c b/drivers/acpi/pci_root_hp.c
index e07c31bea2286c..eb4344c4cb140a 100644
--- a/drivers/acpi/pci_root_hp.c
+++ b/drivers/acpi/pci_root_hp.c
@@ -102,9 +102,9 @@ static void alloc_acpi_root_hp_work(acpi_handle handle, u32 type,
}
/* Program resources in newly inserted bridge */
-static void acpi_root_configure_bridge(acpi_handle handle)
+static void acpi_root_configure_bridge(struct acpi_device *device)
{
- struct acpi_pci_root *root = acpi_pci_find_root(handle);
+ struct acpi_pci_root *root = acpi_driver_data(device);
pcibios_resource_survey_bus(root->bus);
pci_assign_unassigned_bus_resources(root->bus);
@@ -138,7 +138,7 @@ static void handle_root_bridge_insertion(acpi_handle handle)
printk(KERN_ERR "cannot add bridge to acpi list\n");
return;
}
- acpi_root_configure_bridge(handle);
+ acpi_root_configure_bridge(device);
if (acpi_bus_start(device))
printk(KERN_ERR "cannot start bridge\n");
}