Commit b17c0e6f authored by Yinghai Lu's avatar Yinghai Lu Committed by Bjorn Helgaas

tile/PCI: use pci_scan_root_bus instead pci_scan_bus

It will update busn_res accordingly, so we get that for last_busno.
Acked-by: default avatarChris Metcalf <cmetcalf@tilera.com>
Signed-off-by: default avatarYinghai Lu <yinghai@kernel.org>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
parent 30aa80da
...@@ -310,6 +310,7 @@ int __init pcibios_init(void) ...@@ -310,6 +310,7 @@ int __init pcibios_init(void)
if (pci_scan_flags[i] == 0 && controllers[i].ops != NULL) { if (pci_scan_flags[i] == 0 && controllers[i].ops != NULL) {
struct pci_controller *controller = &controllers[i]; struct pci_controller *controller = &controllers[i];
struct pci_bus *bus; struct pci_bus *bus;
LIST_HEAD(resources);
if (tile_init_irqs(i, controller)) { if (tile_init_irqs(i, controller)) {
pr_err("PCI: Could not initialize IRQs\n"); pr_err("PCI: Could not initialize IRQs\n");
...@@ -327,7 +328,9 @@ int __init pcibios_init(void) ...@@ -327,7 +328,9 @@ int __init pcibios_init(void)
* This is inlined in linux/pci.h and calls into * This is inlined in linux/pci.h and calls into
* pci_scan_bus_parented() in probe.c. * pci_scan_bus_parented() in probe.c.
*/ */
bus = pci_scan_bus(0, controller->ops, controller); pci_add_resource(&resources, &ioport_resource);
pci_add_resource(&resources, &iomem_resource);
bus = pci_scan_root_bus(NULL, 0, controller->ops, controller, &resources);
controller->root_bus = bus; controller->root_bus = bus;
controller->last_busno = bus->busn_res.end; controller->last_busno = bus->busn_res.end;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment