COLO will stop the VM during each checkpoint on either PVM or SVM.
Accidentally resuming the VM during the window might be fatal because it
may cause the RAM and devices state to misalign, corrupting the checkpoint.
Hence forbid VM resume during the process.
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Peter Xu <peterx@redhat.com>
Tested-by: Lukas Straub <lukasstraub2@web.de>
Link: https://lore.kernel.org/qemu-devel/20260127185254.3954634-8-peterx@redhat.com
Signed-off-by: Fabiano Rosas <farosas@suse.de>
} else if (runstate_check(RUN_STATE_FINISH_MIGRATE)) {
error_setg(errp, "Migration is not finalized yet");
return;
+ } else if (runstate_check(RUN_STATE_COLO)) {
+ error_setg(errp, "COLO checkpoint in progress");
+ return;
}
for (blk = blk_next(NULL); blk; blk = blk_next(blk)) {