summaryrefslogtreecommitdiff
path: root/drivers/pci/controller/dwc/pcie-designware.h
diff options
context:
space:
mode:
authorAjay Agarwal <ajayagarwal@google.com>2023-04-12 15:04:25 +0530
committerLorenzo Pieralisi <lpieralisi@kernel.org>2023-05-26 10:45:12 +0200
commitda56a1bfbab55189595e588f1d984bdfb5cf5924 (patch)
tree3b6bc5e11ca564f1349019af3e3d688da6866b70 /drivers/pci/controller/dwc/pcie-designware.h
parentac9a78681b921877518763ba0e89202254349d1b (diff)
downloadlinux-da56a1bfbab55189595e588f1d984bdfb5cf5924.tar.gz
linux-da56a1bfbab55189595e588f1d984bdfb5cf5924.tar.bz2
linux-da56a1bfbab55189595e588f1d984bdfb5cf5924.zip
PCI: dwc: Wait for link up only if link is started
In dw_pcie_host_init() regardless of whether the link has been started or not, the code waits for the link to come up. Even in cases where start_link() is not defined the code ends up spinning in a loop for 1 second. Since in some systems dw_pcie_host_init() gets called during probe, this one second loop for each pcie interface instance ends up extending the boot time. Wait for the link up in only if the start_link() is defined. Link: https://lore.kernel.org/r/20230412093425.3659088-1-ajayagarwal@google.com Tested-by: Will McVicker <willmcvicker@google.com> Signed-off-by: Sajid Dalvi <sdalvi@google.com> Signed-off-by: Ajay Agarwal <ajayagarwal@google.com> Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
Diffstat (limited to 'drivers/pci/controller/dwc/pcie-designware.h')
-rw-r--r--drivers/pci/controller/dwc/pcie-designware.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/pci/controller/dwc/pcie-designware.h b/drivers/pci/controller/dwc/pcie-designware.h
index 79713ce075cc..615660640801 100644
--- a/drivers/pci/controller/dwc/pcie-designware.h
+++ b/drivers/pci/controller/dwc/pcie-designware.h
@@ -429,6 +429,7 @@ void dw_pcie_setup(struct dw_pcie *pci);
void dw_pcie_iatu_detect(struct dw_pcie *pci);
int dw_pcie_edma_detect(struct dw_pcie *pci);
void dw_pcie_edma_remove(struct dw_pcie *pci);
+void dw_pcie_print_link_status(struct dw_pcie *pci);
static inline void dw_pcie_writel_dbi(struct dw_pcie *pci, u32 reg, u32 val)
{