public inbox for linux-pci@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Manivannan Sadhasivam <mani@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>,
	"Keith Busch" <kbusch@kernel.org>, "Jens Axboe" <axboe@kernel.dk>,
	"Christoph Hellwig" <hch@lst.de>,
	"Sagi Grimberg" <sagi@grimberg.me>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-msm@vger.kernel.org, linux-nvme@lists.infradead.org
Subject: Re: [PATCH 3/4] PCI: qcom: Indicate broken L1ss exit during resume from system suspend
Date: Wed, 22 Apr 2026 18:49:38 -0500	[thread overview]
Message-ID: <20260422234938.GA416865@bhelgaas> (raw)
In-Reply-To: <bkejoqdchyv55efsyl7o6b3ewiwaj5kbc2hgltxt5vwqdvt5yf@cxvwcjo5zcrp>

On Tue, Apr 21, 2026 at 10:41:08PM +0530, Manivannan Sadhasivam wrote:
> On Mon, Apr 20, 2026 at 03:49:15PM -0500, Bjorn Helgaas wrote:
> > On Sat, Apr 18, 2026 at 11:09:11AM +0530, Manivannan Sadhasivam wrote:
> > > On Fri, Apr 17, 2026 at 05:26:15PM -0500, Bjorn Helgaas wrote:
> > > ...
> > 
> > > > Does L1.2 have to meet the advertised L1 Exit Latency?  I assume
> > > > maybe it does because I don't see an exception for L1.x or any
> > > > exit latencies advertised in the L1 PM Substates Capability.
> > > 
> > > As per my understanding, 'L1 Exit Latency' only covers ASPM L1
> > > state, not L1ss.  Because, 'L1 Exit Latency' field exists even
> > > before L1 PM Substates got introduced in r3.1. So it doesn't cover
> > > L1.2 exit latency.

FWIW, this FAQ from https://pcisig.com/faq?keys=3.0 confirms your
understanding:

  Section 7.8.6 - Is the L1 Exit Latency in the Link Capabilities
  register only the ASPM L1.0 exit latency or does it include the
  added ASPM L1.2 to ASPM L1.0 latency?

    The ASPM L1 Exit Latency in the Link Capabilities register
    indicates the L1/L1.0 to L0 latency, and does not include added
    latency due to Clock Power Management, L1.1 or L1.2.

> > > > Regardless, I'd be kind of surprised if *any* system could meet an
> > > > L1.2 exit latency from a system suspend situation where PHY power
> > > > is removed.  On ACPI systems, the OS doesn't know how to remove
> > > > PHY power, so I don't think that situation can happen unless
> > > > firmware is involved in the suspend.
> > > 
> > > Yes, you are right. Even for systems turning off the PHY completely,
> > > they should have some mechanism to detect the CLKREQ# assert and
> > > turn ON the PHY within the expected time.
> > 
> > What would the expected time be?
> 
> That's mostly L10_REFCLK_ON + T_COMMONMODE. But nevertheless, the
> system wakeup and controller driver resume() time would be far
> greater than it.

This patch sets "pp->bridge->broken_l1ss_resume = true".  I'm trying
to understand how we know to set this.  There might be other platforms
that need to do this but I don't know how to identify them.

This comment:

  + * Some host bridges power off the PHY to enter deep low-power modes
  + * during system suspend. Exiting L1 PM Substates from this condition
  + * violates strict timing requirements and results in Link Down (LDn).
  + * On such platforms, the endpoint must be prepared for context loss.

suggests that the L1.2 exit takes too long and results in the link
going down, which is essentially a reset for the downstream device,
which would destroy the context.

Is there some spec language that determines how long the Downstream
Port waits for the L1.2 exit before it gives up and decides the link
is down?

  reply	other threads:[~2026-04-22 23:49 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-14 15:59 [PATCH 0/4] PCI: Introduce pci_dev_suspend_retention_supported() API Manivannan Sadhasivam via B4 Relay
2026-04-14 15:59 ` [PATCH 1/4] PCI: Introduce an API to check if RC/platform can retain device context during suspend Manivannan Sadhasivam via B4 Relay
2026-04-16 19:18   ` Bjorn Helgaas
2026-04-17 11:11     ` Manivannan Sadhasivam
2026-04-14 15:59 ` [PATCH 2/4] PCI: Indicate context lost if L1ss exit is broken during resume from system suspend Manivannan Sadhasivam via B4 Relay
2026-04-14 15:59 ` [PATCH 3/4] PCI: qcom: Indicate broken L1ss exit " Manivannan Sadhasivam via B4 Relay
2026-04-16 19:20   ` Bjorn Helgaas
2026-04-17 12:06     ` Manivannan Sadhasivam
2026-04-17 22:26       ` Bjorn Helgaas
2026-04-18  5:39         ` Manivannan Sadhasivam
2026-04-20 20:49           ` Bjorn Helgaas
2026-04-21 17:11             ` Manivannan Sadhasivam
2026-04-22 23:49               ` Bjorn Helgaas [this message]
2026-04-14 15:59 ` [PATCH 4/4] nvme-pci: Use pci_dev_suspend_retention_supported() API during suspend Manivannan Sadhasivam via B4 Relay
2026-04-22  6:33   ` Christoph Hellwig
2026-04-16 19:11 ` [PATCH 0/4] PCI: Introduce pci_dev_suspend_retention_supported() API Bjorn Helgaas
2026-04-17 11:04   ` Manivannan Sadhasivam
2026-04-17 22:29     ` Bjorn Helgaas
2026-04-18  5:16       ` 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=20260422234938.GA416865@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=bhelgaas@google.com \
    --cc=hch@lst.de \
    --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=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