summaryrefslogtreecommitdiff
path: root/migration/savevm.c
diff options
context:
space:
mode:
authorJuan Quintela <quintela@redhat.com>2017-03-20 22:25:28 +0100
committerJuan Quintela <quintela@redhat.com>2017-04-21 12:25:39 +0200
commit5727309d254b4942645888574a16d36942ec439c (patch)
tree9a09abab8e668ca62d67ffbf11289b1799a2e958 /migration/savevm.c
parent6d358d94943076846328cc292e4f45c31e1d5d96 (diff)
downloadqemu-5727309d254b4942645888574a16d36942ec439c.zip
migration: Remove MigrationState from migration_in_postcopy
We need to call for the migrate_get_current() in more that half of the uses, so call that inside. Signed-off-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Reviewed-by: Peter Xu <peterx@redhat.com>
Diffstat (limited to 'migration/savevm.c')
-rw-r--r--migration/savevm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/migration/savevm.c b/migration/savevm.c
index 3b19a4a274..853a81a080 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -1062,7 +1062,7 @@ int qemu_savevm_state_iterate(QEMUFile *f, bool postcopy)
static bool should_send_vmdesc(void)
{
MachineState *machine = MACHINE(qdev_get_machine());
- bool in_postcopy = migration_in_postcopy(migrate_get_current());
+ bool in_postcopy = migration_in_postcopy();
return !machine->suppress_vmdesc && !in_postcopy;
}
@@ -1111,7 +1111,7 @@ void qemu_savevm_state_complete_precopy(QEMUFile *f, bool iterable_only)
int vmdesc_len;
SaveStateEntry *se;
int ret;
- bool in_postcopy = migration_in_postcopy(migrate_get_current());
+ bool in_postcopy = migration_in_postcopy();
trace_savevm_state_complete_precopy();