diff options
author | Lidong Chen <jemmy858585@gmail.com> | 2018-08-06 21:29:35 +0800 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2018-08-22 12:17:43 +0200 |
commit | 923709896b1b01fb982c93492ad01b233e6b6023 (patch) | |
tree | b976bd3e30e3f783e4c935f82ba5d2896075e0af /migration/migration.c | |
parent | c50055ae7c0684edc6f939579f95ea290363b58f (diff) |
migration: poll the cm event for destination qemu
The destination qemu only poll the comp_channel->fd in
qemu_rdma_wait_comp_channel. But when source qemu disconnnect
the rdma connection, the destination qemu should be notified.
Signed-off-by: Lidong Chen <lidongchen@tencent.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'migration/migration.c')
-rw-r--r-- | migration/migration.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/migration/migration.c b/migration/migration.c index 6f2b506335..4d76bee0da 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -390,6 +390,7 @@ static void process_incoming_migration_co(void *opaque) int ret; assert(mis->from_src_file); + mis->migration_incoming_co = qemu_coroutine_self(); mis->largest_page_size = qemu_ram_pagesize_largest(); postcopy_state_set(POSTCOPY_INCOMING_NONE); migrate_set_state(&mis->state, MIGRATION_STATUS_NONE, @@ -419,7 +420,6 @@ static void process_incoming_migration_co(void *opaque) /* we get COLO info, and know if we are in COLO mode */ if (!ret && migration_incoming_enable_colo()) { - mis->migration_incoming_co = qemu_coroutine_self(); qemu_thread_create(&mis->colo_incoming_thread, "COLO incoming", colo_process_incoming_thread, mis, QEMU_THREAD_JOINABLE); mis->have_colo_incoming_thread = true; @@ -443,6 +443,7 @@ static void process_incoming_migration_co(void *opaque) } mis->bh = qemu_bh_new(process_incoming_migration_bh, mis); qemu_bh_schedule(mis->bh); + mis->migration_incoming_co = NULL; } static void migration_incoming_setup(QEMUFile *f) |