aboutsummaryrefslogtreecommitdiff
path: root/hw/scsi/megasas.c
diff options
context:
space:
mode:
authorDmitry Fomichev <dmitry.fomichev@wdc.com>2020-08-12 07:51:22 +0900
committerPaolo Bonzini <pbonzini@redhat.com>2020-09-30 19:09:20 +0200
commitafff2db61f6ace9bb2c4d81c7c57601f5c009acd (patch)
treef5d6a7519c1f578639019cdabdfb36f3f71a45db /hw/scsi/megasas.c
parentb7dd40d40bfa44536bee4aa4d643b26621097d27 (diff)
downloadqemu-afff2db61f6ace9bb2c4d81c7c57601f5c009acd.zip
qemu-afff2db61f6ace9bb2c4d81c7c57601f5c009acd.tar.gz
qemu-afff2db61f6ace9bb2c4d81c7c57601f5c009acd.tar.bz2
scsi-generic: Fix HM-zoned device scan
Several important steps during device scan depend on SCSI type of the device. For example, max_transfer property is only determined and assigned if the device has the type of TYPE_DISK. Host-managed ZBC disks retain most of the properties of regular SCSI drives, but they have their own SCSI device type, 0x14. This prevents the proper assignment of max_transfer property for HM-zoned devices in scsi-generic driver leading to I/O errors if the maximum i/o size calculated at the guest exceeds the host value. To fix this, define TYPE_ZBC to have the standard value from SCSI ZBC standard spec. Several scan steps that were previously done only for TYPE_DISK devices, are now performed for the SCSI devices having TYPE_ZBC too. Reported-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Dmitry Fomichev <dmitry.fomichev@wdc.com> Message-Id: <20200811225122.17342-3-dmitry.fomichev@wdc.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/scsi/megasas.c')
0 files changed, 0 insertions, 0 deletions