aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2019-06-24 14:20:37 +1000
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2019-06-29 10:41:50 +1000
commitec1ea2b46d1a0f58eebee16bb5426b1c6d9c1745 (patch)
treee3f69b7c089f33c43fcaa3d046ecbbd812a1343e
parent806068f25d8d7e8387b9d566425c8646f7572800 (diff)
downloadpci-ec1ea2b46d1a0f58eebee16bb5426b1c6d9c1745.tar.gz
PCI: controller: xgene: Use pci_host_resource_survey()
Use this instead of pci_assign_unassigned_bus_resources() as it is more appropriate for a host bridge. The result should be equivalent based on the default ARM policy. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-rw-r--r--drivers/pci/controller/pci-xgene.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/pci/controller/pci-xgene.c b/drivers/pci/controller/pci-xgene.c
index ffda3e8b474268..f0a711e1398a4d 100644
--- a/drivers/pci/controller/pci-xgene.c
+++ b/drivers/pci/controller/pci-xgene.c
@@ -608,7 +608,6 @@ static int xgene_pcie_probe(struct platform_device *pdev)
struct device_node *dn = dev->of_node;
struct xgene_pcie_port *port;
resource_size_t iobase = 0;
- struct pci_bus *bus, *child;
struct pci_host_bridge *bridge;
int ret;
LIST_HEAD(res);
@@ -659,12 +658,8 @@ static int xgene_pcie_probe(struct platform_device *pdev)
if (ret < 0)
goto error;
- bus = bridge->bus;
-
- pci_assign_unassigned_bus_resources(bus);
- list_for_each_entry(child, &bus->children, node)
- pcie_bus_configure_settings(child);
- pci_bus_add_devices(bus);
+ pci_host_resource_survey(bridge->bus);
+ pci_bus_add_devices(bridge->bus);
return 0;
error: