From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Bin Guo <guobin@linux.alibaba.com>
Cc: qemu-devel@nongnu.org, pbonzini@redhat.com, philmd@linaro.org
Subject: Re: [PATCH] monitor: disable "info kvm" if !KVM
Date: Mon, 5 Jan 2026 10:37:16 +0000 [thread overview]
Message-ID: <aVuUXHT9dt9-ytkG@redhat.com> (raw)
In-Reply-To: <20260105034309.11308-1-guobin@linux.alibaba.com>
On Mon, Jan 05, 2026 at 11:43:09AM +0800, Bin Guo wrote:
Missing commit message explaining why we should do this ?
The 'hmp_info_kvm' implementation is unconditionally built and this patch
isn't changing that, so this result in building unused code.
Conceptually even if KVM is not built, it makes sense to have an
'info kvm' command to tell the user that KVM is not available.
> Signed-off-by: Bin Guo <guobin@linux.alibaba.com>
> ---
> hmp-commands-info.hx | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/hmp-commands-info.hx b/hmp-commands-info.hx
> index 41674dcbe1..1927649493 100644
> --- a/hmp-commands-info.hx
> +++ b/hmp-commands-info.hx
> @@ -294,6 +294,7 @@ SRST
> being coalesced.
> ERST
>
> +#if defined(CONFIG_KVM)
> {
> .name = "kvm",
> .args_type = "",
> @@ -301,6 +302,7 @@ ERST
> .help = "show KVM information",
> .cmd = hmp_info_kvm,
> },
> +#endif
>
> SRST
> ``info kvm``
> --
> 2.50.1 (Apple Git-155)
>
With regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2026-01-05 10:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-05 3:43 [PATCH] monitor: disable "info kvm" if !KVM Bin Guo
2026-01-05 10:37 ` Daniel P. Berrangé [this message]
2026-01-07 9:40 ` Bin Guo
2026-01-08 7:57 ` Markus Armbruster
2026-01-08 9:46 ` Daniel P. Berrangé
2026-01-08 11:35 ` Markus Armbruster
2026-01-08 11:38 ` Daniel P. Berrangé
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=aVuUXHT9dt9-ytkG@redhat.com \
--to=berrange@redhat.com \
--cc=guobin@linux.alibaba.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@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.