diff options
author | Hou Zhiqiang <Zhiqiang.Hou@nxp.com> | 2021-05-13 14:54:32 +0800 |
---|---|---|
committer | Priyanka Jain <priyanka.jain@nxp.com> | 2021-06-17 11:46:11 +0530 |
commit | 8e221b4a1c3144bbc0fcbb5a6c40ba63d618f02f (patch) | |
tree | f5e460907fc097f66ccf27c11c4abbc9071d7e83 | |
parent | ff64e9a9f0f48107a46536c251951885df63d63f (diff) | |
download | u-boot-8e221b4a1c3144bbc0fcbb5a6c40ba63d618f02f.zip u-boot-8e221b4a1c3144bbc0fcbb5a6c40ba63d618f02f.tar.gz u-boot-8e221b4a1c3144bbc0fcbb5a6c40ba63d618f02f.tar.bz2 |
pci: layerscape-ep: Add check of the PCIe controller enablement
Stop to initialize the PCIe controller if it's disabled by RCW.
Fixes: 118e58e26eba ("pci: layerscape: Split the EP and RC driver")
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
-rw-r--r-- | drivers/pci/pcie_layerscape_ep.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/pci/pcie_layerscape_ep.c b/drivers/pci/pcie_layerscape_ep.c index c723163..f2813ae 100644 --- a/drivers/pci/pcie_layerscape_ep.c +++ b/drivers/pci/pcie_layerscape_ep.c @@ -269,6 +269,10 @@ static int ls_pcie_ep_probe(struct udevice *dev) pcie->idx = ((unsigned long)pcie->dbi - PCIE_SYS_BASE_ADDR) / PCIE_CCSR_SIZE; + /* This controller is disabled by RCW */ + if (!is_serdes_configured(PCIE_SRDS_PRTCL(pcie->idx))) + return 0; + pcie->big_endian = fdtdec_get_bool(gd->fdt_blob, dev_of_offset(dev), "big-endian"); |