From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
To: Roman Bolshakov <r.bolshakov@yadro.com>
Cc: qemu-devel@nongnu.org, Eduardo Habkost <ehabkost@redhat.com>,
Markus Armbruster <armbru@redhat.com>
Subject: Re: [PATCH for-6.0 2/6] qapi: Rename KvmInfo to AccelInfo
Date: Fri, 27 Nov 2020 10:40:12 +0000 [thread overview]
Message-ID: <20201127104012.GD2969@work-vm> (raw)
In-Reply-To: <20201116131011.26607-3-r.bolshakov@yadro.com>
* Roman Bolshakov (r.bolshakov@yadro.com) wrote:
> There's nothing specific to KVM in the structure. A more generic name
> would be more appropriate.
>
> Signed-off-by: Roman Bolshakov <r.bolshakov@yadro.com>
For HMP:
Acked-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Markus/Eric: Is it OK from QMP to change the type like that?
Dave
> ---
> monitor/hmp-cmds.c | 4 ++--
> monitor/qmp-cmds.c | 8 ++++----
> qapi/machine.json | 18 +++++++++---------
> 3 files changed, 15 insertions(+), 15 deletions(-)
>
> diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
> index a6a6684df1..ea86289fe8 100644
> --- a/monitor/hmp-cmds.c
> +++ b/monitor/hmp-cmds.c
> @@ -120,7 +120,7 @@ void hmp_info_version(Monitor *mon, const QDict *qdict)
>
> void hmp_info_kvm(Monitor *mon, const QDict *qdict)
> {
> - KvmInfo *info;
> + AccelInfo *info;
>
> info = qmp_query_kvm(NULL);
> monitor_printf(mon, "kvm support: ");
> @@ -130,7 +130,7 @@ void hmp_info_kvm(Monitor *mon, const QDict *qdict)
> monitor_printf(mon, "not compiled\n");
> }
>
> - qapi_free_KvmInfo(info);
> + qapi_free_AccelInfo(info);
> }
>
> void hmp_info_status(Monitor *mon, const QDict *qdict)
> diff --git a/monitor/qmp-cmds.c b/monitor/qmp-cmds.c
> index 0454394e76..f5d50afa9c 100644
> --- a/monitor/qmp-cmds.c
> +++ b/monitor/qmp-cmds.c
> @@ -52,9 +52,9 @@ NameInfo *qmp_query_name(Error **errp)
> return info;
> }
>
> -KvmInfo *qmp_query_kvm(Error **errp)
> +AccelInfo *qmp_query_kvm(Error **errp)
> {
> - KvmInfo *info = g_malloc0(sizeof(*info));
> + AccelInfo *info = g_malloc0(sizeof(*info));
>
> info->enabled = kvm_enabled();
> info->present = kvm_available();
> @@ -62,9 +62,9 @@ KvmInfo *qmp_query_kvm(Error **errp)
> return info;
> }
>
> -KvmInfo *qmp_query_accel(const char *name, Error **errp)
> +AccelInfo *qmp_query_accel(const char *name, Error **errp)
> {
> - KvmInfo *info = g_malloc0(sizeof(*info));
> + AccelInfo *info = g_malloc0(sizeof(*info));
>
> AccelClass *ac = accel_find(name);
>
> diff --git a/qapi/machine.json b/qapi/machine.json
> index 11f364fab4..5648d8d24d 100644
> --- a/qapi/machine.json
> +++ b/qapi/machine.json
> @@ -562,24 +562,24 @@
> { 'command': 'inject-nmi' }
>
> ##
> -# @KvmInfo:
> +# @AccelInfo:
> #
> -# Information about support for KVM acceleration
> +# Information about support for an acceleration
> #
> -# @enabled: true if KVM acceleration is active
> +# @enabled: true if an acceleration is active
> #
> -# @present: true if KVM acceleration is built into this executable
> +# @present: true if an acceleration is built into this executable
> #
> # Since: 0.14.0
> ##
> -{ 'struct': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} }
> +{ 'struct': 'AccelInfo', 'data': {'enabled': 'bool', 'present': 'bool'} }
>
> ##
> # @query-kvm:
> #
> # Returns information about KVM acceleration
> #
> -# Returns: @KvmInfo
> +# Returns: @AccelInfo
> #
> # Since: 0.14.0
> #
> @@ -589,14 +589,14 @@
> # <- { "return": { "enabled": true, "present": true } }
> #
> ##
> -{ 'command': 'query-kvm', 'returns': 'KvmInfo' }
> +{ 'command': 'query-kvm', 'returns': 'AccelInfo' }
>
> ##
> # @query-accel:
> #
> # Returns information about an accelerator
> #
> -# Returns: @KvmInfo
> +# Returns: @AccelInfo
> #
> # Since: 6.0.0
> #
> @@ -608,7 +608,7 @@
> ##
> { 'command': 'query-accel',
> 'data': { 'name': 'str' },
> - 'returns': 'KvmInfo' }
> + 'returns': 'AccelInfo' }
>
> ##
> # @NumaOptionsType:
> --
> 2.29.2
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
next prev parent reply other threads:[~2020-11-27 10:45 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-16 13:10 [PATCH for-6.0 0/6] Add HMP/QMP commands to query accelerator Roman Bolshakov
2020-11-16 13:10 ` [PATCH for-6.0 1/6] qapi: Add query-accel command Roman Bolshakov
2020-11-16 16:20 ` Eric Blake
2020-11-16 18:56 ` Roman Bolshakov
2020-11-16 21:13 ` Eduardo Habkost
2020-11-17 8:51 ` Markus Armbruster
2020-11-18 1:19 ` Roman Bolshakov
2020-11-18 8:36 ` Markus Armbruster
2020-11-18 9:21 ` Paolo Bonzini
2020-11-18 13:08 ` Markus Armbruster
2020-11-18 13:46 ` Paolo Bonzini
2020-11-18 14:45 ` Markus Armbruster
2020-11-18 14:54 ` Paolo Bonzini
2020-11-18 14:00 ` Roman Bolshakov
2020-11-18 11:28 ` Kevin Wolf
2020-11-18 11:56 ` Daniel P. Berrangé
2020-11-18 13:53 ` Markus Armbruster
2020-11-18 15:45 ` Eduardo Habkost
2020-11-18 15:56 ` Eric Blake
2020-11-18 16:23 ` Eduardo Habkost
2020-11-19 13:17 ` Markus Armbruster
2020-11-30 17:05 ` Philippe Mathieu-Daudé
2020-11-16 13:10 ` [PATCH for-6.0 2/6] qapi: Rename KvmInfo to AccelInfo Roman Bolshakov
2020-11-27 10:40 ` Dr. David Alan Gilbert [this message]
2020-11-27 12:08 ` Markus Armbruster
2020-11-16 13:10 ` [PATCH for-6.0 3/6] qapi: Use qmp_query_accel() in qmp_query_kvm() Roman Bolshakov
2020-11-16 13:10 ` [PATCH for-6.0 4/6] softmmu: Remove kvm_available() Roman Bolshakov
2020-11-16 13:10 ` [PATCH for-6.0 5/6] hmp: Add 'info accel' command Roman Bolshakov
2020-11-27 10:39 ` Dr. David Alan Gilbert
2020-11-16 13:10 ` [PATCH for-6.0 6/6] qapi: Deprecate 'query-kvm' Roman Bolshakov
2020-11-27 10:50 ` Daniel P. Berrangé
2020-11-27 11:21 ` Peter Krempa
2020-11-27 11:45 ` Roman Bolshakov
2020-11-27 12:18 ` Peter Krempa
2020-11-27 15:44 ` Markus Armbruster
2020-11-27 16:30 ` Peter Krempa
2020-11-30 9:21 ` Markus Armbruster
2020-11-30 10:09 ` Peter Krempa
2020-11-30 16:03 ` Markus Armbruster
2020-11-30 15:30 ` Eric Blake
2020-11-27 15:53 ` Daniel P. Berrangé
2020-11-27 16:35 ` Peter Krempa
2020-11-19 14:41 ` [PATCH for-6.0 0/6] Add HMP/QMP commands to query accelerator Claudio Fontana
2020-11-19 15:46 ` Roman Bolshakov
2020-11-19 15:54 ` Claudio Fontana
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=20201127104012.GD2969@work-vm \
--to=dgilbert@redhat.com \
--cc=armbru@redhat.com \
--cc=ehabkost@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=r.bolshakov@yadro.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).