qemu-iotests: add support for qed format
authorStefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Sun, 31 Oct 2010 20:10:20 +0000 (16:10 -0400)
committerKevin Wolf <kwolf@redhat.com>
Thu, 23 Feb 2012 09:29:46 +0000 (10:29 +0100)
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
tests/qemu-iotests/017
tests/qemu-iotests/018
tests/qemu-iotests/019
tests/qemu-iotests/020
tests/qemu-iotests/024
tests/qemu-iotests/027
tests/qemu-iotests/028
tests/qemu-iotests/common
tests/qemu-iotests/common.rc

index d861961db28f516300e1aaa28fa7d7ec182aa954..29dd53fb29b73f04732fa892afbd7b0c4d805d51 100755 (executable)
@@ -40,7 +40,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.pattern
 
 # Any format supporting backing files
-_supported_fmt qcow qcow2 vmdk
+_supported_fmt qcow qcow2 vmdk qed
 _supported_os Linux
 
 TEST_OFFSETS="0 4294967296"
index 0a348feb6127d78cb378918a7fb14a25696aad30..f155b4961e36ec6cf04c56c77397fae537c9abdb 100755 (executable)
@@ -40,7 +40,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.pattern
 
 # Any format supporting backing files
-_supported_fmt qcow qcow2 vmdk
+_supported_fmt qcow qcow2 vmdk qed
 _supported_os Linux
 
 TEST_OFFSETS="0 4294967296"
index e0187b1ffaee78b616585d37150e009420087ac9..4c82be2b525539830213b794aaea4d2a07c60017 100755 (executable)
@@ -44,7 +44,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.pattern
 
 # Any format supporting backing files
-_supported_fmt qcow qcow2 vmdk
+_supported_fmt qcow qcow2 vmdk qed
 _supported_os Linux
 
 TEST_OFFSETS="0 4294967296"
index 546e074498fac5d4e67bd29d0b31e33a0e928108..b065a5364091abac70c5fa155ae5c16eec034da5 100755 (executable)
@@ -42,7 +42,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.pattern
 
 # Any format supporting backing files
-_supported_fmt qcow qcow2 vmdk
+_supported_fmt qcow qcow2 vmdk qed
 _supported_os Linux
 
 TEST_OFFSETS="0 4294967296"
index 48680ca048374022ac6edbc9958ebd7b2c757e09..ff6e9842c93e44cf6224f62f8d1ea3d95aa00cbd 100755 (executable)
@@ -41,8 +41,8 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.filter
 . ./common.pattern
 
-# Currently only qcow2 supports rebasing
-_supported_fmt qcow2
+# Currently only qcow2 and qed support rebasing
+_supported_fmt qcow2 qed
 _supported_os Linux
 
 CLUSTER_SIZE=65536
index 67ecffcfdcf72807531dbc30102950225aa2d445..543c48ffaf72ed39604052f6df851f71dd114328 100755 (executable)
@@ -38,7 +38,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 . ./common.rc
 . ./common.filter
 
-_supported_fmt vmdk qcow qcow2
+_supported_fmt vmdk qcow qcow2 qed
 _supported_os Linux
 
 
index 0ca220e88eb412004f045927c7ba384bf37703eb..cb8b25517a6d76c36bdc1a2bc4c04139c3e1c060 100755 (executable)
@@ -44,7 +44,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
 
 # Any format supporting backing files except vmdk and qcow which do not support
 # smaller backing files.
-_supported_fmt qcow2
+_supported_fmt qcow2 qed
 _supported_os Linux
 
 # Choose a size that is not necessarily a cluster size multiple for image
index 988fd5eb37ab1be96de89f74af1da6113a6bf697..d95ba4cddcf3d07b595d297c5bd6996ba3faed35 100644 (file)
@@ -119,6 +119,7 @@ check options
     -cow                test cow
     -qcow               test qcow
     -qcow2              test qcow2
+    -qed                test qed
     -vdi                test vdi
     -vpc                test vpc
     -vmdk               test vmdk
@@ -158,6 +159,11 @@ testlist options
            xpand=false
            ;;
 
+       -qed)
+           IMGFMT=qed
+           xpand=false
+           ;;
+
        -vdi)
            IMGFMT=vdi
            xpand=false
index da58f9256148e9e91da15f24d47d1858f926e15e..f2db92e985034ce8dc573bb8eeee3931b364444b 100644 (file)
@@ -55,7 +55,7 @@ _make_test_img()
     # at least one argument (the image size) needs to be added
     local extra_img_options=$*
 
-    if [ "$IMGFMT" = "qcow2" -a -n "$CLUSTER_SIZE" ]; then
+    if [ \( "$IMGFMT" = "qcow2" -o "$IMGFMT" = "qed" \) -a -n "$CLUSTER_SIZE" ]; then
         extra_img_options="-o cluster_size=$CLUSTER_SIZE $extra_img_options"
     fi
 
@@ -65,6 +65,7 @@ _make_test_img()
        sed -e "s#$IMGFMT#IMGFMT#g" | \
        sed -e "s# encryption=off##g" | \
        sed -e "s# cluster_size=0##g" | \
+       sed -e "s# table_size=0##g" | \
        sed -e "s# compat6=off##g" | \
        sed -e "s# static=off##g"
 }