linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sam Bobroff <sbobroff@linux.ibm.com>
To: Michael Ellerman <mpe@ellerman.id.au>
Cc: linuxppc-dev@lists.ozlabs.org, linux-pci@vger.kernel.org,
	bhelgaas@google.com, bryantly@linux.vnet.ibm.com
Subject: Re: [PATCH v2 1/1] powerpc/pseries: fix EEH recovery of some IOV devices
Date: Mon, 30 Jul 2018 11:58:05 +1000	[thread overview]
Message-ID: <20180730015804.GA10188@tungsten.ozlabs.ibm.com> (raw)
In-Reply-To: <87in5ymp03.fsf@concordia.ellerman.id.au>

[-- Attachment #1: Type: text/plain, Size: 2101 bytes --]

On Mon, Jul 02, 2018 at 10:59:24AM +1000, Michael Ellerman wrote:
> Sam Bobroff <sbobroff@linux.ibm.com> writes:
> 
> > EEH recovery currently fails on pSeries for some IOV capable PCI
> > devices, if CONFIG_PCI_IOV is on and the hypervisor doesn't provide
> > certain device tree properties for the device. (Found on an IOV
> > capable device using the ipr driver.)
> >
> > Recovery fails in pci_enable_resources() at the check on r->parent,
> > because r->flags is set and r->parent is not.  This state is due to
> > sriov_init() setting the start, end and flags members of the IOV BARs
> > but the parent not being set later in
> > pseries_pci_fixup_iov_resources(), because the
> > "ibm,open-sriov-vf-bar-info" property is missing.
> >
> > Correct this by zeroing the resource flags for IOV BARs when they
> > can't be configured.
> >
> > Signed-off-by: Sam Bobroff <sbobroff@linux.ibm.com>
> > ---
> > Hi,
> >
> > This is a fix to allow EEH recovery to succeed in a specific situation,
> > which I've tried to explain in the commit message.
> >
> > As with the RFC version, the IOV BARs are disabled by setting the resource
> > flags to 0 but the other fields are now left as-is because that is what is done
> > elsewhere (see sriov_init() and __pci_read_base()).
> >
> > I've also examined the concern raised by Bjorn Helgaas, that VFs could be
> > enabled later after the BARs are disabled, and it already seems safe: enabling
> > VFs (on pseries) depends on another device tree property,
> > "ibm,number-of-configurable-vfs" as well as support for the RTAS function
> > "ibm_map_pes". Since these are all part of the hypervisor's support for IOV it
> > seems unlikely that we would ever see some of them but not all. (None are
> > currently provided by QEMU/KVM.) (Additionally, the ipr driver on which the EEH
> > recovery failure was discovered doesn't even seem to have SR-IOV support so it
> > certainly can't enable VFs.)
> 
> Can you fold/reword the above into the change log, it seems like useful
> detail.
> 
> cheers

Sure, sounds good.


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

      reply	other threads:[~2018-07-30  3:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-25  0:31 [PATCH v2 1/1] powerpc/pseries: fix EEH recovery of some IOV devices Sam Bobroff
2018-05-30 13:55 ` Bryant G. Ly
2018-06-30  1:53 ` Bjorn Helgaas
2018-07-02  0:59 ` Michael Ellerman
2018-07-30  1:58   ` Sam Bobroff [this message]

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=20180730015804.GA10188@tungsten.ozlabs.ibm.com \
    --to=sbobroff@linux.ibm.com \
    --cc=bhelgaas@google.com \
    --cc=bryantly@linux.vnet.ibm.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    /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).