summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorPeter Maydell2019-05-16 11:24:08 +0200
committerPeter Maydell2019-05-16 11:24:08 +0200
commitc1497fba36465d0259d4d04f2bf09ea59ed42680 (patch)
tree80b616d06242e232762600f80b2d7745ea5015e2 /include
parentMerge remote-tracking branch 'remotes/rth/tags/pull-tcg-20190513' into staging (diff)
parentmonitor: Call mon_get_cpu() only once at hmp_gva2gpa() (diff)
downloadqemu-c1497fba36465d0259d4d04f2bf09ea59ed42680.tar.gz
qemu-c1497fba36465d0259d4d04f2bf09ea59ed42680.tar.xz
qemu-c1497fba36465d0259d4d04f2bf09ea59ed42680.zip
Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20190514b' into staging
Migration pull 2019-05-14 Small fixes/cleanups One HMP/monitor fix # gpg: Signature made Tue 14 May 2019 19:03:53 BST # gpg: using RSA key 45F5C71B4A0CB7FB977A9FA90516331EBC5BFDE7 # gpg: Good signature from "Dr. David Alan Gilbert (RH2) <dgilbert@redhat.com>" [full] # Primary key fingerprint: 45F5 C71B 4A0C B7FB 977A 9FA9 0516 331E BC5B FDE7 * remotes/dgilbert/tags/pull-migration-20190514b: monitor: Call mon_get_cpu() only once at hmp_gva2gpa() migration/ram.c: fix typos in comments migration: Fix use-after-free during process exit migration/savevm: wrap into qemu_loadvm_state_header() migration/savevm: load_header before load_setup migration/savevm: remove duplicate check of migration_is_blocked migration: update comments of migration bitmap migration/ram.c: start of migration_bitmap_sync_range is always 0 qemu-option.hx: Update missed parameter for colo-compare migration/colo.h: Remove obsolete codes migration/colo.c: Remove redundant input parameter migration: savevm: fix error code with migration blockers vmstate: check subsection_found is enough migration: remove not used field xfer_limit migration: not necessary to check ops again migration: comment VMSTATE_UNUSED*() properly Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/migration/colo.h4
-rw-r--r--include/migration/vmstate.h14
2 files changed, 15 insertions, 3 deletions
diff --git a/include/migration/colo.h b/include/migration/colo.h
index 99ce17aca7..f6fbe23ec9 100644
--- a/include/migration/colo.h
+++ b/include/migration/colo.h
@@ -22,8 +22,6 @@ enum colo_event {
COLO_EVENT_FAILOVER,
};
-void colo_info_init(void);
-
void migrate_start_colo_process(MigrationState *s);
bool migration_in_colo_state(void);
@@ -37,7 +35,7 @@ bool migration_incoming_in_colo_state(void);
COLOMode get_colo_mode(void);
/* failover */
-void colo_do_failover(MigrationState *s);
+void colo_do_failover(void);
void colo_checkpoint_notify(void *opaque);
#endif
diff --git a/include/migration/vmstate.h b/include/migration/vmstate.h
index a668ec75b8..9224370ed5 100644
--- a/include/migration/vmstate.h
+++ b/include/migration/vmstate.h
@@ -1035,6 +1035,20 @@ extern const VMStateInfo vmstate_info_qtailq;
#define VMSTATE_BUFFER_UNSAFE(_field, _state, _version, _size) \
VMSTATE_BUFFER_UNSAFE_INFO(_field, _state, _version, vmstate_info_buffer, _size)
+/*
+ * These VMSTATE_UNUSED*() macros can be used to fill in the holes
+ * when some of the vmstate fields are obsolete to be compatible with
+ * migrations between new/old binaries.
+ *
+ * CAUTION: when using any of the VMSTATE_UNUSED*() macros please be
+ * sure that the size passed in is the size that was actually *sent*
+ * rather than the size of the *structure*. One example is the
+ * boolean type - the size of the structure can vary depending on the
+ * definition of boolean, however the size we actually sent is always
+ * 1 byte (please refer to implementation of VMSTATE_BOOL_V and
+ * vmstate_info_bool). So here we should always pass in size==1
+ * rather than size==sizeof(bool).
+ */
#define VMSTATE_UNUSED_V(_v, _size) \
VMSTATE_UNUSED_BUFFER(NULL, _v, _size)