summaryrefslogtreecommitdiff
path: root/drivers/pci/probe.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci/probe.c')
-rw-r--r--drivers/pci/probe.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index ff94b69738a8..cdc2f83c11c5 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -2421,10 +2421,8 @@ unsigned int pci_scan_child_bus(struct pci_bus *bus)
}
for (pass = 0; pass < 2; pass++)
- list_for_each_entry(dev, &bus->devices, bus_list) {
- if (pci_is_bridge(dev))
- max = pci_scan_bridge(bus, dev, max, pass);
- }
+ for_each_pci_bridge(dev, bus)
+ max = pci_scan_bridge(bus, dev, max, pass);
/*
* Make sure a hotplug bridge has at least the minimum requested