[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <069fdf2e-7674-4443-9ecb-849793cb0ecd@rock-chips.com>
Date: Wed, 7 Jan 2026 16:38:39 +0800
From: Shawn Lin <shawn.lin@...k-chips.com>
To: manivannan.sadhasivam@....qualcomm.com, Jingoo Han
<jingoohan1@...il.com>, Manivannan Sadhasivam <mani@...nel.org>,
Lorenzo Pieralisi <lpieralisi@...nel.org>,
Krzysztof Wilczyński <kwilczynski@...nel.org>,
Rob Herring <robh@...nel.org>, Bjorn Helgaas <bhelgaas@...gle.com>
Cc: shawn.lin@...k-chips.com, linux-pci@...r.kernel.org,
linux-kernel@...r.kernel.org, vincent.guittot@...aro.org,
zhangsenchuan@...incomputing.com, Richard Zhu <hongxing.zhu@....com>
Subject: Re: [PATCH v4 4/6] PCI: dwc: Only skip the dw_pcie_wait_for_link()
failure if it returns -ENODEV
在 2026/01/07 星期三 16:11, Manivannan Sadhasivam via B4 Relay 写道:
> From: Manivannan Sadhasivam <manivannan.sadhasivam@....qualcomm.com>
>
> dw_pcie_wait_for_link() now returns -ENODEV if the device is not found on
> the bus and -ETIMEDOUT if the link fails to come up for any other reasons.
> And it is incorrect to skip the link up failures other than device not
> found. So only skip the failure for device not found case and handle
> failure for other reasons.
>
Reviewed-by: Shawn Lin <shawn.lin@...k-chips.com>
> Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@....qualcomm.com>
> ---
> drivers/pci/controller/dwc/pcie-designware-host.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-designware-host.c b/drivers/pci/controller/dwc/pcie-designware-host.c
> index fad0cbedefbc..ccde12b85463 100644
> --- a/drivers/pci/controller/dwc/pcie-designware-host.c
> +++ b/drivers/pci/controller/dwc/pcie-designware-host.c
> @@ -675,8 +675,10 @@ int dw_pcie_host_init(struct dw_pcie_rp *pp)
> goto err_remove_edma;
> }
>
> - /* Ignore errors, the link may come up later */
> - dw_pcie_wait_for_link(pci);
> + /* Skip failure if the device is not found as it may show up later */
> + ret = dw_pcie_wait_for_link(pci);
> + if (ret && ret != -ENODEV)
> + goto err_stop_link;
>
> ret = pci_host_probe(bridge);
> if (ret)
>
Powered by blists - more mailing lists