diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2014-06-24 15:33:42 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2014-06-24 15:33:42 +0100 |
commit | 513d80edc15d77b6d85df7dfad750ce95d091b78 (patch) | |
tree | c0371bf5c7685bfc7d44b6c9835413f86a26211a /vl.c | |
parent | 089a39486f2c47994c6c0d34ac7abf34baf40d9d (diff) | |
parent | 4ea7df4e5c6b9d8b8a474680d6b1687fc8eacbac (diff) |
Merge remote-tracking branch 'remotes/juanquintela/tags/migration/20140623' into staging
migration/next for 20140623
# gpg: Signature made Mon 23 Jun 2014 18:18:57 BST using RSA key ID 5872D723
# gpg: Can't check signature: public key not found
* remotes/juanquintela/tags/migration/20140623: (22 commits)
vmstate: Refactor & increase tests for primitive types
vmstate: Return error in case of error
migration: Remove unneeded minimum_version_id_old
tests: vmstate static checker: add size mismatch inside substructure
tests: vmstate static checker: add substructure for usb-kbd for hid section
tests: vmstate static checker: remove Subsections
tests: vmstate static checker: remove a subsection
tests: vmstate static checker: remove Description inside Fields
tests: vmstate static checker: remove Description
tests: vmstate static checker: remove Fields
tests: vmstate static checker: change description name
tests: vmstate static checker: remove last field in a struct
tests: vmstate static checker: remove a field
tests: vmstate static checker: remove a section
tests: vmstate static checker: minimum_version_id check
tests: vmstate static checker: version mismatch inside a Description
tests: vmstate static checker: add version error in main section
tests: vmstate static checker: incompat machine types
tests: vmstate static checker: add dump1 and dump2 files
vmstate-static-checker: script to validate vmstate changes
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'vl.c')
-rw-r--r-- | vl.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -2931,6 +2931,7 @@ int main(int argc, char **argv, char **envp) 1024 * 1024; ram_addr_t maxram_size = default_ram_size; uint64_t ram_slots = 0; + FILE *vmstate_dump_file = NULL; atexit(qemu_run_exit_notifiers); error_set_progname(argv[0]); @@ -3937,6 +3938,13 @@ int main(int argc, char **argv, char **envp) } configure_msg(opts); break; + case QEMU_OPTION_dump_vmstate: + vmstate_dump_file = fopen(optarg, "w"); + if (vmstate_dump_file == NULL) { + fprintf(stderr, "open %s: %s\n", optarg, strerror(errno)); + exit(1); + } + break; default: os_parse_cmd_args(popt->index, optarg); } @@ -4488,6 +4496,11 @@ int main(int argc, char **argv, char **envp) } qdev_prop_check_global(); + if (vmstate_dump_file) { + /* dump and exit */ + dump_vmstate_json_to_file(vmstate_dump_file); + return 0; + } if (incoming) { Error *local_err = NULL; |