From: Christian Gmeiner <christian.gmeiner@gmail.com>
To: "Jingoo Han" <jingoohan1@gmail.com>,
"Gustavo Pimentel" <gustavo.pimentel@synopsys.com>,
"Lorenzo Pieralisi" <lorenzo.pieralisi@arm.com>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Wilczyński" <kw@linux.com>,
"Bjorn Helgaas" <bhelgaas@google.com>
Cc: Christian Gmeiner <christian.gmeiner@gmail.com>,
linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH v2] PCI: dwc: do not ignore link errors
Date: Wed, 21 Jul 2021 17:28:21 +0200 [thread overview]
Message-ID: <20210721152821.2967356-1-christian.gmeiner@gmail.com> (raw)
This fixes long boot delays of about 10 seconds.
I am working on a device powered by an TI am65 SoC where
we have a PCIe expansion slot. If there is no PCIe device
connected I see boot delays caused by pci_host_probe(..).
Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
---
V2: fix compile
---
drivers/pci/controller/dwc/pcie-designware-host.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-designware-host.c b/drivers/pci/controller/dwc/pcie-designware-host.c
index a608ae1fad57..ce7d3a6f9a03 100644
--- a/drivers/pci/controller/dwc/pcie-designware-host.c
+++ b/drivers/pci/controller/dwc/pcie-designware-host.c
@@ -408,8 +408,9 @@ int dw_pcie_host_init(struct pcie_port *pp)
goto err_free_msi;
}
- /* Ignore errors, the link may come up later */
- dw_pcie_wait_for_link(pci);
+ ret = dw_pcie_wait_for_link(pci);
+ if (ret)
+ goto err_free_msi;
bridge->sysdata = pp;
--
2.31.1
next reply other threads:[~2021-07-21 15:28 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-21 15:28 Christian Gmeiner [this message]
2021-07-21 17:11 ` [PATCH v2] PCI: dwc: do not ignore link errors Bjorn Helgaas
2021-07-22 16:38 ` Bjorn Helgaas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210721152821.2967356-1-christian.gmeiner@gmail.com \
--to=christian.gmeiner@gmail.com \
--cc=bhelgaas@google.com \
--cc=gustavo.pimentel@synopsys.com \
--cc=jingoohan1@gmail.com \
--cc=kw@linux.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lorenzo.pieralisi@arm.com \
--cc=robh@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).