Fix WRITE SAME data buffer length handling
From the SPC-4 paragraph about WRITE SAME(10): "The WRITE SAME (10) command requests that the device server transfer a single logical block from the Data-Out Buffer [ ... ]". Hence always pass a data buffer when sending a WRITE SAME(10) command. Set the NDOB bit in the WRITE SAME(16) command if no data out buffer is present. Signed-off-by: Bart Van Assche <bvanassche@acm.org>
This commit is contained in:
committed by
Ronnie Sahlberg
parent
e8c4be8f62
commit
ded75ae18a
@@ -54,8 +54,8 @@ test_writesame10_unmap_until_end(void)
|
||||
|
||||
logging(LOG_VERBOSE, "Unmap %d blocks using WRITESAME10", i);
|
||||
ret = writesame10(iscsic, tgt_lun, num_blocks - i,
|
||||
0, i,
|
||||
0, 1, 0, 0, NULL);
|
||||
block_size, i,
|
||||
0, 1, 0, 0, buf);
|
||||
CU_ASSERT_EQUAL(ret, 0);
|
||||
|
||||
if (rc16->lbprz) {
|
||||
|
||||
Reference in New Issue
Block a user