[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v8 25/36] iotests: 130: Check image info locklessly
From: |
Fam Zheng |
Subject: |
[Qemu-devel] [PATCH v8 25/36] iotests: 130: Check image info locklessly |
Date: |
Fri, 30 Sep 2016 20:09:55 +0800 |
By the time _img_info is run, QEMU process's resources may still be on
its way being cleaned up, asynchronously, even though the process itself
is already gone after the "kill -KILL" and "wait" commands in
_cleanup_qemu.
Change the last HMP command to 'q' to ensure the locks are released.
Signed-off-by: Fam Zheng <address@hidden>
---
tests/qemu-iotests/130 | 4 ++--
tests/qemu-iotests/130.out | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/130 b/tests/qemu-iotests/130
index ecc8a5b..f14a04f 100755
--- a/tests/qemu-iotests/130
+++ b/tests/qemu-iotests/130
@@ -60,7 +60,7 @@ echo
# Test that a backing file isn't written
_launch_qemu -drive
id=testdisk,file="$TEST_IMG",backing.file.filename="$TEST_IMG.base"
_send_qemu_cmd $QEMU_HANDLE "commit testdisk" "(qemu)"
-_send_qemu_cmd $QEMU_HANDLE '' '(qemu)'
+_send_qemu_cmd $QEMU_HANDLE 'q' '(qemu)'
_cleanup_qemu
_img_info | _filter_img_info
@@ -69,7 +69,7 @@ _img_info | _filter_img_info
_make_test_img -F raw -b "$TEST_IMG.orig" 64M
_launch_qemu -drive
id=testdisk,file="$TEST_IMG",backing.file.filename="$TEST_IMG.base",backing.driver=$IMGFMT
_send_qemu_cmd $QEMU_HANDLE "commit testdisk" "(qemu)"
-_send_qemu_cmd $QEMU_HANDLE '' '(qemu)'
+_send_qemu_cmd $QEMU_HANDLE 'q' '(qemu)'
_cleanup_qemu
_img_info | _filter_img_info
diff --git a/tests/qemu-iotests/130.out b/tests/qemu-iotests/130.out
index ae95b50..2422329 100644
--- a/tests/qemu-iotests/130.out
+++ b/tests/qemu-iotests/130.out
@@ -10,14 +10,14 @@ virtual size: 64M (67108864 bytes)
QEMU X.Y.Z monitor - type 'help' for more information
(qemu)
c[K[Dco[K[D[Dcom[K[D[D[Dcomm[K[D[D[D[Dcommi[K[D[D[D[D[Dcommit[K[D[D[D[D[D[Dcommit
[K[D[D[D[D[D[D[Dcommit t[K[D[D[D[D[D[D[D[Dcommit
te[K[D[D[D[D[D[D[D[D[Dcommit
tes[K[D[D[D[D[D[D[D[D[D[Dcommit
test[K[D[D[D[D[D[D[D[D[D[D[Dcommit
testd[K[D[D[D[D[D[D[D[D[D[D[D[Dcommit
testdi[K[D[D[D[D[D[D[D[D[D[D[D[D[Dcommit
testdis[K[D[D[D[D[D[D[D[D[D[D[D[D[D[Dcommit testdisk[K
-(qemu)
+(qemu) q[K
image: TEST_DIR/t.IMGFMT
file format: IMGFMT
virtual size: 64M (67108864 bytes)
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
backing_file=TEST_DIR/t.IMGFMT.orig backing_fmt=raw
QEMU X.Y.Z monitor - type 'help' for more information
(qemu)
c[K[Dco[K[D[Dcom[K[D[D[Dcomm[K[D[D[D[Dcommi[K[D[D[D[D[Dcommit[K[D[D[D[D[D[Dcommit
[K[D[D[D[D[D[D[Dcommit t[K[D[D[D[D[D[D[D[Dcommit
te[K[D[D[D[D[D[D[D[D[Dcommit
tes[K[D[D[D[D[D[D[D[D[D[Dcommit
test[K[D[D[D[D[D[D[D[D[D[D[Dcommit
testd[K[D[D[D[D[D[D[D[D[D[D[D[Dcommit
testdi[K[D[D[D[D[D[D[D[D[D[D[D[D[Dcommit
testdis[K[D[D[D[D[D[D[D[D[D[D[D[D[D[Dcommit testdisk[K
-(qemu)
+(qemu) q[K
image: TEST_DIR/t.IMGFMT
file format: IMGFMT
virtual size: 64M (67108864 bytes)
--
2.7.4
- [Qemu-devel] [PATCH v8 15/36] qdev: Add "lock-mode" to block device options, (continued)
- [Qemu-devel] [PATCH v8 15/36] qdev: Add "lock-mode" to block device options, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 16/36] ide: Apply lock-mode when initialize, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 17/36] nvme: Apply lock-mode when initialize, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 18/36] usb-storage: Apply lock-mode when realize, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 19/36] pflash: Add "lock-mode" property, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 20/36] qemu-iotests: 046: Move version detection out from verify_io, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 21/36] qemu-iotests: 091: Prepare for image lock, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 22/36] qemu-iotests: 030: Disable image locking when checking test image, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 23/36] iotests: 087: Disable image locking in cases where file is shared, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 24/36] iotests: 087: Disable image locking in cases where file is shared, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 25/36] iotests: 130: Check image info locklessly,
Fam Zheng <=
- [Qemu-devel] [PATCH v8 26/36] iotests: Disable image locking in 085, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 27/36] tests: Use null-co:// instead of /dev/null, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 28/36] qemu-iotests: Add test case 153 for image locking, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 29/36] ahci: Use shared lock for shared storage migration, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 30/36] tests/postcopy: Use shared lock for images, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 31/36] fdc: Add lock-mode qdev properties, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 32/36] m25p80: Add 'lock-mode' property, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 33/36] nand: Add 'lock-mode' property, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 34/36] onenand: Add 'lock-mode' property, Fam Zheng, 2016/09/30
- [Qemu-devel] [PATCH v8 35/36] spapr_nvram: Add 'lock-mode' property, Fam Zheng, 2016/09/30