qemu-patch-raspberry4/scsi
Paolo Bonzini 86933b4e78 pr-helper: fix assertion failure on failed multipath PERSISTENT RESERVE IN
The response size is expected to be zero if the SCSI status is not
"GOOD", but nothing was resetting it.

This can be reproduced simply by "sg_persist -s /dev/sdb" where /dev/sdb
in the guest is a scsi-block device corresponding to a multipath device
on the host.

Before:

  PR in (Read full status): Aborted command

and on the host:

  prh_write_response: Assertion `resp->sz == 0' failed.

After:

  PR in (Read full status): bad field in cdb or parameter list
  (perhaps unsupported service action)

Reported-by: Jiri Belka <jbelka@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
2018-06-28 19:05:35 +02:00
..
Makefile.objs scsi: add persistent reservation manager using qemu-pr-helper 2017-09-22 21:07:27 +02:00
pr-helper.h Clean up includes 2018-02-09 05:05:11 +01:00
pr-manager-helper.c scsi: add persistent reservation manager using qemu-pr-helper 2017-09-22 21:07:27 +02:00
pr-manager.c scsi, file-posix: add support for persistent reservation management 2017-09-22 01:06:51 +02:00
qemu-pr-helper.c pr-helper: fix assertion failure on failed multipath PERSISTENT RESERVE IN 2018-06-28 19:05:35 +02:00
trace-events scsi, file-posix: add support for persistent reservation management 2017-09-22 01:06:51 +02:00
utils.c scsi: fix scsi_convert_sense crash when in_buf == NULL && in_len == 0 2018-01-12 09:54:13 +01:00