[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 5/5] tests: virtio-scsi: Add test for unaligned
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH 5/5] tests: virtio-scsi: Add test for unaligned WRITE SAME |
Date: |
Fri, 24 Apr 2015 13:07:42 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 |
On 24/04/2015 12:53, Fam Zheng wrote:
> + const uint8_t write_same_cdb[] = { 0x41, 0x00, 0x00, 0x00,
> + 0x00, 0x01, 0x02 };
The array size should be CDB_SIZE and there's 3 missing bytes in the
10-byte WRITE SAME CDB.
byte 0: WRITE SAME opcode
byte 1: all zeros, ok
byte 2...5: LBA = 1, ok
byte 6: GROUP NUMBER = 2?
Did you mean 0x00, 0x00, 0x02, 0x00?
It probably works because scsi-disk ignores bytes 6 and 9, and bytes 7-8
are some nonzero value from the stack, but it would break when changing
the array size to CDB_SIZE.
Otherwise looks good.
Thanks for writing the tests!
Paolo
- [Qemu-devel] [PATCH 0/5] virtio-test: Test case update, Fam Zheng, 2015/04/24
- [Qemu-devel] [PATCH 1/5] tests: Link libqos virtio object to virtio-scsi-test, Fam Zheng, 2015/04/24
- [Qemu-devel] [PATCH 3/5] libqos: Complete virtio device ID definition list, Fam Zheng, 2015/04/24
- [Qemu-devel] [PATCH 4/5] tests: virtio-scsi: Move start/stop to individual test functions, Fam Zheng, 2015/04/24
- [Qemu-devel] [PATCH 5/5] tests: virtio-scsi: Add test for unaligned WRITE SAME, Fam Zheng, 2015/04/24
- Re: [Qemu-devel] [PATCH 5/5] tests: virtio-scsi: Add test for unaligned WRITE SAME,
Paolo Bonzini <=
- [Qemu-devel] [PATCH 2/5] libqos: Allow calling guest_free on NULL pointer, Fam Zheng, 2015/04/24