summaryrefslogtreecommitdiffstats
path: root/migration/trace-events
diff options
context:
space:
mode:
authorJianjun Duan2017-01-19 20:00:51 +0100
committerDr. David Alan Gilbert2017-01-24 18:54:47 +0100
commit94869d5c528bf5df54f37cf5390bc979e6ed46fd (patch)
treedd621b855e00c12d8f1e5aef9e2da8fe7a9fa28a /migration/trace-events
parentmigration: extend VMStateInfo (diff)
downloadqemu-94869d5c528bf5df54f37cf5390bc979e6ed46fd.tar.gz
qemu-94869d5c528bf5df54f37cf5390bc979e6ed46fd.tar.xz
qemu-94869d5c528bf5df54f37cf5390bc979e6ed46fd.zip
migration: migrate QTAILQ
Currently we cannot directly transfer a QTAILQ instance because of the limitation in the migration code. Here we introduce an approach to transfer such structures. We created VMStateInfo vmstate_info_qtailq for QTAILQ. Similar VMStateInfo can be created for other data structures such as list. When a QTAILQ is migrated from source to target, it is appended to the corresponding QTAILQ structure, which is assumed to have been properly initialized. This approach will be used to transfer pending_events and ccs_list in spapr state. We also create some macros in qemu/queue.h to access a QTAILQ using pointer arithmetic. This ensures that we do not depend on the implementation details about QTAILQ in the migration code. Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Jianjun Duan <duanj@linux.vnet.ibm.com> Message-Id: <1484852453-12728-3-git-send-email-duanj@linux.vnet.ibm.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'migration/trace-events')
-rw-r--r--migration/trace-events4
1 files changed, 4 insertions, 0 deletions
diff --git a/migration/trace-events b/migration/trace-events
index 94134f700b..c46f9e98df 100644
--- a/migration/trace-events
+++ b/migration/trace-events
@@ -52,6 +52,10 @@ vmstate_n_elems(const char *name, int n_elems) "%s: %d"
vmstate_subsection_load(const char *parent) "%s"
vmstate_subsection_load_bad(const char *parent, const char *sub, const char *sub2) "%s: %s/%s"
vmstate_subsection_load_good(const char *parent) "%s"
+get_qtailq(const char *name, int version_id) "%s v%d"
+get_qtailq_end(const char *name, const char *reason, int val) "%s %s/%d"
+put_qtailq(const char *name, int version_id) "%s v%d"
+put_qtailq_end(const char *name, const char *reason) "%s %s"
# migration/qemu-file.c
qemu_file_fclose(void) ""