qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PULL 04/17] blockdev: no need to drain+flush in hmp_drive_


From: Stefan Hajnoczi
Subject: [Qemu-devel] [PULL 04/17] blockdev: no need to drain+flush in hmp_drive_del
Date: Thu, 2 Jul 2015 10:19:36 +0100

From: Paolo Bonzini <address@hidden>

bdrv_close already does that, and in fact hmp_drive_del would need
another drain after the flush (which bdrv_close does).  So remove
the duplication.

Signed-off-by: Paolo Bonzini <address@hidden>
Reviewed-by: Alberto Garcia <address@hidden>
Reviewed-by: Fam Zheng <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Message-id: address@hidden
Signed-off-by: Stefan Hajnoczi <address@hidden>
---
 blockdev.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/blockdev.c b/blockdev.c
index b354676..4d5e016 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2167,9 +2167,6 @@ void hmp_drive_del(Monitor *mon, const QDict *qdict)
         return;
     }
 
-    /* quiesce block driver; prevent further io */
-    bdrv_drain_all();
-    bdrv_flush(bs);
     bdrv_close(bs);
 
     /* if we have a device attached to this BlockDriverState
-- 
2.4.3




reply via email to

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