diff options
author | Peter Xu <peterx@redhat.com> | 2017-06-27 12:10:14 +0800 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2017-06-28 11:18:38 +0200 |
commit | 5272298c48eb3a01c41a7822e6303d0a0a05f004 (patch) | |
tree | 5523c54e95b24105a355a11b9e835fe1e4e4c80c /hw/xen | |
parent | e5cb7e7677010f529d3f0f9dcdb385dea9446f8d (diff) |
migration: move global_state.optional out
Put it into MigrationState then we can use the properties to specify
whether to enable storing global state.
Removing global_state_set_optional() since now we can use HW_COMPAT_2_3
for x86/power, and AccelClass.global_props for Xen.
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
Message-Id: <1498536619-14548-6-git-send-email-peterx@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'hw/xen')
-rw-r--r-- | hw/xen/xen-common.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/hw/xen/xen-common.c b/hw/xen/xen-common.c index d3fa705a82..459e6ab765 100644 --- a/hw/xen/xen-common.c +++ b/hw/xen/xen-common.c @@ -139,19 +139,28 @@ static int xen_init(MachineState *ms) } qemu_add_vm_change_state_handler(xen_change_state_handler, NULL); - global_state_set_optional(); savevm_skip_configuration(); savevm_skip_section_footers(); return 0; } +static GlobalProperty xen_compat_props[] = { + { + .driver = "migration", + .property = "store-global-state", + .value = "off", + }, + { /* end of list */ }, +}; + static void xen_accel_class_init(ObjectClass *oc, void *data) { AccelClass *ac = ACCEL_CLASS(oc); ac->name = "Xen"; ac->init_machine = xen_init; ac->allowed = &xen_allowed; + ac->global_props = xen_compat_props; } #define TYPE_XEN_ACCEL ACCEL_CLASS_NAME("xen") |