* Re: [PATCH RESEND] PCI: amd-mdb: Assert PERST# on shutdown
[not found] <20260427121227.290604-1-sai.krishna.musham@amd.com>
@ 2026-05-12 13:14 ` Manivannan Sadhasivam
2026-05-13 21:43 ` Bjorn Helgaas
1 sibling, 0 replies; 2+ messages in thread
From: Manivannan Sadhasivam @ 2026-05-12 13:14 UTC (permalink / raw)
To: bhelgaas, lpieralisi, robh, krzk+dt, conor+dt, cassel,
Krzysztof Wilczyński, Sai Krishna Musham
Cc: linux-pci, devicetree, linux-kernel, michal.simek,
bharat.kumar.gogada, thippeswamy.havalige
On Mon, 27 Apr 2026 17:42:27 +0530, Sai Krishna Musham wrote:
> Add a shutdown handler for the AMD MDB PCIe host controller that
> asserts the PERST# signal via GPIO before the system powers off or
> reboots. This ensures the connected PCIe endpoint is held in reset
> during shutdown.
Applied, thanks!
[1/1] PCI: amd-mdb: Assert PERST# on shutdown
commit: 0492461a0508d88f2b63de4f7f4e71b38078de20
Best regards,
--
Manivannan Sadhasivam <mani@kernel.org>
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH RESEND] PCI: amd-mdb: Assert PERST# on shutdown
[not found] <20260427121227.290604-1-sai.krishna.musham@amd.com>
2026-05-12 13:14 ` [PATCH RESEND] PCI: amd-mdb: Assert PERST# on shutdown Manivannan Sadhasivam
@ 2026-05-13 21:43 ` Bjorn Helgaas
1 sibling, 0 replies; 2+ messages in thread
From: Bjorn Helgaas @ 2026-05-13 21:43 UTC (permalink / raw)
To: Sai Krishna Musham
Cc: bhelgaas, lpieralisi, kw, mani, robh, krzk+dt, conor+dt, cassel,
linux-pci, devicetree, linux-kernel, michal.simek,
bharat.kumar.gogada, thippeswamy.havalige
On Mon, Apr 27, 2026 at 05:42:27PM +0530, Sai Krishna Musham wrote:
> Add a shutdown handler for the AMD MDB PCIe host controller that
> asserts the PERST# signal via GPIO before the system powers off or
> reboots. This ensures the connected PCIe endpoint is held in reset
> during shutdown.
I see a few other drivers (dwc/pci-imx6.c, dwc/pcie-fu740.c,
pcie-iproc-platform.c) that do something similar, but it doesn't look
consistent. *Should* this be consistent across all drivers?
> Signed-off-by: Sai Krishna Musham <sai.krishna.musham@amd.com>
> ---
> drivers/pci/controller/dwc/pcie-amd-mdb.c | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/drivers/pci/controller/dwc/pcie-amd-mdb.c b/drivers/pci/controller/dwc/pcie-amd-mdb.c
> index 7e50e11fbffd..69d21b4727e4 100644
> --- a/drivers/pci/controller/dwc/pcie-amd-mdb.c
> +++ b/drivers/pci/controller/dwc/pcie-amd-mdb.c
> @@ -507,6 +507,14 @@ static int amd_mdb_pcie_probe(struct platform_device *pdev)
> return amd_mdb_add_pcie_port(pcie, pdev);
> }
>
> +static void amd_mdb_pcie_shutdown(struct platform_device *pdev)
> +{
> + struct amd_mdb_pcie *pcie = platform_get_drvdata(pdev);
> +
> + if (pcie->perst_gpio)
> + gpiod_set_value_cansleep(pcie->perst_gpio, 1);
> +}
> +
> static const struct of_device_id amd_mdb_pcie_of_match[] = {
> {
> .compatible = "amd,versal2-mdb-host",
> @@ -521,6 +529,7 @@ static struct platform_driver amd_mdb_pcie_driver = {
> .suppress_bind_attrs = true,
> },
> .probe = amd_mdb_pcie_probe,
> + .shutdown = amd_mdb_pcie_shutdown,
> };
>
> builtin_platform_driver(amd_mdb_pcie_driver);
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-05-13 21:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20260427121227.290604-1-sai.krishna.musham@amd.com>
2026-05-12 13:14 ` [PATCH RESEND] PCI: amd-mdb: Assert PERST# on shutdown Manivannan Sadhasivam
2026-05-13 21:43 ` Bjorn Helgaas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox