Skip to content

Commit 67047e8

Browse files
robherringLorenzo Pieralisi
authored andcommitted
PCI: tegra: Use pci_host_probe() to register host
The tegra host driver does the same host registration and bus scanning calls as pci_host_probe, so let's use it instead. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Rob Herring <[email protected]> Signed-off-by: Lorenzo Pieralisi <[email protected]> Cc: Thierry Reding <[email protected]> Cc: Jonathan Hunter <[email protected]> Cc: [email protected]
1 parent 1f9b751 commit 67047e8

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

drivers/pci/controller/pci-tegra.c

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2670,7 +2670,6 @@ static int tegra_pcie_probe(struct platform_device *pdev)
26702670
struct device *dev = &pdev->dev;
26712671
struct pci_host_bridge *host;
26722672
struct tegra_pcie *pcie;
2673-
struct pci_bus *child;
26742673
struct resource *bus;
26752674
int err;
26762675

@@ -2721,20 +2720,12 @@ static int tegra_pcie_probe(struct platform_device *pdev)
27212720
host->map_irq = tegra_pcie_map_irq;
27222721
host->swizzle_irq = pci_common_swizzle;
27232722

2724-
err = pci_scan_root_bus_bridge(host);
2723+
err = pci_host_probe(host);
27252724
if (err < 0) {
27262725
dev_err(dev, "failed to register host: %d\n", err);
27272726
goto pm_runtime_put;
27282727
}
27292728

2730-
pci_bus_size_bridges(host->bus);
2731-
pci_bus_assign_resources(host->bus);
2732-
2733-
list_for_each_entry(child, &host->bus->children, node)
2734-
pcie_bus_configure_settings(child);
2735-
2736-
pci_bus_add_devices(host->bus);
2737-
27382729
if (IS_ENABLED(CONFIG_DEBUG_FS)) {
27392730
err = tegra_pcie_debugfs_init(pcie);
27402731
if (err < 0)

0 commit comments

Comments
 (0)