* [PATCH] PCI: qcom: Don't deassert reset GPIO during probe
@ 2019-01-25 23:26 Bjorn Andersson
2019-02-08 14:54 ` Stanimir Varbanov
2019-02-13 15:23 ` Lorenzo Pieralisi
0 siblings, 2 replies; 5+ messages in thread
From: Bjorn Andersson @ 2019-01-25 23:26 UTC (permalink / raw)
To: Stanimir Varbanov, Lorenzo Pieralisi, Bjorn Helgaas
Cc: linux-pci, linux-arm-msm, linux-kernel, Khasim Syed Mohammed,
Niklas Cassel, stable
Acquiring the reset GPIO low means that reset is being deasserted, this
is followed almost immediately with qcom_pcie_host_init() asserting it,
initializing it and then finally deasserting it again, for the link to
come up.
Some PCIe devices requires a minimum time between the initial deassert
and subsequent reset cycles. In a platform that boots with the reset
GPIO asserted this requirement is being violated by this deassert/assert
pulse.
Acquiring the reset GPIO high will prevent this by matching the state to
the subsequent asserted state.
Cc: stable@vger.kernel.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
---
drivers/pci/controller/dwc/pcie-qcom.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
index d185ea5fe996..a7f703556790 100644
--- a/drivers/pci/controller/dwc/pcie-qcom.c
+++ b/drivers/pci/controller/dwc/pcie-qcom.c
@@ -1228,7 +1228,7 @@ static int qcom_pcie_probe(struct platform_device *pdev)
pcie->ops = of_device_get_match_data(dev);
- pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_LOW);
+ pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_HIGH);
if (IS_ERR(pcie->reset)) {
ret = PTR_ERR(pcie->reset);
goto err_pm_runtime_put;
--
2.18.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] PCI: qcom: Don't deassert reset GPIO during probe
2019-01-25 23:26 [PATCH] PCI: qcom: Don't deassert reset GPIO during probe Bjorn Andersson
@ 2019-02-08 14:54 ` Stanimir Varbanov
2019-02-13 15:23 ` Lorenzo Pieralisi
1 sibling, 0 replies; 5+ messages in thread
From: Stanimir Varbanov @ 2019-02-08 14:54 UTC (permalink / raw)
To: Bjorn Andersson, Lorenzo Pieralisi, Bjorn Helgaas
Cc: linux-pci, linux-arm-msm, linux-kernel, Khasim Syed Mohammed,
Niklas Cassel, stable
Hi Bjorn,
Thanks for the patch!
On 1/26/19 1:26 AM, Bjorn Andersson wrote:
> Acquiring the reset GPIO low means that reset is being deasserted, this
> is followed almost immediately with qcom_pcie_host_init() asserting it,
> initializing it and then finally deasserting it again, for the link to
> come up.
>
> Some PCIe devices requires a minimum time between the initial deassert
> and subsequent reset cycles. In a platform that boots with the reset
> GPIO asserted this requirement is being violated by this deassert/assert
> pulse.
>
> Acquiring the reset GPIO high will prevent this by matching the state to
> the subsequent asserted state.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> ---
> drivers/pci/controller/dwc/pcie-qcom.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
> index d185ea5fe996..a7f703556790 100644
> --- a/drivers/pci/controller/dwc/pcie-qcom.c
> +++ b/drivers/pci/controller/dwc/pcie-qcom.c
> @@ -1228,7 +1228,7 @@ static int qcom_pcie_probe(struct platform_device *pdev)
>
> pcie->ops = of_device_get_match_data(dev);
>
> - pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_LOW);
> + pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_HIGH);
> if (IS_ERR(pcie->reset)) {
> ret = PTR_ERR(pcie->reset);
> goto err_pm_runtime_put;
>
Acked-by: Stanimir Varbanov <svarbanov@mm-sol.com>
--
regards,
Stan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] PCI: qcom: Don't deassert reset GPIO during probe
2019-01-25 23:26 [PATCH] PCI: qcom: Don't deassert reset GPIO during probe Bjorn Andersson
2019-02-08 14:54 ` Stanimir Varbanov
@ 2019-02-13 15:23 ` Lorenzo Pieralisi
2019-02-19 5:16 ` Bjorn Andersson
1 sibling, 1 reply; 5+ messages in thread
From: Lorenzo Pieralisi @ 2019-02-13 15:23 UTC (permalink / raw)
To: Bjorn Andersson
Cc: Stanimir Varbanov, Bjorn Helgaas, linux-pci, linux-arm-msm,
linux-kernel, Khasim Syed Mohammed, Niklas Cassel, stable
On Fri, Jan 25, 2019 at 03:26:16PM -0800, Bjorn Andersson wrote:
> Acquiring the reset GPIO low means that reset is being deasserted, this
> is followed almost immediately with qcom_pcie_host_init() asserting it,
> initializing it and then finally deasserting it again, for the link to
> come up.
>
> Some PCIe devices requires a minimum time between the initial deassert
> and subsequent reset cycles. In a platform that boots with the reset
> GPIO asserted this requirement is being violated by this deassert/assert
> pulse.
>
> Acquiring the reset GPIO high will prevent this by matching the state to
> the subsequent asserted state.
>
> Cc: stable@vger.kernel.org
Missing Fixes: tag, please provide me one so that I can proceed.
Lorenzo
> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> ---
> drivers/pci/controller/dwc/pcie-qcom.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
> index d185ea5fe996..a7f703556790 100644
> --- a/drivers/pci/controller/dwc/pcie-qcom.c
> +++ b/drivers/pci/controller/dwc/pcie-qcom.c
> @@ -1228,7 +1228,7 @@ static int qcom_pcie_probe(struct platform_device *pdev)
>
> pcie->ops = of_device_get_match_data(dev);
>
> - pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_LOW);
> + pcie->reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_HIGH);
> if (IS_ERR(pcie->reset)) {
> ret = PTR_ERR(pcie->reset);
> goto err_pm_runtime_put;
> --
> 2.18.0
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] PCI: qcom: Don't deassert reset GPIO during probe
2019-02-13 15:23 ` Lorenzo Pieralisi
@ 2019-02-19 5:16 ` Bjorn Andersson
2019-02-19 11:10 ` Lorenzo Pieralisi
0 siblings, 1 reply; 5+ messages in thread
From: Bjorn Andersson @ 2019-02-19 5:16 UTC (permalink / raw)
To: Lorenzo Pieralisi
Cc: Stanimir Varbanov, Bjorn Helgaas, linux-pci, linux-arm-msm,
linux-kernel, Khasim Syed Mohammed, Niklas Cassel, stable
On Wed 13 Feb 07:23 PST 2019, Lorenzo Pieralisi wrote:
> On Fri, Jan 25, 2019 at 03:26:16PM -0800, Bjorn Andersson wrote:
> > Acquiring the reset GPIO low means that reset is being deasserted, this
> > is followed almost immediately with qcom_pcie_host_init() asserting it,
> > initializing it and then finally deasserting it again, for the link to
> > come up.
> >
> > Some PCIe devices requires a minimum time between the initial deassert
> > and subsequent reset cycles. In a platform that boots with the reset
> > GPIO asserted this requirement is being violated by this deassert/assert
> > pulse.
> >
> > Acquiring the reset GPIO high will prevent this by matching the state to
> > the subsequent asserted state.
> >
> > Cc: stable@vger.kernel.org
>
> Missing Fixes: tag, please provide me one so that I can proceed.
>
This applies to the original commit introducing this driver, so:
Fixes: 82a823833f4e ("PCI: qcom: Add Qualcomm PCIe controller driver")
Regards,
Bjorn
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] PCI: qcom: Don't deassert reset GPIO during probe
2019-02-19 5:16 ` Bjorn Andersson
@ 2019-02-19 11:10 ` Lorenzo Pieralisi
0 siblings, 0 replies; 5+ messages in thread
From: Lorenzo Pieralisi @ 2019-02-19 11:10 UTC (permalink / raw)
To: Bjorn Andersson
Cc: Stanimir Varbanov, Bjorn Helgaas, linux-pci, linux-arm-msm,
linux-kernel, Khasim Syed Mohammed, Niklas Cassel, stable
On Mon, Feb 18, 2019 at 09:16:03PM -0800, Bjorn Andersson wrote:
> On Wed 13 Feb 07:23 PST 2019, Lorenzo Pieralisi wrote:
>
> > On Fri, Jan 25, 2019 at 03:26:16PM -0800, Bjorn Andersson wrote:
> > > Acquiring the reset GPIO low means that reset is being deasserted, this
> > > is followed almost immediately with qcom_pcie_host_init() asserting it,
> > > initializing it and then finally deasserting it again, for the link to
> > > come up.
> > >
> > > Some PCIe devices requires a minimum time between the initial deassert
> > > and subsequent reset cycles. In a platform that boots with the reset
> > > GPIO asserted this requirement is being violated by this deassert/assert
> > > pulse.
> > >
> > > Acquiring the reset GPIO high will prevent this by matching the state to
> > > the subsequent asserted state.
> > >
> > > Cc: stable@vger.kernel.org
> >
> > Missing Fixes: tag, please provide me one so that I can proceed.
> >
>
> This applies to the original commit introducing this driver, so:
>
> Fixes: 82a823833f4e ("PCI: qcom: Add Qualcomm PCIe controller driver")
Applied to pci/dwc for v5.1, thanks.
Lorenzo
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-02-19 11:10 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-25 23:26 [PATCH] PCI: qcom: Don't deassert reset GPIO during probe Bjorn Andersson
2019-02-08 14:54 ` Stanimir Varbanov
2019-02-13 15:23 ` Lorenzo Pieralisi
2019-02-19 5:16 ` Bjorn Andersson
2019-02-19 11:10 ` Lorenzo Pieralisi
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).