Linux PCI subsystem development
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
To: "Krishna Chaitanya Chundru" <krishna.chundru@oss.qualcomm.com>,
	"Vinod Koul" <vkoul@kernel.org>,
	"Neil Armstrong" <neil.armstrong@linaro.org>,
	"Philipp Zabel" <p.zabel@pengutronix.de>,
	"Jingoo Han" <jingoohan1@gmail.com>,
	"Manivannan Sadhasivam" <mani@kernel.org>,
	"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
	"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
	"Rob Herring" <robh@kernel.org>,
	"Bjorn Helgaas" <bhelgaas@google.com>
Cc: linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org,
	linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org
Subject: Re: [PATCH 3/5] PCI: qcom: Keep PERST# GPIO state as-is during probe
Date: Fri, 9 Jan 2026 12:14:05 +0100	[thread overview]
Message-ID: <be6aecbc-3ea4-4282-b777-0dc8ae1b8c26@oss.qualcomm.com> (raw)
In-Reply-To: <20260109-link_retain-v1-3-7e6782230f4b@oss.qualcomm.com>

On 1/9/26 8:21 AM, Krishna Chaitanya Chundru wrote:
> The PERST# signal is used to reset PCIe devices. Currently, the driver
> requests the GPIO with GPIOD_OUT_HIGH, which forces the line high
> during probe. This can unintentionally assert reset early, breaking

                                         ^ de-assert, probably?

Konrad

> link retention or causing unexpected device behavior.
> 
> Change the request to use GPIOD_ASIS so the driver preserves the
> existing state configured by the bootloader or firmware. This allows
> platforms that manage PERST# externally to maintain proper reset
> sequencing.
> 
> Signed-off-by: Krishna Chaitanya Chundru <krishna.chundru@oss.qualcomm.com>
> ---
>  drivers/pci/controller/dwc/pcie-qcom.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
> index 7b92e7a1c0d9364a9cefe1450818f9cbfc7fd3ac..9342f9c75f1c3017b55614069a7aa821a6fb8da7 100644
> --- a/drivers/pci/controller/dwc/pcie-qcom.c
> +++ b/drivers/pci/controller/dwc/pcie-qcom.c
> @@ -1711,7 +1711,7 @@ static int qcom_pcie_parse_port(struct qcom_pcie *pcie, struct device_node *node
>  	int ret;
>  
>  	reset = devm_fwnode_gpiod_get(dev, of_fwnode_handle(node),
> -				      "reset", GPIOD_OUT_HIGH, "PERST#");
> +				      "reset", GPIOD_ASIS, "PERST#");
>  	if (IS_ERR(reset))
>  		return PTR_ERR(reset);
>  
> @@ -1772,7 +1772,7 @@ static int qcom_pcie_parse_legacy_binding(struct qcom_pcie *pcie)
>  	if (IS_ERR(phy))
>  		return PTR_ERR(phy);
>  
> -	reset = devm_gpiod_get_optional(dev, "perst", GPIOD_OUT_HIGH);
> +	reset = devm_gpiod_get_optional(dev, "perst", GPIOD_ASIS);
>  	if (IS_ERR(reset))
>  		return PTR_ERR(reset);
>  
> 

  reply	other threads:[~2026-01-09 11:14 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-09  7:21 [PATCH 0/5] PCI: qcom: Add link retention support Krishna Chaitanya Chundru
2026-01-09  7:21 ` [PATCH 1/5] phy: qcom: qmp-pcie: Skip PHY reset if already up Krishna Chaitanya Chundru
2026-01-09  9:23   ` Abel Vesa
2026-01-09 13:08   ` Dmitry Baryshkov
2026-01-09 13:10     ` Neil Armstrong
2026-01-09 14:03       ` Dmitry Baryshkov
2026-01-14  9:36         ` Vinod Koul
2026-02-16 14:53         ` Manivannan Sadhasivam
2026-02-16 14:56           ` Konrad Dybcio
2026-01-09  7:21 ` [PATCH 2/5] PCI: dwc: Add support for retaining link during host init Krishna Chaitanya Chundru
2026-01-09 15:53   ` Bjorn Helgaas
2026-01-12 11:29     ` Konrad Dybcio
2026-01-22  8:55     ` Krishna Chaitanya Chundru
2026-01-09  7:21 ` [PATCH 3/5] PCI: qcom: Keep PERST# GPIO state as-is during probe Krishna Chaitanya Chundru
2026-01-09 11:14   ` Konrad Dybcio [this message]
2026-02-16 14:58   ` Manivannan Sadhasivam
2026-01-09  7:21 ` [PATCH 4/5] PCI: qcom: Add link retention support Krishna Chaitanya Chundru
2026-02-16 15:08   ` Manivannan Sadhasivam
2026-01-09  7:21 ` [PATCH 5/5] PCI: qcom: enable Link retain logic for Hamoa Krishna Chaitanya Chundru
2026-01-09 13:09   ` Dmitry Baryshkov
2026-01-22  8:59     ` Krishna Chaitanya Chundru
2026-01-15  2:16 ` [PATCH 0/5] PCI: qcom: Add link retention support Qiang Yu

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=be6aecbc-3ea4-4282-b777-0dc8ae1b8c26@oss.qualcomm.com \
    --to=konrad.dybcio@oss.qualcomm.com \
    --cc=bhelgaas@google.com \
    --cc=jingoohan1@gmail.com \
    --cc=krishna.chundru@oss.qualcomm.com \
    --cc=kwilczynski@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-phy@lists.infradead.org \
    --cc=lpieralisi@kernel.org \
    --cc=mani@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=p.zabel@pengutronix.de \
    --cc=robh@kernel.org \
    --cc=vkoul@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