From 25d0c16f625feb3b6b9bf8079388cdd314e63916 Mon Sep 17 00:00:00 2001 From: zhanghailiang Date: Thu, 27 Oct 2016 14:42:55 +0800 Subject: migration: Switch to COLO process after finishing loadvm Switch from normal migration loadvm process into COLO checkpoint process if COLO mode is enabled. We add three new members to struct MigrationIncomingState, 'have_colo_incoming_thread' and 'colo_incoming_thread' record the COLO related thread for secondary VM, 'migration_incoming_co' records the original migration incoming coroutine. Signed-off-by: zhanghailiang Signed-off-by: Li Zhijian Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Amit Shah Signed-off-by: Amit Shah --- include/migration/colo.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/migration/colo.h') diff --git a/include/migration/colo.h b/include/migration/colo.h index bf84b99cc5..b40676c748 100644 --- a/include/migration/colo.h +++ b/include/migration/colo.h @@ -15,6 +15,8 @@ #include "qemu-common.h" #include "migration/migration.h" +#include "qemu/coroutine_int.h" +#include "qemu/thread.h" bool colo_supported(void); void colo_info_init(void); @@ -22,4 +24,9 @@ void colo_info_init(void); void migrate_start_colo_process(MigrationState *s); bool migration_in_colo_state(void); +/* loadvm */ +bool migration_incoming_enable_colo(void); +void migration_incoming_exit_colo(void); +void *colo_process_incoming_thread(void *opaque); +bool migration_incoming_in_colo_state(void); #endif -- cgit v1.2.3