Patchwork [10/14] block-migration: actually disable dirty tracking on cleanup

login
register
mail settings
Submitter Kevin Wolf
Date Feb. 7, 2011, 12:40 p.m.
Message ID <1297082430-628-11-git-send-email-kwolf@redhat.com>
Download mbox | patch
Permalink /patch/82168/
State New
Headers show

Comments

Kevin Wolf - Feb. 7, 2011, 12:40 p.m.
From: Marcelo Tosatti <mtosatti@redhat.com>

Call to set_dirty_tracking() is misplaced.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block-migration.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/block-migration.c b/block-migration.c
index c9d3e81..483ca7b 100644
--- a/block-migration.c
+++ b/block-migration.c
@@ -533,6 +533,8 @@  static void blk_mig_cleanup(Monitor *mon)
     BlkMigDevState *bmds;
     BlkMigBlock *blk;
 
+    set_dirty_tracking(0);
+
     while ((bmds = QSIMPLEQ_FIRST(&block_mig_state.bmds_list)) != NULL) {
         QSIMPLEQ_REMOVE_HEAD(&block_mig_state.bmds_list, entry);
         qemu_free(bmds->aio_bitmap);
@@ -545,8 +547,6 @@  static void blk_mig_cleanup(Monitor *mon)
         qemu_free(blk);
     }
 
-    set_dirty_tracking(0);
-
     monitor_printf(mon, "\n");
 }