HMP pull 2017-10-05

-----BEGIN PGP SIGNATURE-----
 
 iQIcBAABAgAGBQJZ1g5lAAoJEAUWMx68W/3nFY8P/3L3TtGeHkrKPmb6dKrjWuLc
 i4Hmy/T5sJ8S0xzuMbzk3MBjTc6grUxfZ5v2FfOEjuwx23zIRXrobgGnPiMVnFup
 vpJExl/UKl1YN1txKijk46XaY2S24qNr6WwHcvZlVw1tUyrIQYGN4WiLcqZDpIia
 SSHjm3DkMfg0UjVg/3Grf9zhQzXra5tjhofuehATJF1nIeDP1jVWhTXqY5krtkOT
 yMYh2zPCBrEwB7dvJocB9sKEsvf5WhmGGEZWvoqwChbN4pYgzIRdkn9yuKHUThmx
 cLLXSAe8jQYuwL8KRjFMIiaxYITkPn2yvisb45Ii/feMvqtXizkxEFOIUFzjvh6P
 ve9uzIGAezGZ4K5sQzRUcCfUJ2Ax7WXmCFTfs2rGtyk33F01/ng63KSZVW04tk2+
 /13U50eVKcP2pqFF1VN1/ySSsPosnNQe6sUq/moDQ8P0H0Y9cNeQ/b5YigJ5RzsB
 iufp5HzlGdJj/VLykARlRkw4hCxKBGA8kYCOam1cn+zu0iF2d6uNiJNBiuigPDiS
 BlEjNwuDbdFFyaMPino/ajKZ6PSe/iVZmZou4PNFDFaBEoo8rK4ld2TMVlFBedHE
 I0kPs4omz7MFZ8olhDBBD4NGjp1qcEzyzlcuz7pCnioShQ/yX/J28IQTYPSz0GKS
 N8jRs8WyPnpfv0M6UCmF
 =EAfk
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/dgilbert/tags/pull-hmp-20171005' into staging

HMP pull 2017-10-05

# gpg: Signature made Thu 05 Oct 2017 11:50:13 BST
# gpg:                using RSA key 0x0516331EBC5BFDE7
# gpg: Good signature from "Dr. David Alan Gilbert (RH2) <dgilbert@redhat.com>"
# gpg: WARNING: This key is not certified with sufficiently trusted signatures!
# gpg:          It is not certain that the signature belongs to the owner.
# Primary key fingerprint: 45F5 C71B 4A0C B7FB 977A  9FA9 0516 331E BC5B FDE7

* remotes/dgilbert/tags/pull-hmp-20171005:
  hmp-commands-info: Change "@findex FOO" to "@findex info FOO"
  hmp-commands-info: Move Texinfo stanzas to conventional place
  hmp-commands-info: Fix "info rocker-FOO" misspellings
  hmp: Fix unknown command for subtable
  hmp: Missing handle_errors

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
Peter Maydell 2017-10-05 16:13:46 +01:00
commit 67caeeacd3
3 changed files with 75 additions and 72 deletions

View File

@ -23,7 +23,7 @@ ETEXI
STEXI STEXI
@item info version @item info version
@findex version @findex info version
Show the version of QEMU. Show the version of QEMU.
ETEXI ETEXI
@ -37,7 +37,7 @@ ETEXI
STEXI STEXI
@item info network @item info network
@findex network @findex info network
Show the network state. Show the network state.
ETEXI ETEXI
@ -51,7 +51,7 @@ ETEXI
STEXI STEXI
@item info chardev @item info chardev
@findex chardev @findex info chardev
Show the character devices. Show the character devices.
ETEXI ETEXI
@ -66,7 +66,7 @@ ETEXI
STEXI STEXI
@item info block @item info block
@findex block @findex info block
Show info of one block device or all block devices. Show info of one block device or all block devices.
ETEXI ETEXI
@ -80,7 +80,7 @@ ETEXI
STEXI STEXI
@item info blockstats @item info blockstats
@findex blockstats @findex info blockstats
Show block device statistics. Show block device statistics.
ETEXI ETEXI
@ -94,7 +94,7 @@ ETEXI
STEXI STEXI
@item info block-jobs @item info block-jobs
@findex block-jobs @findex info block-jobs
Show progress of ongoing block device operations. Show progress of ongoing block device operations.
ETEXI ETEXI
@ -108,7 +108,7 @@ ETEXI
STEXI STEXI
@item info registers @item info registers
@findex registers @findex info registers
Show the cpu registers. Show the cpu registers.
ETEXI ETEXI
@ -125,7 +125,7 @@ ETEXI
STEXI STEXI
@item info lapic @item info lapic
@findex lapic @findex info lapic
Show local APIC state Show local APIC state
ETEXI ETEXI
@ -141,7 +141,7 @@ ETEXI
STEXI STEXI
@item info ioapic @item info ioapic
@findex ioapic @findex info ioapic
Show io APIC state Show io APIC state
ETEXI ETEXI
@ -155,7 +155,7 @@ ETEXI
STEXI STEXI
@item info cpus @item info cpus
@findex cpus @findex info cpus
Show infos for each CPU. Show infos for each CPU.
ETEXI ETEXI
@ -169,7 +169,7 @@ ETEXI
STEXI STEXI
@item info history @item info history
@findex history @findex info history
Show the command line history. Show the command line history.
ETEXI ETEXI
@ -183,7 +183,7 @@ ETEXI
STEXI STEXI
@item info irq @item info irq
@findex irq @findex info irq
Show the interrupts statistics (if available). Show the interrupts statistics (if available).
ETEXI ETEXI
@ -197,7 +197,7 @@ ETEXI
STEXI STEXI
@item info pic @item info pic
@findex pic @findex info pic
Show i8259 (PIC) state. Show i8259 (PIC) state.
ETEXI ETEXI
@ -211,7 +211,7 @@ ETEXI
STEXI STEXI
@item info pci @item info pci
@findex pci @findex info pci
Show PCI information. Show PCI information.
ETEXI ETEXI
@ -228,7 +228,7 @@ ETEXI
STEXI STEXI
@item info tlb @item info tlb
@findex tlb @findex info tlb
Show virtual to physical memory mappings. Show virtual to physical memory mappings.
ETEXI ETEXI
@ -244,7 +244,7 @@ ETEXI
STEXI STEXI
@item info mem @item info mem
@findex mem @findex info mem
Show the active virtual memory mappings. Show the active virtual memory mappings.
ETEXI ETEXI
@ -259,7 +259,7 @@ ETEXI
STEXI STEXI
@item info mtree @item info mtree
@findex mtree @findex info mtree
Show memory tree. Show memory tree.
ETEXI ETEXI
@ -275,7 +275,7 @@ ETEXI
STEXI STEXI
@item info jit @item info jit
@findex jit @findex info jit
Show dynamic compiler info. Show dynamic compiler info.
ETEXI ETEXI
@ -291,7 +291,7 @@ ETEXI
STEXI STEXI
@item info opcount @item info opcount
@findex opcount @findex info opcount
Show dynamic compiler opcode counters Show dynamic compiler opcode counters
ETEXI ETEXI
@ -305,7 +305,7 @@ ETEXI
STEXI STEXI
@item info kvm @item info kvm
@findex kvm @findex info kvm
Show KVM information. Show KVM information.
ETEXI ETEXI
@ -319,7 +319,7 @@ ETEXI
STEXI STEXI
@item info numa @item info numa
@findex numa @findex info numa
Show NUMA information. Show NUMA information.
ETEXI ETEXI
@ -333,7 +333,7 @@ ETEXI
STEXI STEXI
@item info usb @item info usb
@findex usb @findex info usb
Show guest USB devices. Show guest USB devices.
ETEXI ETEXI
@ -347,7 +347,7 @@ ETEXI
STEXI STEXI
@item info usbhost @item info usbhost
@findex usbhost @findex info usbhost
Show host USB devices. Show host USB devices.
ETEXI ETEXI
@ -361,7 +361,7 @@ ETEXI
STEXI STEXI
@item info profile @item info profile
@findex profile @findex info profile
Show profiling information. Show profiling information.
ETEXI ETEXI
@ -375,7 +375,7 @@ ETEXI
STEXI STEXI
@item info capture @item info capture
@findex capture @findex info capture
Show capture information. Show capture information.
ETEXI ETEXI
@ -389,7 +389,7 @@ ETEXI
STEXI STEXI
@item info snapshots @item info snapshots
@findex snapshots @findex info snapshots
Show the currently saved VM snapshots. Show the currently saved VM snapshots.
ETEXI ETEXI
@ -403,7 +403,7 @@ ETEXI
STEXI STEXI
@item info status @item info status
@findex status @findex info status
Show the current VM status (running|paused). Show the current VM status (running|paused).
ETEXI ETEXI
@ -417,7 +417,7 @@ ETEXI
STEXI STEXI
@item info mice @item info mice
@findex mice @findex info mice
Show which guest mouse is receiving events. Show which guest mouse is receiving events.
ETEXI ETEXI
@ -431,7 +431,7 @@ ETEXI
STEXI STEXI
@item info vnc @item info vnc
@findex vnc @findex info vnc
Show the vnc server status. Show the vnc server status.
ETEXI ETEXI
@ -447,7 +447,7 @@ ETEXI
STEXI STEXI
@item info spice @item info spice
@findex spice @findex info spice
Show the spice server status. Show the spice server status.
ETEXI ETEXI
@ -461,7 +461,7 @@ ETEXI
STEXI STEXI
@item info name @item info name
@findex name @findex info name
Show the current VM name. Show the current VM name.
ETEXI ETEXI
@ -475,7 +475,7 @@ ETEXI
STEXI STEXI
@item info uuid @item info uuid
@findex uuid @findex info uuid
Show the current VM UUID. Show the current VM UUID.
ETEXI ETEXI
@ -489,7 +489,7 @@ ETEXI
STEXI STEXI
@item info cpustats @item info cpustats
@findex cpustats @findex info cpustats
Show CPU statistics. Show CPU statistics.
ETEXI ETEXI
@ -505,7 +505,7 @@ ETEXI
STEXI STEXI
@item info usernet @item info usernet
@findex usernet @findex info usernet
Show user network stack connection states. Show user network stack connection states.
ETEXI ETEXI
@ -519,7 +519,7 @@ ETEXI
STEXI STEXI
@item info migrate @item info migrate
@findex migrate @findex info migrate
Show migration status. Show migration status.
ETEXI ETEXI
@ -533,7 +533,7 @@ ETEXI
STEXI STEXI
@item info migrate_capabilities @item info migrate_capabilities
@findex migrate_capabilities @findex info migrate_capabilities
Show current migration capabilities. Show current migration capabilities.
ETEXI ETEXI
@ -547,7 +547,7 @@ ETEXI
STEXI STEXI
@item info migrate_parameters @item info migrate_parameters
@findex migrate_parameters @findex info migrate_parameters
Show current migration parameters. Show current migration parameters.
ETEXI ETEXI
@ -561,7 +561,7 @@ ETEXI
STEXI STEXI
@item info migrate_cache_size @item info migrate_cache_size
@findex migrate_cache_size @findex info migrate_cache_size
Show current migration xbzrle cache size. Show current migration xbzrle cache size.
ETEXI ETEXI
@ -575,7 +575,7 @@ ETEXI
STEXI STEXI
@item info balloon @item info balloon
@findex balloon @findex info balloon
Show balloon information. Show balloon information.
ETEXI ETEXI
@ -589,7 +589,7 @@ ETEXI
STEXI STEXI
@item info qtree @item info qtree
@findex qtree @findex info qtree
Show device tree. Show device tree.
ETEXI ETEXI
@ -603,7 +603,7 @@ ETEXI
STEXI STEXI
@item info qdm @item info qdm
@findex qdm @findex info qdm
Show qdev device model list. Show qdev device model list.
ETEXI ETEXI
@ -617,7 +617,7 @@ ETEXI
STEXI STEXI
@item info qom-tree @item info qom-tree
@findex qom-tree @findex info qom-tree
Show QOM composition tree. Show QOM composition tree.
ETEXI ETEXI
@ -631,7 +631,7 @@ ETEXI
STEXI STEXI
@item info roms @item info roms
@findex roms @findex info roms
Show roms. Show roms.
ETEXI ETEXI
@ -647,7 +647,7 @@ ETEXI
STEXI STEXI
@item info trace-events @item info trace-events
@findex trace-events @findex info trace-events
Show available trace-events & their state. Show available trace-events & their state.
ETEXI ETEXI
@ -661,7 +661,7 @@ ETEXI
STEXI STEXI
@item info tpm @item info tpm
@findex tpm @findex info tpm
Show the TPM device. Show the TPM device.
ETEXI ETEXI
@ -675,7 +675,7 @@ ETEXI
STEXI STEXI
@item info memdev @item info memdev
@findex memdev @findex info memdev
Show memory backends Show memory backends
ETEXI ETEXI
@ -689,7 +689,7 @@ ETEXI
STEXI STEXI
@item info memory-devices @item info memory-devices
@findex memory-devices @findex info memory-devices
Show memory devices. Show memory devices.
ETEXI ETEXI
@ -703,7 +703,7 @@ ETEXI
STEXI STEXI
@item info iothreads @item info iothreads
@findex iothreads @findex info iothreads
Show iothread's identifiers. Show iothread's identifiers.
ETEXI ETEXI
@ -717,7 +717,7 @@ ETEXI
STEXI STEXI
@item info rocker @var{name} @item info rocker @var{name}
@findex rocker @findex info rocker
Show rocker switch. Show rocker switch.
ETEXI ETEXI
@ -730,8 +730,8 @@ ETEXI
}, },
STEXI STEXI
@item info rocker_ports @var{name}-ports @item info rocker-ports @var{name}-ports
@findex ocker-ports @findex info rocker-ports
Show rocker ports. Show rocker ports.
ETEXI ETEXI
@ -744,8 +744,8 @@ ETEXI
}, },
STEXI STEXI
@item info rocker_of_dpa_flows @var{name} [@var{tbl_id}] @item info rocker-of-dpa-flows @var{name} [@var{tbl_id}]
@findex rocker-of-dpa-flows @findex info rocker-of-dpa-flows
Show rocker OF-DPA flow tables. Show rocker OF-DPA flow tables.
ETEXI ETEXI
@ -759,7 +759,7 @@ ETEXI
STEXI STEXI
@item info rocker-of-dpa-groups @var{name} [@var{type}] @item info rocker-of-dpa-groups @var{name} [@var{type}]
@findex rocker-of-dpa-groups @findex info rocker-of-dpa-groups
Show rocker OF-DPA groups. Show rocker OF-DPA groups.
ETEXI ETEXI
@ -775,7 +775,7 @@ ETEXI
STEXI STEXI
@item info skeys @var{address} @item info skeys @var{address}
@findex skeys @findex info skeys
Display the value of a storage key (s390 only) Display the value of a storage key (s390 only)
ETEXI ETEXI
@ -791,7 +791,7 @@ ETEXI
STEXI STEXI
@item info cmma @var{address} @item info cmma @var{address}
@findex cmma @findex info cmma
Display the values of the CMMA storage attributes for a range of pages (s390 only) Display the values of the CMMA storage attributes for a range of pages (s390 only)
ETEXI ETEXI
@ -805,7 +805,7 @@ ETEXI
STEXI STEXI
@item info dump @item info dump
@findex dump @findex info dump
Display the latest dump status. Display the latest dump status.
ETEXI ETEXI
@ -819,7 +819,7 @@ ETEXI
STEXI STEXI
@item info ramblock @item info ramblock
@findex ramblock @findex info ramblock
Dump all the ramblocks of the system. Dump all the ramblocks of the system.
ETEXI ETEXI
@ -833,14 +833,8 @@ ETEXI
STEXI STEXI
@item info hotpluggable-cpus @item info hotpluggable-cpus
@findex hotpluggable-cpus @findex info hotpluggable-cpus
Show information about hotpluggable CPUs Show information about hotpluggable CPUs
ETEXI
STEXI
@item info vm-generation-id
@findex vm-generation-id
Show Virtual Machine Generation ID
ETEXI ETEXI
{ {
@ -852,10 +846,9 @@ ETEXI
}, },
STEXI STEXI
@item info memory_size_summary @item info vm-generation-id
@findex memory_size_summary @findex info vm-generation-id
Display the amount of initially allocated and present hotpluggable (if Show Virtual Machine Generation ID
enabled) memory in bytes.
ETEXI ETEXI
{ {
@ -867,6 +860,13 @@ ETEXI
.cmd = hmp_info_memory_size_summary, .cmd = hmp_info_memory_size_summary,
}, },
STEXI
@item info memory_size_summary
@findex info memory_size_summary
Display the amount of initially allocated and present hotpluggable (if
enabled) memory in bytes.
ETEXI
STEXI STEXI
@end table @end table
ETEXI ETEXI

2
hmp.c
View File

@ -2394,6 +2394,7 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
monitor_printf(mon, "\n"); monitor_printf(mon, "\n");
qapi_free_MemdevList(memdev_list); qapi_free_MemdevList(memdev_list);
hmp_handle_error(mon, &err);
} }
void hmp_info_memory_devices(Monitor *mon, const QDict *qdict) void hmp_info_memory_devices(Monitor *mon, const QDict *qdict)
@ -2432,6 +2433,7 @@ void hmp_info_memory_devices(Monitor *mon, const QDict *qdict)
} }
qapi_free_MemoryDeviceInfoList(info_list); qapi_free_MemoryDeviceInfoList(info_list);
hmp_handle_error(mon, &err);
} }
void hmp_info_iothreads(Monitor *mon, const QDict *qdict) void hmp_info_iothreads(Monitor *mon, const QDict *qdict)

View File

@ -2697,6 +2697,7 @@ static const mon_cmd_t *search_dispatch_table(const mon_cmd_t *disp_table,
* the command is found in a sub-command table. * the command is found in a sub-command table.
*/ */
static const mon_cmd_t *monitor_parse_command(Monitor *mon, static const mon_cmd_t *monitor_parse_command(Monitor *mon,
const char *cmdp_start,
const char **cmdp, const char **cmdp,
mon_cmd_t *table) mon_cmd_t *table)
{ {
@ -2712,7 +2713,7 @@ static const mon_cmd_t *monitor_parse_command(Monitor *mon,
cmd = search_dispatch_table(table, cmdname); cmd = search_dispatch_table(table, cmdname);
if (!cmd) { if (!cmd) {
monitor_printf(mon, "unknown command: '%.*s'\n", monitor_printf(mon, "unknown command: '%.*s'\n",
(int)(p - *cmdp), *cmdp); (int)(p - cmdp_start), cmdp_start);
return NULL; return NULL;
} }
@ -2724,7 +2725,7 @@ static const mon_cmd_t *monitor_parse_command(Monitor *mon,
*cmdp = p; *cmdp = p;
/* search sub command */ /* search sub command */
if (cmd->sub_table != NULL && *p != '\0') { if (cmd->sub_table != NULL && *p != '\0') {
return monitor_parse_command(mon, cmdp, cmd->sub_table); return monitor_parse_command(mon, cmdp_start, cmdp, cmd->sub_table);
} }
return cmd; return cmd;
@ -3108,7 +3109,7 @@ static void handle_hmp_command(Monitor *mon, const char *cmdline)
trace_handle_hmp_command(mon, cmdline); trace_handle_hmp_command(mon, cmdline);
cmd = monitor_parse_command(mon, &cmdline, mon->cmd_table); cmd = monitor_parse_command(mon, cmdline, &cmdline, mon->cmd_table);
if (!cmd) { if (!cmd) {
return; return;
} }