aboutsummaryrefslogtreecommitdiff
path: root/tests/qemu-iotests/093
diff options
context:
space:
mode:
authorAndrey Shinkevich <andrey.shinkevich@virtuozzo.com>2019-07-15 19:07:59 +0300
committerKevin Wolf <kwolf@redhat.com>2019-07-19 13:19:09 +0200
commita6862418fec40727b392c86dc13d9ec980efcb15 (patch)
tree88d7c3a9001e0152525b2bd66e89fc083d5c00ec /tests/qemu-iotests/093
parent0274f45bdef73283f2c213610f11d4e5dcba43b6 (diff)
downloadqemu-a6862418fec40727b392c86dc13d9ec980efcb15.zip
qemu-a6862418fec40727b392c86dc13d9ec980efcb15.tar.gz
qemu-a6862418fec40727b392c86dc13d9ec980efcb15.tar.bz2
iotests: Set read-zeroes on in null block driver for Valgrind
The Valgrind tool reports about the uninitialised buffer 'buf' instantiated on the stack of the function guess_disk_lchs(). Pass 'read-zeroes=on' to the null block driver to make it deterministic. The output of the tests 051, 186 and 227 now includes the parameter 'read-zeroes'. So, the benchmark output files are being changed too. Suggested-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/093')
-rwxr-xr-xtests/qemu-iotests/0939
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/qemu-iotests/093 b/tests/qemu-iotests/093
index d88fbc1..4b2cac1 100755
--- a/tests/qemu-iotests/093
+++ b/tests/qemu-iotests/093
@@ -38,7 +38,7 @@ class ThrottleTestCase(iotests.QMPTestCase):
def setUp(self):
self.vm = iotests.VM()
for i in range(0, self.max_drives):
- self.vm.add_drive(self.test_img)
+ self.vm.add_drive(self.test_img, "file.read-zeroes=on")
self.vm.launch()
def tearDown(self):
@@ -273,7 +273,8 @@ class ThrottleTestGroupNames(iotests.QMPTestCase):
def setUp(self):
self.vm = iotests.VM()
for i in range(0, self.max_drives):
- self.vm.add_drive(self.test_img, "throttling.iops-total=100")
+ self.vm.add_drive(self.test_img,
+ "throttling.iops-total=100,file.read-zeroes=on")
self.vm.launch()
def tearDown(self):
@@ -378,10 +379,10 @@ class ThrottleTestRemovableMedia(iotests.QMPTestCase):
def test_removable_media(self):
# Add a couple of dummy nodes named cd0 and cd1
result = self.vm.qmp("blockdev-add", driver="null-aio",
- node_name="cd0")
+ read_zeroes=True, node_name="cd0")
self.assert_qmp(result, 'return', {})
result = self.vm.qmp("blockdev-add", driver="null-aio",
- node_name="cd1")
+ read_zeroes=True, node_name="cd1")
self.assert_qmp(result, 'return', {})
# Attach a CD drive with cd0 inserted