The snapshot RAM-saving path does not support Xen's memory mappings. Refuse 'savevm' and 'loadvm' when running as a Xen device model, the same way they are refused for CPR migration modes.
Suggested-by: Akihiko Odaki <[email protected]> Signed-off-by: Andrey Drobyshev <[email protected]> --- migration/options.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/migration/options.c b/migration/options.c index 92eda90114e..0b7f393492d 100644 --- a/migration/options.c +++ b/migration/options.c @@ -37,6 +37,7 @@ #include "ram.h" #include "options.h" #include "system/kvm.h" +#include "system/xen.h" /* Maximum migrate downtime set to 2000 seconds */ #define MAX_MIGRATE_DOWNTIME_SECONDS 2000 @@ -563,6 +564,11 @@ bool migrate_can_snapshot(Error **errp) MigMode mode = migrate_mode(); int i; + if (xen_enabled()) { + error_setg(errp, "Snapshots are not compatible with Xen"); + return false; + } + if (mode != MIG_MODE_NORMAL) { error_setg(errp, "Snapshots are not compatible with migration mode %s", MigMode_str(mode)); -- 2.47.1
