linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: Kai-Heng Feng <kai.heng.feng@canonical.com>,
	bhelgaas@google.com, koba.ko@canonical.com,
	sathyanarayanan.kuppuswamy@linux.intel.com,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] PCI: Add helper to check if any of ancestor device support D3cold
Date: Sat, 26 Aug 2023 08:11:05 -0500	[thread overview]
Message-ID: <20230826131105.GA691555@bhelgaas> (raw)
In-Reply-To: <20230825063948.GY3465@black.fi.intel.com>

On Fri, Aug 25, 2023 at 09:39:48AM +0300, Mika Westerberg wrote:
> On Fri, Aug 25, 2023 at 01:43:08PM +0800, Kai-Heng Feng wrote:
> > On Fri, Aug 25, 2023 at 1:29 PM Mika Westerberg
> > <mika.westerberg@linux.intel.com> wrote:
> > > On Thu, Aug 24, 2023 at 09:46:00PM +0800, Kai-Heng Feng wrote:
> > > > On Thu, Aug 24, 2023 at 7:57 PM Mika Westerberg
> > > > <mika.westerberg@linux.intel.com> wrote:

> > I think what Bjorn suggested is to keep AER enabled for D3hot, and
> > only disable it for D3cold and S3.
> > 
> > > > Unless there are cases when device firmware behave differently to
> > > > D3hot? Then maybe it's better to disable AER for both D3hot, D3cold
> > > > and system S3.
> > >
> > > Yes, this makes sense.
> > 
> > I agree that differentiate between D3hot and D3cold unnecessarily make
> > things more complicated, but Bjorn suggested errors reported by AER
> > under D3hot should still be recorded.
> > Do you have more compelling data to persuade Bjorn that AER should be
> > disabled for both D3 states?
> 
> Is there even an AER error that can happen when a device is in D3hot
> (link is in L1) or D3cold (link is in L2/3)? I'm not an expert in AER
> but AFAICT these errors are reported when the device is in active state
> not when it is in low power state.

I don't think a device in D3cold can signal its own errors.  But the
link transition to L2/L3 as a device goes to D3cold may cause the
bridge above to log an error.  And of course a config access to a
device in D3cold will probably result in an Unsupported Request being
logged by the bridge above it.  I think these are the sorts of errors
we do need to avoid or ignore somehow.

But Configuration and Message requests definitely happen in D3hot, and
they can cause errors reported via AER.  The spec (r6.0, sec 2.2.8)
recommends that Messages be handled the same in D0-D3hot.

PTM is an example of where we had errors being reported at suspend/
resume because we had it configured incorrectly.  If we disabled AER
in D3hot we might not learn about that kind of configuration problem.
That's what makes me think there's some value in keeping AER enabled
in D3hot.

Bjorn

  reply	other threads:[~2023-08-26 13:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-24  4:46 [PATCH 1/3] PCI: Add helper to check if any of ancestor device support D3cold Kai-Heng Feng
2023-08-24  4:46 ` [PATCH 2/3] PCI/AER: Disable AER service on suspend Kai-Heng Feng
2023-08-24  4:46 ` [PATCH 3/3] PCI/DPC: Disable DPC " Kai-Heng Feng
2023-08-24 11:56 ` [PATCH 1/3] PCI: Add helper to check if any of ancestor device support D3cold Mika Westerberg
2023-08-24 13:46   ` Kai-Heng Feng
2023-08-25  5:29     ` Mika Westerberg
2023-08-25  5:43       ` Kai-Heng Feng
2023-08-25  6:39         ` Mika Westerberg
2023-08-26 13:11           ` Bjorn Helgaas [this message]
2023-08-28  7:29             ` Kai-Heng Feng
2023-08-28 16:23               ` Bjorn Helgaas

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=20230826131105.GA691555@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=bhelgaas@google.com \
    --cc=kai.heng.feng@canonical.com \
    --cc=koba.ko@canonical.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=sathyanarayanan.kuppuswamy@linux.intel.com \
    /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;
as well as URLs for NNTP newsgroup(s).