[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 02/19] migration: They are called vmstate_foo, move
From: |
Juan Quintela |
Subject: |
[Qemu-devel] [PATCH 02/19] migration: They are called vmstate_foo, move them to vmstate.c |
Date: |
Mon, 17 Apr 2017 22:00:24 +0200 |
Signed-off-by: Juan Quintela <address@hidden>
---
migration/savevm.c | 17 -----------------
migration/vmstate.c | 16 ++++++++++++++++
2 files changed, 16 insertions(+), 17 deletions(-)
diff --git a/migration/savevm.c b/migration/savevm.c
index cc9c086..c47b209 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -45,7 +45,6 @@
#include "qemu/sockets.h"
#include "qemu/queue.h"
#include "sysemu/cpus.h"
-#include "exec/memory.h"
#include "qmp-commands.h"
#include "trace.h"
#include "qemu/bitops.h"
@@ -2465,19 +2464,3 @@ void hmp_info_snapshots(Monitor *mon, const QDict *qdict)
g_free(global_snapshots);
}
-
-void vmstate_register_ram(MemoryRegion *mr, DeviceState *dev)
-{
- qemu_ram_set_idstr(mr->ram_block,
- memory_region_name(mr), dev);
-}
-
-void vmstate_unregister_ram(MemoryRegion *mr, DeviceState *dev)
-{
- qemu_ram_unset_idstr(mr->ram_block);
-}
-
-void vmstate_register_ram_global(MemoryRegion *mr)
-{
- vmstate_register_ram(mr, NULL);
-}
diff --git a/migration/vmstate.c b/migration/vmstate.c
index 8a71349..174c490 100644
--- a/migration/vmstate.c
+++ b/migration/vmstate.c
@@ -1,5 +1,6 @@
#include "qemu/osdep.h"
#include "qemu-common.h"
+#include "exec/memory.h"
#include "migration/migration.h"
#include "migration/qemu-file.h"
#include "migration/vmstate.h"
@@ -1127,3 +1128,18 @@ bool vmstate_device_is_migratable(const
VMStateDescription *vmsd)
return true;
}
+void vmstate_register_ram(MemoryRegion *mr, DeviceState *dev)
+{
+ qemu_ram_set_idstr(mr->ram_block,
+ memory_region_name(mr), dev);
+}
+
+void vmstate_unregister_ram(MemoryRegion *mr, DeviceState *dev)
+{
+ qemu_ram_unset_idstr(mr->ram_block);
+}
+
+void vmstate_register_ram_global(MemoryRegion *mr)
+{
+ vmstate_register_ram(mr, NULL);
+}
--
2.9.3
- [Qemu-devel] [PATCH 00/19] Migration cleanup, Juan Quintela, 2017/04/17
- [Qemu-devel] [PATCH 02/19] migration: They are called vmstate_foo, move them to vmstate.c,
Juan Quintela <=
- [Qemu-devel] [PATCH 01/19] migration: to_dst_file at that point is NULL, Juan Quintela, 2017/04/17
- [Qemu-devel] [PATCH 03/19] migration: Split migration/channel.c for channel operations, Juan Quintela, 2017/04/17
- [Qemu-devel] [PATCH 04/19] migration: Remove MigrationState from migration_channel_incomming(), Juan Quintela, 2017/04/17
- [Qemu-devel] [PATCH 05/19] migration: Export exec.c functions in its own file, Juan Quintela, 2017/04/17
- [Qemu-devel] [PATCH 06/19] migration: Export fd.c functions in its own file, Juan Quintela, 2017/04/17