Skip to content

RFC monitor: Pass HMP arguments to QMP HumanReadableText API as JSON

Philippe Mathieu-Daudé qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest3 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3hw/s390x: Declare target specific monitor commands in hmp-target.hhw/s390x/s390-skeys.c hw/s390x/s390-stattrib.c include/hw/s390x/storage-attributes.h +3 more+9 -131 reply
2/3monitor: Allow passing HMP arguments to QMP HumanReadableText APIaccel/tcg/monitor.c docs/devel/writing-monitor-commands.rst hw/core/loader.c +7 more+59 -161 reply
3/3hw/s390x: Introduce x-query-s390x-cmma QMP commandhmp-commands-info.hx hw/s390x/s390-stattrib.c qapi/machine.json+39 -110 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC PATCH 0/3] monitor: Pass HMP arguments to QMP HumanReadableText API as JSON

Current HMPCommand::cmd_info_hrt() handlers don't allow passing arguments from the monitor. This series pass them to the underlying QMP commands as a JSON dictionary, easily deserialized as QDict, similarly to how current HMP commands receive their arguments. Thus very few changes are required to port to the new API. As an example, the @x-query-s390x-cmma command is ported.

Based-on: <[email protected]>

Philippe Mathieu-Daudé (3):
hw/s390x: Declare target specific monitor commands in hmp-target.h
monitor: Allow passing HMP arguments to QMP HumanReadableText API hw/s390x: Introduce x-query-s390x-cmma QMP command

 docs/devel/writing-monitor-commands.rst | 15 ++++++++-
 qapi/machine.json                       | 44 +++++++++++++++++++++++++
 include/hw/s390x/storage-attributes.h   |  4 ---
 include/hw/s390x/storage-keys.h         |  4 ---
 include/monitor/hmp-target.h            |  5 +++
 include/monitor/monitor.h               |  3 +-
 monitor/monitor-internal.h              |  2 +-
 accel/tcg/monitor.c                     |  4 +--
 hw/core/loader.c                        |  2 +-
 hw/core/machine-qmp-cmds.c              |  9 ++---
 hw/s390x/s390-skeys.c                   |  2 ++
 hw/s390x/s390-stattrib.c                | 30 +++++++++++------
 hw/usb/bus.c                            |  2 +-
 monitor/hmp-target.c                    |  8 ++---
 monitor/hmp.c                           | 11 ++++---
 hmp-commands-info.hx                    |  2 +-
 16 files changed, 107 insertions(+), 40 deletions(-)
Signature · 1 line
2.41.0