From: Markus Armbruster <armbru@redhat.com>
To: "Philippe Mathieu-Daudé" <philmd@linaro.org>
Cc: qemu-devel@nongnu.org,
"Dr. David Alan Gilbert" <dave@treblig.org>,
"Mark Cave-Ayland" <mark.cave-ayland@ilande.co.uk>,
"Daniel P . Berrangé" <berrange@redhat.com>,
qemu-ppc@nongnu.org
Subject: Re: [PATCH 1/2] hw/misc/mos6522: Expose x-query-mos6522-devices QMP command
Date: Tue, 11 Jun 2024 07:36:45 +0200 [thread overview]
Message-ID: <87sexkujki.fsf@pond.sub.org> (raw)
In-Reply-To: <20240610150758.2827-2-philmd@linaro.org> ("Philippe Mathieu-Daudé"'s message of "Mon, 10 Jun 2024 17:07:57 +0200")
Philippe Mathieu-Daudé <philmd@linaro.org> writes:
> This is a counterpart to the HMP "info via" command. It is being
> added with an "x-" prefix because this QMP command is intended as an
> adhoc debugging tool and will thus not be modelled in QAPI as fully
> structured data, nor will it have long term guaranteed stability.
>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
> MAINTAINERS | 2 +-
> qapi/machine.json | 17 +++++++++++++++++
> hw/misc/mos6522-stubs.c | 18 ++++++++++++++++++
> hw/misc/mos6522.c | 5 +++--
> hw/misc/meson.build | 3 ++-
> 5 files changed, 41 insertions(+), 4 deletions(-)
> create mode 100644 hw/misc/mos6522-stubs.c
>
> diff --git a/MAINTAINERS b/MAINTAINERS
> index 951556224a..e86638c68c 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -1453,7 +1453,7 @@ F: hw/ppc/mac_newworld.c
> F: hw/pci-host/uninorth.c
> F: hw/pci-bridge/dec.[hc]
> F: hw/misc/macio/
> -F: hw/misc/mos6522.c
> +F: hw/misc/mos6522*.c
> F: hw/nvram/mac_nvram.c
> F: hw/ppc/fw_cfg.c
> F: hw/input/adb*
> diff --git a/qapi/machine.json b/qapi/machine.json
> index 1283d14493..a82b8dd39d 100644
> --- a/qapi/machine.json
> +++ b/qapi/machine.json
I figure you pick machine.json because it already serves as grabbag of
vaguely device-specific queries like x-query-usb. misc-target.json is
another grabbag.
> @@ -1865,6 +1865,23 @@
> 'data': { 'filename': 'str' },
> 'if': 'CONFIG_FDT' }
>
> +##
> +# @x-query-mos6522-devices:
> +#
> +# Query information on MOS6522 VIA devices
> +#
> +# Features:
> +#
> +# @unstable: This command is meant for debugging.
> +#
> +# Returns: MOS6522 VIA devices information
> +#
> +# Since: 9.1
> +##
> +{ 'command': 'x-query-mos6522-devices',
> + 'returns': 'HumanReadableText',
> + 'features': [ 'unstable' ]}
> +
> ##
> # @x-query-interrupt-controllers:
> #
HMP "info via" is compile-time conditional on CONFIG_MOS6522.
Its new QMP counterpart x-query-mos6522-devices is unconditional.
Can you explain why?
Possibly related:
commit 409e9f7131e55e74eb09e65535779e311df5ebf5
Author: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Date: Sat Mar 5 15:09:53 2022 +0000
mos6522: add "info via" HMP command for debugging
This displays detailed information about the device registers and timers to aid
debugging problems with timers and interrupts.
--> Currently the QAPI generators for HumanReadableText don't work correctly if
--> used in qapi/target-misc.json when a non-specified target is built, so for
--> now manually add a hmp_info_via() wrapper until direct support for per-device
--> HMP/QMP commands is implemented.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
Message-Id: <20220305150957.5053-9-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
[...]
next prev parent reply other threads:[~2024-06-11 5:38 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-10 15:07 [PATCH 0/2] hw/misc/mos6522: Do not open-code hmp_info_human_readable_text() Philippe Mathieu-Daudé
2024-06-10 15:07 ` [PATCH 1/2] hw/misc/mos6522: Expose x-query-mos6522-devices QMP command Philippe Mathieu-Daudé
2024-06-10 17:08 ` Daniel P. Berrangé
2024-06-11 5:36 ` Markus Armbruster [this message]
2024-06-10 15:07 ` [PATCH 2/2] hw/misc/mos6522: Do not open-code hmp_info_human_readable_text() Philippe Mathieu-Daudé
2024-06-10 17:09 ` Daniel P. Berrangé
2024-06-11 5:49 ` Examining device state via monitor for debugging (was: [PATCH 0/2] hw/misc/mos6522: Do not open-code hmp_info_human_readable_text()) Markus Armbruster
2024-06-11 6:09 ` Examining device state via monitor for debugging Mark Cave-Ayland
2024-06-11 6:58 ` Manos Pitsidianakis
2024-06-11 8:06 ` Mark Cave-Ayland
2024-06-11 7:57 ` Examining device state via monitor for debugging (was: [PATCH 0/2] hw/misc/mos6522: Do not open-code hmp_info_human_readable_text()) Daniel P. Berrangé
2024-06-11 8:13 ` Examining device state via monitor for debugging Mark Cave-Ayland
2024-06-11 8:46 ` Daniel P. Berrangé
2024-06-11 8:30 ` Examining device state via monitor for debugging (was: [PATCH 0/2] hw/misc/mos6522: Do not open-code hmp_info_human_readable_text()) Peter Maydell
2024-06-11 12:23 ` Dr. David Alan Gilbert
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87sexkujki.fsf@pond.sub.org \
--to=armbru@redhat.com \
--cc=berrange@redhat.com \
--cc=dave@treblig.org \
--cc=mark.cave-ayland@ilande.co.uk \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.