summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorEric Blake2016-05-16 18:43:03 +0200
committerMax Reitz2016-05-19 16:56:58 +0200
commit37546ff28fb89744ebf2223db22cbc253592abe1 (patch)
treeafeb3f34de755b9d181a20fba7eaf3aec3e5ae4f /tests
parentqemu-iotests: Simplify 109 with unaligned qemu-img compare (diff)
downloadqemu-37546ff28fb89744ebf2223db22cbc253592abe1.tar.gz
qemu-37546ff28fb89744ebf2223db22cbc253592abe1.tar.xz
qemu-37546ff28fb89744ebf2223db22cbc253592abe1.zip
qemu-iotests: Fix regression in 136 on aio_read invalid
Commit 093ea232 removed the ability for aio_read and aio_write to artificially inflate the invalid statistics counters for block devices, since it no longer flags unaligned offset or length. Add 'aio_read -i' and 'aio_write -i' to restore the ability, and update test 136 to use it. Reported-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Eric Blake <eblake@redhat.com> Message-id: 1463416983-28318-4-git-send-email-eblake@redhat.com Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/qemu-iotests/13615
1 files changed, 4 insertions, 11 deletions
diff --git a/tests/qemu-iotests/136 b/tests/qemu-iotests/136
index 996265e626..635b977552 100644
--- a/tests/qemu-iotests/136
+++ b/tests/qemu-iotests/136
@@ -226,18 +226,11 @@ sector = "%d"
highest_offset = wr_ops * wr_size
- # Two types of invalid operations: unaligned length and unaligned offset
- for i in range(invalid_rd_ops / 2):
- ops.append("aio_read 0 511")
+ for i in range(invalid_rd_ops):
+ ops.append("aio_read -i 0 512")
- for i in range(invalid_rd_ops / 2, invalid_rd_ops):
- ops.append("aio_read 13 512")
-
- for i in range(invalid_wr_ops / 2):
- ops.append("aio_write 0 511")
-
- for i in range(invalid_wr_ops / 2, invalid_wr_ops):
- ops.append("aio_write 13 512")
+ for i in range(invalid_wr_ops):
+ ops.append("aio_write -i 0 512")
for i in range(failed_rd_ops):
ops.append("aio_read %d 512" % bad_offset)