qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCHv2 0/7] Allow EEH on spapr-pci-host-bridge devices


From: David Gibson
Subject: [Qemu-devel] [PATCHv2 0/7] Allow EEH on spapr-pci-host-bridge devices
Date: Mon, 29 Feb 2016 18:06:20 +1100

For historical reasons, the spapr machine type has two PCI host bridge
implementations: spapr-pci-host-bridge, and
spapr-vfio-pci-host-bridge.  The latter was (duh) designed for VFIO
devices, but later reworks mean it's not necessary for that, and VFIO
can be used on the regular host bridge.

The only remaining difference is that EEH (Enhanced Error Handling -
IBM's interface with similar purpose to AER) is only supported on the
spapr-vfio-pci-host-bridge device.

This series corrects this, allowing EEH operations on the regular host
bridge.  That allows the special VFIO host bridge (we leave a stub,
for backwards compatibility).

EEH is only supported for VFIO devices, for the time being, and due to
bugs in the kernel implementation, it is only usable when the host
bridge only has devices from a single (host-side) IOMMU group
("Partitionable Endpoint", in IBM terminology).  That's an annoying
limitation which we hope to lift someday, but it's no worse than now,
since the spapr-vfio-pci-host-bridge only permits devices from a
single IOMMU group in any case (although it doesn't properly enforce
that).

I wrote these a while back, and I'm not sure why they got sidelined -
I suspect I was looking for testing from Gavin Shan, not realising
then that he was no longer working on EEH.  In any case, I'm hoping we
can squeeze this change into 2.6, so we don't need to carry the broken
spapr-vfio-pci-host-bridge device any longer.


Alex,

If you could look at the 2 patches in this series affecting core VFIO
code ASAP, that would be really helpful.  Also, if you could let me
know if you would like to take those through your tree, or if I can
take them through mine, with your ack.

Changes since v1:
  * Don't consider containers with no groups as being able to support
    EEH, which is a safer option
  * To avoid build problems on non-Linux hosts, I no longer merge most
    of the code into spapr_pci.c, instead leaving it in helpers in
    spapr_pci_vfio.c, just no longer part of its own special device
    type (this approach suggested by Alexey Kardashevskiy).

David Gibson (7):
  vfio: Start improving VFIO/EEH interface
  spapr_pci: Switch to vfio_eeh_as_op() interface
  spapr_pci: Eliminate class callbacks
  spapr_pci: Allow EEH on spapr-pci-host-bridge
  spapr_pci: (Mostly) remove spapr-pci-vfio-host-bridge
  spapr_pci: Remove finish_realize hook
  vfio: Eliminate vfio_container_ioctl()

 hw/ppc/spapr_pci.c          |  63 +++++++--------------
 hw/ppc/spapr_pci_vfio.c     | 131 +++++++++++++++-----------------------------
 hw/vfio/common.c            | 101 +++++++++++++++++++++++-----------
 include/hw/pci-host/spapr.h |  64 +++++++++++++---------
 include/hw/vfio/vfio.h      |   4 +-
 5 files changed, 173 insertions(+), 190 deletions(-)

-- 
2.5.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]