diff options
| author | Niklas Cassel <[email protected]> | 2025-06-25 10:23:52 +0000 |
|---|---|---|
| committer | Manivannan Sadhasivam <[email protected]> | 2025-06-25 13:26:04 +0000 |
| commit | d7467bc72ce4e3f64062017d6c9ae3816e8a7b0e (patch) | |
| tree | b766f45c32fa4395445d96e3b9d373a777cdb90a /drivers/pci/controller/dwc/pcie-designware.c | |
| parent | PCI: dwc: Ensure that dw_pcie_wait_for_link() waits 100 ms after link up (diff) | |
| download | kernel-d7467bc72ce4e3f64062017d6c9ae3816e8a7b0e.tar.gz kernel-d7467bc72ce4e3f64062017d6c9ae3816e8a7b0e.zip | |
PCI: Move link up wait time and max retries macros to pci.h
Move the LINK_WAIT_SLEEP_MS and LINK_WAIT_MAX_RETRIES macros to pci.h.
Prefix the macros with PCIE_ in order to avoid redefining these for
drivers that already have macros named like this.
No functional changes.
Suggested-by: Manivannan Sadhasivam <[email protected]>
Signed-off-by: Niklas Cassel <[email protected]>
Signed-off-by: Manivannan Sadhasivam <[email protected]>
Link: https://patch.msgid.link/[email protected]
Diffstat (limited to 'drivers/pci/controller/dwc/pcie-designware.c')
| -rw-r--r-- | drivers/pci/controller/dwc/pcie-designware.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/pci/controller/dwc/pcie-designware.c b/drivers/pci/controller/dwc/pcie-designware.c index 053e9c540439..89aad5a08928 100644 --- a/drivers/pci/controller/dwc/pcie-designware.c +++ b/drivers/pci/controller/dwc/pcie-designware.c @@ -702,14 +702,14 @@ int dw_pcie_wait_for_link(struct dw_pcie *pci) int retries; /* Check if the link is up or not */ - for (retries = 0; retries < LINK_WAIT_MAX_RETRIES; retries++) { + for (retries = 0; retries < PCIE_LINK_WAIT_MAX_RETRIES; retries++) { if (dw_pcie_link_up(pci)) break; - msleep(LINK_WAIT_SLEEP_MS); + msleep(PCIE_LINK_WAIT_SLEEP_MS); } - if (retries >= LINK_WAIT_MAX_RETRIES) { + if (retries >= PCIE_LINK_WAIT_MAX_RETRIES) { dev_info(pci->dev, "Phy link never came up\n"); return -ETIMEDOUT; } |
