[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v3 13/35] arch_init/ram_save: introduce constant for
From: |
Isaku Yamahata |
Subject: |
[Qemu-devel] [PATCH v3 13/35] arch_init/ram_save: introduce constant for ram save version = 4 |
Date: |
Tue, 30 Oct 2012 17:32:49 +0900 |
Introduce RAM_SAVE_VERSION_ID to represent version_id for ram save format.
Signed-off-by: Isaku Yamahata <address@hidden>
---
arch_init.c | 2 +-
arch_init.h | 2 ++
vl.c | 3 ++-
3 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/arch_init.c b/arch_init.c
index 4b65221..23717d3 100644
--- a/arch_init.c
+++ b/arch_init.c
@@ -784,7 +784,7 @@ static int ram_load(QEMUFile *f, void *opaque, int
version_id)
seq_iter++;
- if (version_id < 4 || version_id > 4) {
+ if (version_id < 4 || version_id > RAM_SAVE_VERSION_ID) {
return -EINVAL;
}
diff --git a/arch_init.h b/arch_init.h
index e4c131e..780eedf 100644
--- a/arch_init.h
+++ b/arch_init.h
@@ -44,4 +44,6 @@ CpuDefinitionInfoList GCC_WEAK_DECL
*arch_query_cpu_definitions(Error **errp);
#define RAM_SAVE_FLAG_CONTINUE 0x20
#define RAM_SAVE_FLAG_XBZRLE 0x40
+#define RAM_SAVE_VERSION_ID 4 /* currently version 4 */
+
#endif
diff --git a/vl.c b/vl.c
index ee3c43a..723fc59 100644
--- a/vl.c
+++ b/vl.c
@@ -3557,7 +3557,8 @@ int main(int argc, char **argv, char **envp)
default_drive(default_sdcard, snapshot, machine->use_scsi,
IF_SD, 0, SD_OPTS);
- register_savevm_live(NULL, "ram", 0, 4, &savevm_ram_handlers, NULL);
+ register_savevm_live(NULL, "ram", 0, RAM_SAVE_VERSION_ID,
+ &savevm_ram_handlers, NULL);
if (nb_numa_nodes > 0) {
int i;
--
1.7.10.4
- [Qemu-devel] [PATCH v3 24/35] postcopy outgoing: add -p option to migrate command, (continued)
- [Qemu-devel] [PATCH v3 24/35] postcopy outgoing: add -p option to migrate command, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 07/35] savevm: export qemu_peek_buffer, qemu_peek_byte, qemu_file_skip, qemu_fflush, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 15/35] arch_init/ram_save_setup: factor out bitmap alloc/free, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 19/35] uvmem.h: import Linux uvmem.h and teach update-linux-headers.sh, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 31/35] arch_init: export ram_save_iterate(), Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 28/35] arch_init: factor out setting last_block, last_offset, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 17/35] arch_init: factor out logic to find ram block with id string, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 18/35] migration: export migrate_fd_completed() and migrate_fd_cleanup(), Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 34/35] postcopy/outgoing: introduce precopy_count parameter, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 16/35] arch_init/ram_load: refactor ram_load, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 13/35] arch_init/ram_save: introduce constant for ram save version = 4,
Isaku Yamahata <=
- [Qemu-devel] [PATCH v3 30/35] arch_init: factor out ram_load, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 22/35] savevm: add new section that is used by postcopy, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 32/35] postcopy: pre+post optimization incoming side, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 21/35] postcopy: introduce helper functions for postcopy, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 35/35] postcopy: pre+post optimization outgoing side, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 27/35] postcopy/outgoing: implement forward/backword prefault, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 23/35] postcopy: implement incoming part of postcopy live migration, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 25/35] postcopy: implement outgoing part of postcopy live migration, Isaku Yamahata, 2012/10/30
- [Qemu-devel] [PATCH v3 26/35] postcopy/outgoing: add -n options to disable background transfer, Isaku Yamahata, 2012/10/30
- Re: [Qemu-devel] [PATCH v3 00/35] postcopy live migration, Benoit Hudzia, 2012/10/30