]> git.ipfire.org Git - thirdparty/qemu.git/commit
scsi-disk: fix VERIFY emulation
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 28 Nov 2013 10:18:56 +0000 (11:18 +0100)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Fri, 21 Feb 2014 03:59:17 +0000 (21:59 -0600)
commit30a08ab4e15a5fc810c9b4541456d2ebac68c646
tree38832bb7c99f42694b9a5da0bcb7162b08764cc3
parentdf3e347891e4aaf84af983f9e3229079f1b9d2c4
scsi-disk: fix VERIFY emulation

VERIFY emulation was completely botched (and remained botched through
all the refactorings).  The command must be emulated both in check-medium
mode (BYTCHK=00, which we implement by doing nothing) and in check-bytes
mode (which we do not implement yet).  Unlike WRITE AND VERIFY (which we
treat simply as WRITE with FUA bit set), VERIFY cannot be handled like
READ.  In fact the device is _receiving_ data for VERIFY, not _sending_
it like READ.

Cc: qemu-stable@nongnu.org
Tested-by: Hervé Poussineau <hpoussin@reactos.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit d97e7730816094a71cd1f19a56d7a73f77cdbf96)

Conflicts:

hw/scsi/scsi-disk.c

*fixed up WRITE_SAME_* conflicts due to 84f94a9a not being in 1.7.0

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
hw/scsi/scsi-disk.c