All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ashutosh Dixit <ashutosh.dixit@intel.com>
To: Bjorn Helgaas <helgaas@kernel.org>
Cc: "Marciniszyn, Mike" <mike.marciniszyn@intel.com>,
	"Dalessandro, Dennis" <dennis.dalessandro@intel.com>,
	Doug Ledford <dledford@redhat.com>,
	"Hefty, Sean" <sean.hefty@intel.com>,
	Hal Rosenstock <hal.rosenstock@gmail.com>,
	"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>
Subject: Re: hfi1 use of PCI internals
Date: Fri, 17 Jun 2016 18:05:43 -0400	[thread overview]
Message-ID: <tnm1t4m8rh3ns.fsf@phwtpriv05.ph.intel.com> (raw)
In-Reply-To: <20160616200817.GA17778@localhost> (Bjorn Helgaas's message of "Thu, 16 Jun 2016 14:08:17 -0600")

On Thu, Jun 16 2016 at 04:08:17 PM, Bjorn Helgaas <helgaas@kernel.org> wrote:
>
> That's a good start, but leads to more questions.  For example, it
> doesn't answer the obvious question of why the driver needs to
> enable/disable ASPM from interrupt context.

For power saving reasons we keep ASPM L1 enabled, but implement a
heuristic to "quickly" disable ASPM L1 when we notice PCIe traffic (as
measured by the interrupt rate) starting up. If interrupt activity
ceases ASPM L1 is re-enabled.

> Disabling ASPM should only require writing the device's Link Control
> register.  The PCI core could probably provide an interface to do that
> in interrupt context.
>
> Enabling ASPM is not latency-critical and could probably be done from
> a work queue outside interrupt context, although conceptually there
> shouldn't be much required here either, and possibly the PCI core
> interface could be improved.

That is true, to keep latencies low we need to disable ASPM from
interrupt context, but re-enabling ASPM is not latency critical.

> It's possible the latency problem could be handled by some sort of
> quirk that overrides the acceptable latency.

Correct, this is another issue that needs to be resolved.

WARNING: multiple messages have this Message-ID (diff)
From: Ashutosh Dixit <ashutosh.dixit@intel.com>
To: Bjorn Helgaas <helgaas@kernel.org>
Cc: "Marciniszyn\, Mike" <mike.marciniszyn@intel.com>, "Dalessandro\,
	Dennis" <dennis.dalessandro@intel.com>,
	Doug Ledford <dledford@redhat.com>, "Hefty\,
	Sean" <sean.hefty@intel.com>,
	Hal Rosenstock <hal.rosenstock@gmail.com>,
	"linux-rdma\@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	"linux-kernel\@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-pci\@vger.kernel.org" <linux-pci@vger.kernel.org>
Subject: Re: hfi1 use of PCI internals
Date: Fri, 17 Jun 2016 18:05:43 -0400	[thread overview]
Message-ID: <tnm1t4m8rh3ns.fsf@phwtpriv05.ph.intel.com> (raw)
In-Reply-To: <20160616200817.GA17778@localhost> (Bjorn Helgaas's message of "Thu, 16 Jun 2016 14:08:17 -0600")

On Thu, Jun 16 2016 at 04:08:17 PM, Bjorn Helgaas <helgaas@kernel.org> wrote:
>
> That's a good start, but leads to more questions.  For example, it
> doesn't answer the obvious question of why the driver needs to
> enable/disable ASPM from interrupt context.

For power saving reasons we keep ASPM L1 enabled, but implement a
heuristic to "quickly" disable ASPM L1 when we notice PCIe traffic (as
measured by the interrupt rate) starting up. If interrupt activity
ceases ASPM L1 is re-enabled.

> Disabling ASPM should only require writing the device's Link Control
> register.  The PCI core could probably provide an interface to do that
> in interrupt context.
>
> Enabling ASPM is not latency-critical and could probably be done from
> a work queue outside interrupt context, although conceptually there
> shouldn't be much required here either, and possibly the PCI core
> interface could be improved.

That is true, to keep latencies low we need to disable ASPM from
interrupt context, but re-enabling ASPM is not latency critical.

> It's possible the latency problem could be handled by some sort of
> quirk that overrides the acceptable latency.

Correct, this is another issue that needs to be resolved.

WARNING: multiple messages have this Message-ID (diff)
From: Ashutosh Dixit <ashutosh.dixit@intel.com>
To: Bjorn Helgaas <helgaas@kernel.org>
Cc: "Marciniszyn\, Mike" <mike.marciniszyn@intel.com>,  "Dalessandro\,
	Dennis" <dennis.dalessandro@intel.com>,
	 Doug Ledford <dledford@redhat.com>,  "Hefty\,
	Sean" <sean.hefty@intel.com>,
	 Hal Rosenstock <hal.rosenstock@gmail.com>,
	 "linux-rdma\@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	 "linux-kernel\@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	 "linux-pci\@vger.kernel.org" <linux-pci@vger.kernel.org>
Subject: Re: hfi1 use of PCI internals
Date: Fri, 17 Jun 2016 18:05:43 -0400	[thread overview]
Message-ID: <tnm1t4m8rh3ns.fsf@phwtpriv05.ph.intel.com> (raw)
In-Reply-To: <20160616200817.GA17778@localhost> (Bjorn Helgaas's message of "Thu, 16 Jun 2016 14:08:17 -0600")

On Thu, Jun 16 2016 at 04:08:17 PM, Bjorn Helgaas <helgaas@kernel.org> wrote:
>
> That's a good start, but leads to more questions.  For example, it
> doesn't answer the obvious question of why the driver needs to
> enable/disable ASPM from interrupt context.

For power saving reasons we keep ASPM L1 enabled, but implement a
heuristic to "quickly" disable ASPM L1 when we notice PCIe traffic (as
measured by the interrupt rate) starting up. If interrupt activity
ceases ASPM L1 is re-enabled.

> Disabling ASPM should only require writing the device's Link Control
> register.  The PCI core could probably provide an interface to do that
> in interrupt context.
>
> Enabling ASPM is not latency-critical and could probably be done from
> a work queue outside interrupt context, although conceptually there
> shouldn't be much required here either, and possibly the PCI core
> interface could be improved.

That is true, to keep latencies low we need to disable ASPM from
interrupt context, but re-enabling ASPM is not latency critical.

> It's possible the latency problem could be handled by some sort of
> quirk that overrides the acceptable latency.

Correct, this is another issue that needs to be resolved.

  parent reply	other threads:[~2016-06-17 22:05 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-16 16:20 hfi1 use of PCI internals Bjorn Helgaas
2016-06-16 16:20 ` Bjorn Helgaas
2016-06-16 18:48 ` Ashutosh Dixit
2016-06-16 18:48   ` Ashutosh Dixit
2016-06-16 18:48   ` Ashutosh Dixit
2016-06-16 20:08   ` Bjorn Helgaas
2016-06-17 13:58     ` Dennis Dalessandro
2016-06-17 22:05     ` Ashutosh Dixit [this message]
2016-06-17 22:05       ` Ashutosh Dixit
2016-06-17 22:05       ` Ashutosh Dixit
2016-06-17 23:04       ` 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=tnm1t4m8rh3ns.fsf@phwtpriv05.ph.intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=dennis.dalessandro@intel.com \
    --cc=dledford@redhat.com \
    --cc=hal.rosenstock@gmail.com \
    --cc=helgaas@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=mike.marciniszyn@intel.com \
    --cc=sean.hefty@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 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.