Skip to content

scsi-generic: error handling overhaul

Paolo Bonzini qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest0 of 11 patches 1 replyIn review

Patches in v1 No applies recorded yet

None of the 11 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 00/11] scsi-generic: error handling overhaul

This series is mostly a refresh of Hannes's patches at
https://patchew.org/QEMU/[email protected]/, which haven't been applied yet because they broke the testsuite.

In addition to Hannes's introduction of host status in the SCSI subsystem, which survives mostly in patches 3 and 6-10, I am also changing scsi_handle_rw_error to always pass down guest-recoverable sense codes, even if rerror=stop/werror=stop. Without this change, [rw]error=stop are mostly unusable because the guest will stop even for unit attention sense.

Paolo

Supersedes: <[email protected]>

Hannes Reinecke (5):
scsi: drop 'result' argument from command_complete callback
scsi: Rename linux-specific SG_ERR codes to generic SCSI_HOST error
codes
scsi: Add mapping for generic SCSI_HOST status to sense codes
scsi: inline sg_io_sense_from_errno() into the callers.
scsi: move host_status handling into SCSI drivers

Paolo Bonzini (5):
scsi-disk: move scsi_handle_rw_error earlier
scsi-disk: do not complete requests early for rerror/werror=ignore
scsi: introduce scsi_sense_from_errno()
scsi-disk: pass SCSI status to scsi_handle_rw_error
scsi-disk: pass guest recoverable errors through even for rerror=stop

 hw/scsi/esp-pci.c        |   5 +-
 hw/scsi/esp.c            |   7 +-
 hw/scsi/lsi53c895a.c     |   6 +-
 hw/scsi/megasas.c        |   6 +-
 hw/scsi/mptsas.c         |   5 +-
 hw/scsi/scsi-bus.c       |  23 ++++-
 hw/scsi/scsi-disk.c      | 203 ++++++++++++++++++++++-----------------
 hw/scsi/scsi-generic.c   |  20 ++--
 hw/scsi/spapr_vscsi.c    |  10 +-
 hw/scsi/virtio-scsi.c    |  51 +++++++++-
 hw/scsi/vmw_pvscsi.c     |  43 ++++++++-
 hw/usb/dev-storage.c     |   6 +-
 hw/usb/dev-uas.c         |   7 +-
 include/hw/scsi/esp.h    |   2 +-
 include/hw/scsi/scsi.h   |   6 +-
 include/scsi/constants.h |   3 +
 include/scsi/utils.h     |  29 ++++--
 scsi/qemu-pr-helper.c    |  24 +++--
 scsi/utils.c             | 119 +++++++++++++++++------
 19 files changed, 395 insertions(+), 180 deletions(-)
Signature · 1 line
2.29.2