summaryrefslogtreecommitdiff
path: root/migration/migration.c
diff options
context:
space:
mode:
authorVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>2018-03-13 15:34:01 -0400
committerJohn Snow <jsnow@redhat.com>2018-03-13 17:06:09 -0400
commitb35ebdf076d697bca9ad8715ac76d7b7f3ac1be3 (patch)
tree7aa0608119de0b525ec65e8827d311b72636f154 /migration/migration.c
parent16b0fd3252511af284ceaeedb4d09ce2d5142da0 (diff)
downloadqemu-b35ebdf076d697bca9ad8715ac76d7b7f3ac1be3.tar.gz
migration: add postcopy migration of dirty bitmaps
Postcopy migration of dirty bitmaps. Only named dirty bitmaps are migrated. If destination qemu is already containing a dirty bitmap with the same name as a migrated bitmap (for the same node), then, if their granularities are the same the migration will be done, otherwise the error will be generated. If destination qemu doesn't contain such bitmap it will be created. Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Message-id: 20180313180320.339796-12-vsementsov@virtuozzo.com [Changed '+' to '*' as per list discussion. --js] Signed-off-by: John Snow <jsnow@redhat.com>
Diffstat (limited to 'migration/migration.c')
-rw-r--r--migration/migration.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/migration/migration.c b/migration/migration.c
index 59b4fe6090..623f373326 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -157,6 +157,9 @@ MigrationIncomingState *migration_incoming_get_current(void)
memset(&mis_current, 0, sizeof(MigrationIncomingState));
qemu_mutex_init(&mis_current.rp_mutex);
qemu_event_init(&mis_current.main_thread_load_event, false);
+
+ init_dirty_bitmap_incoming_migration();
+
once = true;
}
return &mis_current;
@@ -320,6 +323,8 @@ static void process_incoming_migration_bh(void *opaque)
state, we need to obey autostart. Any other state is set with
runstate_set. */
+ dirty_bitmap_mig_before_vm_start();
+
if (!global_state_received() ||
global_state_get_runstate() == RUN_STATE_RUNNING) {
if (autostart) {