From: Jon Hunter <jonathanh@nvidia.com>
To: Manivannan Sadhasivam <mani@kernel.org>,
Bjorn Helgaas <helgaas@kernel.org>
Cc: manivannan.sadhasivam@oss.qualcomm.com,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
"Rob Herring" <robh@kernel.org>,
linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org,
"David E. Box" <david.e.box@linux.intel.com>,
"Kai-Heng Feng" <kai.heng.feng@canonical.com>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Heiner Kallweit" <hkallweit1@gmail.com>,
"Chia-Lin Kao" <acelan.kao@canonical.com>,
"linux-tegra@vger.kernel.org" <linux-tegra@vger.kernel.org>,
"Keith Busch" <kbusch@kernel.org>, "Jens Axboe" <axboe@kernel.dk>,
"Christoph Hellwig" <hch@lst.de>,
"Sagi Grimberg" <sagi@grimberg.me>,
linux-nvme@lists.infradead.org
Subject: Re: [PATCH v2 1/2] PCI/ASPM: Override the ASPM and Clock PM states set by BIOS for devicetree platforms
Date: Fri, 23 Jan 2026 10:55:28 +0000 [thread overview]
Message-ID: <bf37b6a5-268d-4c07-a536-a826b3d5953b@nvidia.com> (raw)
In-Reply-To: <e44c330b-778b-4fa1-b678-fa909cc05b03@nvidia.com>
On 22/01/2026 19:14, Jon Hunter wrote:
...
>> I think what is going on here is that since before commits
>> f3ac2ff14834 and
>> df5192d9bb0e, !pcie_aspm_enabled() check was passing as ASPM was not
>> enabled for
>> the device (and upstream port) and after those commits, this check is not
>> passing and the NVMe driver is not shutting down the controller and
>> expects the
>> link to be in L0/L1ss. But the Tegra controller driver initiates L2/L3
>> transition, and also turns off the device. So all the NVMe context is
>> lost
>> during suspend and while resuming, the NVMe driver got confused due to
>> lost
>> context.
>>
>> Jon, could you please try the below hack and see if it fixes the issue?
>>
>> diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c
>> index 0e4caeab739c..4b8d261117f5 100644
>> --- a/drivers/nvme/host/pci.c
>> +++ b/drivers/nvme/host/pci.c
>> @@ -3723,7 +3723,7 @@ static int nvme_suspend(struct device *dev)
>> * state (which may not be possible if the link is up).
>> */
>> if (pm_suspend_via_firmware() || !ctrl->npss ||
>> - !pcie_aspm_enabled(pdev) ||
>> + pcie_aspm_enabled(pdev) ||
>> (ndev->ctrl.quirks & NVME_QUIRK_SIMPLE_SUSPEND))
>> return nvme_disable_prepare_reset(ndev, true);
>> This will confirm whether the issue is due to Tegra controller driver
>> breaking
>> the NVMe driver assumption or not.
>
> Yes that appears to be working! I will test some more boards to confirm.
So yes with the above all boards appear to be working fine.
How is this usually coordinated between the NVMe driver and Host
controller driver? It is not clear to me exactly where the problem is
and if the NVMe is not shutting down, then what should be preventing the
Host controller from shutting down.
Thanks
Jon
--
nvpublic
next prev parent reply other threads:[~2026-01-23 10:55 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20250922-pci-dt-aspm-v2-0-2a65cf84e326@oss.qualcomm.com>
[not found] ` <20250922-pci-dt-aspm-v2-1-2a65cf84e326@oss.qualcomm.com>
2026-01-22 12:12 ` [PATCH v2 1/2] PCI/ASPM: Override the ASPM and Clock PM states set by BIOS for devicetree platforms Jon Hunter
2026-01-22 13:17 ` Manivannan Sadhasivam
2026-01-22 13:43 ` Jon Hunter
2026-01-22 14:39 ` Manivannan Sadhasivam
2026-01-22 15:29 ` Bjorn Helgaas
2026-01-22 17:01 ` Manivannan Sadhasivam
2026-01-22 19:14 ` Jon Hunter
2026-01-23 10:55 ` Jon Hunter [this message]
2026-01-23 13:56 ` Manivannan Sadhasivam
2026-01-23 14:39 ` Jon Hunter
2026-02-16 14:03 ` Jon Hunter
2026-02-16 14:18 ` Manivannan Sadhasivam
2026-02-16 14:35 ` Jon Hunter
2026-02-19 17:42 ` Jon Hunter
2026-02-26 10:34 ` Jon Hunter
2026-02-26 11:08 ` Manivannan Sadhasivam
2026-02-26 16:55 ` Jon Hunter
2026-03-03 16:27 ` Manivannan Sadhasivam
2026-02-26 11:16 ` Manivannan Sadhasivam
2026-02-26 16:52 ` Jon Hunter
2026-03-03 16:17 ` Manivannan Sadhasivam
2026-03-06 16:03 ` Jon Hunter
2026-03-09 8:00 ` Manivannan Sadhasivam
2026-02-16 17:19 ` Claudiu Beznea
2026-02-18 13:56 ` Manivannan Sadhasivam
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=bf37b6a5-268d-4c07-a536-a826b3d5953b@nvidia.com \
--to=jonathanh@nvidia.com \
--cc=acelan.kao@canonical.com \
--cc=axboe@kernel.dk \
--cc=bhelgaas@google.com \
--cc=david.e.box@linux.intel.com \
--cc=hch@lst.de \
--cc=helgaas@kernel.org \
--cc=hkallweit1@gmail.com \
--cc=kai.heng.feng@canonical.com \
--cc=kbusch@kernel.org \
--cc=kwilczynski@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=mani@kernel.org \
--cc=manivannan.sadhasivam@oss.qualcomm.com \
--cc=rafael@kernel.org \
--cc=robh@kernel.org \
--cc=sagi@grimberg.me \
/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