EEH Support for VFIO Devices
Status from this message: Thanks, applied to ppc-next.
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v19 Latest2 patches 2 repliesApplied
- v182 patches 8 repliesSuperseded
- v172 patches 2 repliesSuperseded
Earlier versions · 19
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v16 | 2 patches | 6 replies | Superseded | |
| v15 | 2 patches | 8 replies | Superseded | |
| v14 | 3 patches | 0 replies | Superseded | |
| v13 | 3 patches | 11 replies | Superseded | |
| v12 | 4 patches | 10 replies | Superseded | |
| v11 | 3 patches | 5 replies | Superseded | |
| v10 posting 2/2 | 3 patches | 7 replies | Superseded | |
| v10 posting 1/2 | 3 patches | 1 reply | Superseded | |
| v9 posting 2/2 | 3 patches | 0 replies | Superseded | |
| v9 posting 1/2 | 3 patches | 2 replies | Superseded | |
| v8 posting 2/2 | 4 patches | 10 replies | Superseded | |
| v8 posting 1/2 | 3 patches | 6 replies | Superseded | |
| v7 | 3 patches | 27 replies | Superseded | |
| v6 | 3 patches | 28 replies | Superseded | |
| v5 | 4 patches | 6 replies | Superseded | |
| v4 RFC | 4 patches | 27 replies | Superseded | |
| v3 RFC | 8 patches | 20 replies | Superseded | |
| v2 RFC | 10 patches | 1 reply | Superseded | |
| v1 RFC | 22 patches | 5 replies | Superseded |
Changes in v19 from the cover letter
* Check the validity of PCI device address in sPAPRPHBClass::eeh_set_option() when enabling EEH functionality.
Patches in v19 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | sPAPR: Implement EEH RTAS callshw/ include/ include/ | +316 | 0 replies | |
| 2/2 | sPAPR: Implement sPAPRPHBClass EEH callbackshw/ hw/ | +116 | 0 replies |
Reviews trailers per patch
All 2 patches have a Reviewed-by or Acked-by.
| Patch | David Gibson |
|---|---|
| 1/2 | R-b |
| 2/2 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [Qemu-devel] [PATCH v19 0/2] EEH Support for VFIO Devices
The series of patches adds support EEH for VFIO PCI devices on sPAPR platform. It requires corresponding host kernel support, which was merged during 3.17 merge window. This patchset has been rebased to Alex Graf's QEMU repository:
git://github.com/agraf/qemu.git (branch: ppc-next)
The implementations notes are below. Please consider for merging!
* RTAS calls are received in spapr_pci.c, sanity check is done there. RTAS handlers handle what they can. If there is something it cannot handle and sPAPRPHBClass EEH callback is defined, it is called.
* sPAPRPHBClass EEH callbacks are only implemented for VFIO now. It does ioctl() to the IOMMU container fd to complete the call. Error codes from that ioctl() are transferred back to the guest.
Changelog
=========
v18 -> v19:
* Check the validity of PCI device address in sPAPRPHBClass::eeh_set_option() when enabling EEH functionality.
v17 -> v18:
* Check options in sPAPRPHBClass callbacks for RTAS call "ibm,set-eeh-option" and "ibm,set-slot-reset".
* Return RTAS_OUT_PARAM_ERROR on errors and RTAS_OUT_NO_ERRORS_FOUND on success as we don't have error log yet.
v16 -> v17:
* Split sPAPRPHBClass::eeh_handler() to multiple callbacks according to David Gibson's suggestion
* Make comments for the form of PE address more precise and merge the condition checking on the option in rtas_ibm_get_config_addr_info2() to improve code readability
* Return RTAS_OUT_PARAM_ERROR for invalid number of arguments to function rtas_ibm_slot_error_detail(), which is inconsistent with PAPR spec
v15 -> v16:
* Drop rtas_handle_eeh_request() and merge the logic to its callers so that more accurate return values can be returned for RTAS calls in the callers
* Always return 1 ("No error log") for RTAS call "ibm,slot-error-detail" and correct wrong return values for other RTAS calls according to David Gibson's suggestions.
* Make fall-through more obvious for case of negative return value from sPAPRPHBClass::eeh_handler()
* Clear the argument buffer passed to ioctl()
* Rename sPAPRPHBClass variable from "info" to "spc"
v14 -> v15:
* Dropped unrelated patch making find_phb()/find_dev() public.
* Checking RTAS parameter number before accessing RTAS parameter buffer for more safety.
* Return hardware error from RTAS call "ibm,set-eeh-option" and "ibm,set-slot-reset" for some cases according to PAPR spec.
v13 -> v14:
* Check if sPAPRPHBState instance is valid before converting it to the corresponding class as pointed by Alex Graf.
v12 -> v13:
* Rebase to Alex Graf's QEMU repository ("ppc-next" branch).
* Drop the patch for header file (vfio.h) changes, which was merged
to QEMU repository by commit a9fd1654 ("linux-headers: update to 3.17-rc7").
* Retested on Emulex adapter and EEH errors are recovered successfully.
Gavin Shan (2):
sPAPR: Implement EEH RTAS calls
sPAPR: Implement sPAPRPHBClass EEH callbacks
hw/ppc/spapr_pci.c | 271 ++++++++++++++++++++++++++++++++++++++++++++ hw/ppc/spapr_pci_vfio.c | 115 +++++++++++++++++++ hw/vfio/common.c | 1 + include/hw/pci-host/spapr.h | 4 + include/hw/ppc/spapr.h | 43 ++++++- 5 files changed, 432 insertions(+), 2 deletions(-)
Signature · 1 line
1.8.3.2