diff options
| author | Konstantin Porotchkin <[email protected]> | 2017-03-28 18:36:34 +0300 |
|---|---|---|
| committer | Stefan Roese <[email protected]> | 2017-05-09 13:38:17 +0200 |
| commit | 3f75e0ce7badc7db03885f8b925a5f47cad29cac (patch) | |
| tree | f6a77a1b9a6a240330f8968adbb3d7c75c9201c2 /drivers | |
| parent | 2f720f195792bb29289827ef9512e0366a81933b (diff) | |
fix: mvebu: pcie_dw: Allow probing empty PCIe slots
This patch allows probing all PCIe nodes defined in DTS
even if there no device connected to such node (no link).
Without this fix the driver returns -ENODEV when the PCIe
link is down. As result the pci_init function stops
scanning bus on first empty PCIe slot and all devices
located in higher numbered buses are not discovered.
Signed-off-by: Konstantin Porotchkin <[email protected]>
Cc: Stefan Roese <[email protected]>
Cc: Igal Liberman <[email protected]>
Cc: Nadav Haklai <[email protected]>
Reviewed-by: Stefan Roese <[email protected]>
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/pci/pcie_dw_mvebu.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/pci/pcie_dw_mvebu.c b/drivers/pci/pcie_dw_mvebu.c index d4776a9c81e..05a06604e68 100644 --- a/drivers/pci/pcie_dw_mvebu.c +++ b/drivers/pci/pcie_dw_mvebu.c @@ -487,13 +487,13 @@ static int pcie_dw_mvebu_probe(struct udevice *dev) /* Don't register host if link is down */ if (!pcie_dw_mvebu_pcie_link_up(pcie->ctrl_base, LINK_SPEED_GEN_3)) { printf("PCIE-%d: Link down\n", dev->seq); - return -ENODEV; + } else { + printf("PCIE-%d: Link up (Gen%d-x%d, Bus%d)\n", dev->seq, + pcie_dw_get_link_speed(pcie->ctrl_base), + pcie_dw_get_link_width(pcie->ctrl_base), + hose->first_busno); } - printf("PCIE-%d: Link up (Gen%d-x%d, Bus%d)\n", dev->seq, - pcie_dw_get_link_speed(pcie->ctrl_base), - pcie_dw_get_link_width(pcie->ctrl_base), hose->first_busno); - pcie_dw_regions_setup(pcie); /* Set the CLASS_REV of RC CFG header to PCI_CLASS_BRIDGE_PCI */ |
