|
|
9ae3a8 |
From b592b76b870d07c394156192913924af7d1a8079 Mon Sep 17 00:00:00 2001
|
|
|
9ae3a8 |
From: Jeffrey Cody <jcody@redhat.com>
|
|
|
9ae3a8 |
Date: Wed, 20 Nov 2013 19:43:45 +0100
|
|
|
9ae3a8 |
Subject: [PATCH 02/25] block: qemu-iotests, add quotes to $TEST_IMG usage io pattern tests
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
RH-Author: Jeffrey Cody <jcody@redhat.com>
|
|
|
9ae3a8 |
Message-id: <0ff2c944dec278cb605a62a3ec55fd0a57432ecf.1384975172.git.jcody@redhat.com>
|
|
|
9ae3a8 |
Patchwork-id: 55795
|
|
|
9ae3a8 |
O-Subject: [RHEL7 qemu-kvm PATCH 02/26] block: qemu-iotests, add quotes to $TEST_IMG usage io pattern tests
|
|
|
9ae3a8 |
Bugzilla: 879234
|
|
|
9ae3a8 |
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Fam Zheng <famz@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
The usage of $TEST_IMG was not properly quoted everywhere in
|
|
|
9ae3a8 |
common.pattern.
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Signed-off-by: Jeff Cody <jcody@redhat.com>
|
|
|
9ae3a8 |
Reviewed-by: Eric Blake <eblake@redhat.com>
|
|
|
9ae3a8 |
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
(cherry picked from commit 0084043888f6773d905c1b5d644b89c79d1c7714)
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
tests/qemu-iotests/common.pattern | 12 ++++++------
|
|
|
9ae3a8 |
1 file changed, 6 insertions(+), 6 deletions(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
tests/qemu-iotests/common.pattern | 12 ++++++------
|
|
|
9ae3a8 |
1 files changed, 6 insertions(+), 6 deletions(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/tests/qemu-iotests/common.pattern b/tests/qemu-iotests/common.pattern
|
|
|
9ae3a8 |
index 00e0f60..ddfbca1 100644
|
|
|
9ae3a8 |
--- a/tests/qemu-iotests/common.pattern
|
|
|
9ae3a8 |
+++ b/tests/qemu-iotests/common.pattern
|
|
|
9ae3a8 |
@@ -28,7 +28,7 @@ function do_is_allocated() {
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function is_allocated() {
|
|
|
9ae3a8 |
- do_is_allocated "$@" | $QEMU_IO $TEST_IMG | _filter_qemu_io
|
|
|
9ae3a8 |
+ do_is_allocated "$@" | $QEMU_IO "$TEST_IMG" | _filter_qemu_io
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function do_io() {
|
|
|
9ae3a8 |
@@ -46,18 +46,18 @@ function do_io() {
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function io_pattern() {
|
|
|
9ae3a8 |
- do_io "$@" | $QEMU_IO $TEST_IMG | _filter_qemu_io
|
|
|
9ae3a8 |
+ do_io "$@" | $QEMU_IO "$TEST_IMG" | _filter_qemu_io
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function io() {
|
|
|
9ae3a8 |
local start=$2
|
|
|
9ae3a8 |
local pattern=$(( (start >> 9) % 256 ))
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- do_io "$@" $pattern | $QEMU_IO $TEST_IMG | _filter_qemu_io
|
|
|
9ae3a8 |
+ do_io "$@" $pattern | $QEMU_IO "$TEST_IMG" | _filter_qemu_io
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function io_zero() {
|
|
|
9ae3a8 |
- do_io "$@" 0 | $QEMU_IO $TEST_IMG | _filter_qemu_io
|
|
|
9ae3a8 |
+ do_io "$@" 0 | $QEMU_IO "$TEST_IMG" | _filter_qemu_io
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
function io_test() {
|
|
|
9ae3a8 |
@@ -117,8 +117,8 @@ function io_test2() {
|
|
|
9ae3a8 |
echo === Clusters to be compressed [3]
|
|
|
9ae3a8 |
io_pattern writev $((offset + 8 * $cluster_size)) $cluster_size $((9 * $cluster_size)) $num 165
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- mv $TEST_IMG $TEST_IMG.orig
|
|
|
9ae3a8 |
- $QEMU_IMG convert -f $IMGFMT -O $IMGFMT -c $TEST_IMG.orig $TEST_IMG
|
|
|
9ae3a8 |
+ mv "$TEST_IMG" "$TEST_IMG.orig"
|
|
|
9ae3a8 |
+ $QEMU_IMG convert -f $IMGFMT -O $IMGFMT -c "$TEST_IMG.orig" "$TEST_IMG"
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
# Write the used clusters
|
|
|
9ae3a8 |
echo === Used clusters [1]
|
|
|
9ae3a8 |
--
|
|
|
9ae3a8 |
1.7.1
|
|
|
9ae3a8 |
|