diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2019-06-24 11:50:31 +1000 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2019-06-24 14:03:57 +1000 |
commit | a43d552305dbe6cb6db1c7d3488d8b2213796253 (patch) | |
tree | b6e41ca5c1fa5c9aeaa83636771e62ae34546e2e | |
parent | e3b5db827a2994dbe6ae76d9e959d00a36684627 (diff) | |
download | pci-a43d552305dbe6cb6db1c7d3488d8b2213796253.tar.gz |
arm64: PCI: Use pci_bus_resource_survey() for ACPI platforms
This switches arm64 to use the new generic pci_bus_resource_survey()
with the existing default policies.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-rw-r--r-- | arch/arm64/kernel/pci.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c index e541408778bde3..a2eaaadc769e57 100644 --- a/arch/arm64/kernel/pci.c +++ b/arch/arm64/kernel/pci.c @@ -162,9 +162,8 @@ static void pci_acpi_generic_release_info(struct acpi_pci_root_info *ci) struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root) { struct acpi_pci_generic_root_info *ri; - struct pci_bus *bus, *child; struct acpi_pci_root_ops *root_ops; - struct pci_host_bridge *host; + struct pci_bus *bus; ri = kzalloc(sizeof(*ri), GFP_KERNEL); if (!ri) @@ -190,19 +189,8 @@ struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root) if (!bus) return NULL; - /* If we must preserve the resource configuration, claim now */ - host = pci_find_host_bridge(bus); - if (host->rsrc_policy <= pci_rsrc_claim_assign) - pci_bus_claim_resources(bus); - - /* - * Assign whatever was left unassigned. If we didn't claim above, - * this will reassign everything. - */ - pci_assign_unassigned_root_bus_resources(bus); - - list_for_each_entry(child, &bus->children, node) - pcie_bus_configure_settings(child); + /* Setup resources */ + pci_host_resource_survey(bus); return bus; } |