summaryrefslogtreecommitdiffstats
path: root/migration
diff options
context:
space:
mode:
authorLaurent Vivier2017-05-24 14:10:48 +0200
committerDavid Gibson2017-06-06 00:53:24 +0200
commit1b6e74824659ef10bd2a2924a98df388b78e175e (patch)
tree586d5444c2e168b2b5dcd54cde22242b8519db0c /migration
parentMerge remote-tracking branch 'remotes/mjt/tags/trivial-patches-fetch' into st... (diff)
downloadqemu-1b6e74824659ef10bd2a2924a98df388b78e175e.tar.gz
qemu-1b6e74824659ef10bd2a2924a98df388b78e175e.tar.xz
qemu-1b6e74824659ef10bd2a2924a98df388b78e175e.zip
migration: remove register_savevm()
We can replace the four remaining calls of register_savevm() by calls to register_savevm_live(). So we can remove the function and as we don't allocate anymore the ops pointer with g_new0() we don't have to free it then. Signed-off-by: Laurent Vivier <lvivier@redhat.com> Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'migration')
-rw-r--r--migration/savevm.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/migration/savevm.c b/migration/savevm.c
index 9c320f59d0..035c127fdd 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -645,21 +645,6 @@ int register_savevm_live(DeviceState *dev,
return 0;
}
-int register_savevm(DeviceState *dev,
- const char *idstr,
- int instance_id,
- int version_id,
- SaveStateHandler *save_state,
- LoadStateHandler *load_state,
- void *opaque)
-{
- SaveVMHandlers *ops = g_new0(SaveVMHandlers, 1);
- ops->save_state = save_state;
- ops->load_state = load_state;
- return register_savevm_live(dev, idstr, instance_id, version_id,
- ops, opaque);
-}
-
void unregister_savevm(DeviceState *dev, const char *idstr, void *opaque)
{
SaveStateEntry *se, *new_se;
@@ -679,7 +664,6 @@ void unregister_savevm(DeviceState *dev, const char *idstr, void *opaque)
if (strcmp(se->idstr, id) == 0 && se->opaque == opaque) {
QTAILQ_REMOVE(&savevm_state.handlers, se, entry);
g_free(se->compat);
- g_free(se->ops);
g_free(se);
}
}