vmstate: Add info vmstate HMP command (WIP)
RFC 1/1 vmstate: Add info vmstate HMP command (WIP)
This adds a command "info vmstate" for dumping a textual representation of the currently registered VMStateDescriptions.
Being purely for debugging, intentionally no QMP schema is set in stone.
Drawback is that conversations from savevm to VMState show up as differences when comparing outputs and require manual code review.
---
Hi Amit,
Here's my previous work, as promised at your KVM Forum talk.
Regards,
Andreas
include/migration/vmstate.h | 2 ++ monitor.c | 12 ++++++++++ savevm.c | 58 +++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 72 insertions(+)
include/migration/vmstate.h +2 -0
@@ -750,4 +750,6 @@ void vmstate_register_ram(struct MemoryRegion *memory, DeviceState *dev);void vmstate_unregister_ram (struct MemoryRegion *memory,DeviceState *dev);void vmstate_register_ram_global (struct MemoryRegion *memory); +void vmstate_info (Monitor *mon); +#endif
monitor.c +12 -0
@@ -2039,6 +2039,11 @@ static void do_info_profile(Monitor *mon, const QDict *qdict) }#endif +static void do_info_vmstate (Monitor *mon,const QDict *qdict) +{ +vmstate_info (mon); +} +/* Capture support */ static QLIST_HEAD (capture_list_head, CaptureState) capture_head;
@@ -2846,6 +2851,13 @@ static mon_cmd_t info_cmds[] = { .help = "show the vnc server status", .mhandler.cmd = hmp_info_vnc, }, + { + .name = "vmstate", + .args_type = "", + .params = "", + .help = "show the VMState structure", + .mhandler.cmd = do_info_vmstate, + }, #if defined(CONFIG_SPICE) { .name = "spice",
savevm.c +58 -0
64 lines not on this page · raw message
Signature · 1 line
1.8.1.4
Quoted 4 lines · On Thu, 24 Oct 2013 16:34:50 +0100 Andreas Färber <[email protected]> wrote:
This adds a command "info vmstate" for dumping a textual representation of the currently registered VMStateDescriptions.
Being purely for debugging, intentionally no QMP schema is set in stone.
We had a discussion in the past about prefixing such QMP commands with x- or adding a special vendor extension for them. I don't remember the conclusion there, although I see that we do have x-rdma-pin-all in the schema.