All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mika Westerberg <mika.westerberg@linux.intel.com>
To: Bjorn Helgaas <helgaas@kernel.org>
Cc: Lukas Wunner <lukas@wunner.de>,
	Mahesh J Salgaonkar <mahesh@linux.ibm.com>,
	oohall@gmail.com, Chris Chiu <chris.chiu@canonical.com>,
	linux-pci@vger.kernel.org, Ashok Raj <ashok.raj@intel.com>,
	Sathyanarayanan Kuppuswamy 
	<sathyanarayanan.kuppuswamy@linux.intel.com>,
	Sheng Bi <windy.bi.enflame@gmail.com>,
	Ravi Kishore Koppuravuri <ravi.kishore.koppuravuri@intel.com>,
	Stanislav Spassov <stanspas@amazon.de>,
	Yang Su <yang.su@linux.alibaba.com>,
	shuo.tan@linux.alibaba.com
Subject: Re: [PATCH] PCI/PM: Wait longer after reset when active link reporting is supported
Date: Tue, 28 Mar 2023 12:26:43 +0300	[thread overview]
Message-ID: <20230328092643.GF33314@black.fi.intel.com> (raw)
In-Reply-To: <20230327144050.GA2835405@bhelgaas>

On Mon, Mar 27, 2023 at 09:40:50AM -0500, Bjorn Helgaas wrote:
> On Mon, Mar 27, 2023 at 12:42:50PM +0300, Mika Westerberg wrote:
> > On Sun, Mar 26, 2023 at 08:22:07AM +0200, Lukas Wunner wrote:
> > > On Wed, Mar 22, 2023 at 05:16:24PM -0500, Bjorn Helgaas wrote:
> > > > On Tue, Mar 21, 2023 at 11:50:31AM +0200, Mika Westerberg wrote:
> 
> > > > After ac91e6980563, we called pci_bridge_wait_for_secondary_bus() with
> > > > timeouts of either:
> > > > 
> > > >   60s for reset (pci_bridge_secondary_bus_reset() or
> > > >       dpc_reset_link()), or
> > > > 
> > > >    1s for resume (pci_pm_resume_noirq() or pci_pm_runtime_resume() via
> > > >       pci_pm_bridge_power_up_actions())
> > > > 
> > > > If I'm reading this right, the main changes of this patch are:
> > > > 
> > > >   - For slow links (<= 5 GT/s), we sleep 100ms, then previously waited
> > > >     up to 1s (resume) or 60s (reset) for the device to be ready.  Now
> > > >     we will wait a max of 1s for both resume and reset.
> > > > 
> > > >   - For fast links (> 5 GT/s) we wait up to 100ms for the link to come
> > > >     up and fail if it does not.  If the link did come up in 100ms, we
> > > >     previously waited up to 1s (resume) or 60s (reset).  Now we will
> > > >     wait up to 60s for both resume and reset.
> > > > 
> > > > So this *reduces* the time we wait for slow links after reset, and
> > > > *increases* the time for fast links after resume.  Right?
> > > 
> > > Good point.  So now the wait duration hinges on the link speed
> > > rather than reset versus resume.
> > > ...
> 
> > I can update the patch accordingly.
> 
> If you do an update, is it possible to split into two patches so one
> increases the time for resume for fast links and the other decreases
> the time for reset on slow links?  I'm thinking about potential debug
> efforts where it might be easier to untangle things if they are
> separate.

Yes, sure.

  reply	other threads:[~2023-03-28  9:26 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-21  9:50 [PATCH] PCI/PM: Wait longer after reset when active link reporting is supported Mika Westerberg
2023-03-22 22:16 ` Bjorn Helgaas
2023-03-23  9:41   ` Mika Westerberg
2023-03-23 13:29     ` Mika Westerberg
2023-03-26  6:22   ` Lukas Wunner
2023-03-27  9:42     ` Mika Westerberg
2023-03-27 14:40       ` Bjorn Helgaas
2023-03-28  9:26         ` Mika Westerberg [this message]
2023-03-27 15:08       ` Sathyanarayanan Kuppuswamy
2023-03-28  9:29         ` Mika Westerberg

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=20230328092643.GF33314@black.fi.intel.com \
    --to=mika.westerberg@linux.intel.com \
    --cc=ashok.raj@intel.com \
    --cc=chris.chiu@canonical.com \
    --cc=helgaas@kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lukas@wunner.de \
    --cc=mahesh@linux.ibm.com \
    --cc=oohall@gmail.com \
    --cc=ravi.kishore.koppuravuri@intel.com \
    --cc=sathyanarayanan.kuppuswamy@linux.intel.com \
    --cc=shuo.tan@linux.alibaba.com \
    --cc=stanspas@amazon.de \
    --cc=windy.bi.enflame@gmail.com \
    --cc=yang.su@linux.alibaba.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.