qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] block: Inactivate all nodes at migration source


From: Fam Zheng
Subject: [Qemu-devel] [PATCH] block: Inactivate all nodes at migration source
Date: Fri, 15 Apr 2016 11:11:06 +0800

qcow2 is not necessarily the top layer node. Since bdrv_inactivate()
doesn't recurse, we should ensure all block nodes are inactivated.

Signed-off-by: Fam Zheng <address@hidden>
---
 block.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/block.c b/block.c
index d4939b4..1c575e4 100644
--- a/block.c
+++ b/block.c
@@ -3270,7 +3270,7 @@ int bdrv_inactivate_all(void)
     BlockDriverState *bs = NULL;
     int ret;
 
-    while ((bs = bdrv_next(bs)) != NULL) {
+    while ((bs = bdrv_next_node(bs)) != NULL) {
         AioContext *aio_context = bdrv_get_aio_context(bs);
 
         aio_context_acquire(aio_context);
-- 
2.8.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]