summaryrefslogtreecommitdiff
path: root/migration/vmstate.c
AgeCommit message (Collapse)AuthorFilesLines
2015-02-05migration: Append JSON description of migration streamAlexander Graf1-6/+180
One of the annoyances of the current migration format is the fact that it's not self-describing. In fact, it's not properly describing at all. Some code randomly scattered throughout QEMU elaborates roughly how to read and write a stream of bytes. We discussed an idea during KVM Forum 2013 to add a JSON description of the migration protocol itself to the migration stream. This patch adds a section after the VM_END migration end marker that contains description data on what the device sections of the stream are composed of. This approach is backwards compatible with any QEMU version reading the stream, because QEMU just stops reading after the VM_END marker and ignores any data following it. With an additional external program this allows us to decipher the contents of any migration stream and hopefully make migration bugs easier to track down. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Amit Shah <amit.shah@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
2015-02-05Migration: Add lots of trace eventsDr. David Alan Gilbert1-4/+20
Mostly on the load side, so that when we get a complaint about a migration failure we can figure out what it didn't like. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Amit Shah <amit.shah@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
2015-02-05savevm: Convert fprintf to error_reportDr. David Alan Gilbert1-3/+4
Convert a bunch of fprintfs to error_reports Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Amit Shah <amit.shah@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
2014-12-16Start migrating migration code into a migration directoryDr. David Alan Gilbert1-0/+687
The migration code now occupies a fair chunk of the top level .c files, it seems time to give it it's own directory. I've not touched: arch_init.c - that's mostly RAM migration but has a few random other bits savevm.c - because it's built target specific This is purely a code move; no code has changed. - it fails checkpatch because of old violations, it feels safer to keep this as purely a move and fix those at some mythical future date. The xbzrle and vmstate tests are now only run for softmmu builds since they require files in the migrate/ directory which is only built for softmmu. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Amit Shah <amit.shah@redhat.com>