qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 1/1] scsi-disk: passthrough VERIFY command


From: Junlian Bell
Subject: [Qemu-devel] [PATCH 1/1] scsi-disk: passthrough VERIFY command
Date: Fri, 16 Dec 2016 15:55:27 +0800

When a scsi-disk object receives VERIFY command with BYTCHK bit being zero,
scsi_block_is_passthrough returns false and finally makes req being proceeded
by scsi_block_dma_command. Because scsi_block_dma_command has removed process
of VERIFY, QEMU will abort in this function.

This patch makes all VERIFY passthrough to solve this problom.

Signed-off-by: Junlian Bell <address@hidden>
---
 hw/scsi/scsi-disk.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/hw/scsi/scsi-disk.c b/hw/scsi/scsi-disk.c
index a96319138a..f30f97f976 100644
--- a/hw/scsi/scsi-disk.c
+++ b/hw/scsi/scsi-disk.c
@@ -2690,13 +2690,6 @@ static bool scsi_block_is_passthrough(SCSIDiskState *s, 
uint8_t *buf)
     case VERIFY_10:
     case VERIFY_12:
     case VERIFY_16:
-        /* Check if BYTCHK == 0x01 (data-out buffer contains data
-         * for the number of logical blocks specified in the length
-         * field).  For other modes, do not use scatter/gather operation.
-         */
-        if ((buf[1] & 6) != 2) {
-            return false;
-        }
         break;
 
     case READ_6:
-- 
2.11.0.28.gde2efeb




reply via email to

[Prev in Thread] Current Thread [Next in Thread]