All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Khushit Shah <khushit.shah@nutanix.com>
Cc: qemu-devel@nongnu.org, qemu-arm@nongnu.org,
	kvmarm@lists.linux.dev, "Eric Auger" <eric.auger@redhat.com>,
	"Cornelia Huck" <cohuck@redhat.com>,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Richard Henderson" <richard.henderson@linaro.org>,
	"Marc Zyngier" <maz@kernel.org>,
	"Oliver Upton" <oliver.upton@linux.dev>,
	"Andrea Bolognani" <abologna@redhat.com>,
	"Jiri Denemark" <jdenemar@redhat.com>,
	"Gavin Shan" <gshan@redhat.com>,
	"Shameer Kolothum" <skolothumtho@nvidia.com>,
	"Sebastian Ott" <sebott@redhat.com>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>,
	"Jinqian Yang" <yangjinqian1@huawei.com>,
	"Shaju Abraham" <shaju.abraham@nutanix.com>,
	"Mark Cave-Ayland" <mark.caveayland@nutanix.com>
Subject: Re: [RFC PATCH v2 23/29] target/arm/qmp: add query-arm-cpu-props-info
Date: Fri, 19 Jun 2026 10:51:04 +0100	[thread overview]
Message-ID: <ajURCGaS94gwV_px@redhat.com> (raw)
In-Reply-To: <20260605083358.1320563-24-khushit.shah@nutanix.com>

On Fri, Jun 05, 2026 at 08:33:52AM +0000, Khushit Shah wrote:
> Introduce 'query-arm-cpu-props-info' QMP command. This command returns
> information about ARM CPU model properties, including their name, type,
> supported values on the given host, and composite parent if any.

Do we have to make this ARM only ?

x86 has named CPU properties too. They are all basically
booleans so this API offers a superset of functionality
needed for x86, and thus I'd expect x86 to be folded into
this new API too.

> This provides management layer necessary information to determine
> migration compatibility off a VM on different host.
> 
> Signed-off-by: Khushit Shah <khushit.shah@nutanix.com>
> ---
>  qapi/misc-arm.json              | 41 ++++++++++++++++
>  stubs/qmp-arm-gic.c             |  6 +++
>  target/arm/arm-cpu-props-stub.c | 13 +++++
>  target/arm/arm-cpu-props.c      | 85 +++++++++++++++++++++++++++++++++
>  target/arm/arm-cpu-props.h      |  5 ++
>  target/arm/arm-qmp-cmds.c       | 44 +++++++++++++++++
>  target/arm/cpu-idregs.c         | 71 +++++++++++++++++++++++++++
>  target/arm/cpu-idregs.h         |  8 ++++
>  8 files changed, 273 insertions(+)
> 
> diff --git a/qapi/misc-arm.json b/qapi/misc-arm.json
> index 4dc66d00e5..1a3fb140c4 100644
> --- a/qapi/misc-arm.json
> +++ b/qapi/misc-arm.json
> @@ -46,6 +46,47 @@
>  ##
>  { 'command': 'query-gic-capabilities', 'returns': ['GICCapability'] }
>  
> +##
> +# @CpuPropInfo:
> +#
> +# Information about a specific ARM CPU model property.
> +#
> +# @name: the name of the property
> +#
> +# @type: the type of the property, any of ('string', 'boolean',
> +#     'number').
> +#
> +# @supported-values: the set of values the host hardware supports
> +#     for the property, a list of strings.
> +#
> +# @composite: name of the encapsulating composite property if any.
> +#
> +# Since: 11.1
> +##
> +{ 'struct': 'CpuPropInfo',
> +  'data': { 'name': 'str',
> +            'type': 'str',

This should be an enumerated type, not a string.

> +            'supported-values': 'any',

If these values vary based on @type, then this should
be a discriminated union.

> +            '*composite': 'str' } }
> +

With regards,
Daniel
-- 
|: https://berrange.com       ~~        https://hachyderm.io/@berrange :|
|: https://libvirt.org          ~~          https://entangle-photo.org :|
|: https://pixelfed.art/berrange   ~~    https://fstop138.berrange.com :|


  parent reply	other threads:[~2026-06-19  9:51 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-05  8:33 [RFC PATCH v2 00/29] target/arm: Named CPU models for Arm64 on KVM Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 01/29] target/arm: named_cpu_model: define containers for ID registers and fields Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 02/29] target/arm: Add ID Register field descriptions in cpu-idregs.h.inc Khushit Shah
2026-06-12  9:35   ` Eric Auger
2026-06-12 11:01     ` Khushit Shah
2026-06-17  6:32   ` Eric Auger
2026-06-05  8:33 ` [RFC PATCH v2 03/29] target/arm: Add MIDR, REVIDR, AIDR and extra ID regs to cpu-sysregs Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 04/29] target/arm: Generate ARM64 ID registers and field tables Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 05/29] target/arm: Replace FIELD() macros with IDREG_FIELD expansion Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 06/29] target/arm: Introduce data-structures for the ARM property layer Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 07/29] target/arm: Define ARM properties Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 08/29] target/arm: Add ID register field helper functions Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 09/29] target/arm: Add all ARM64 properties to host model Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 10/29] target/arm: Add named cpu model infra + graviton3 named model Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 11/29] target/arm: Add Nvidia Grace " Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 12/29] target/arm/kvm: Writeback modified ID registers to KVM Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 13/29] target/arm/kvm: enable writable implementation ID registers Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 14/29] target/arm: Validate cpu->isar.idregs[] before writeback Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 15/29] target/arm/kvm: handle DCZID_EL0 specially Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 16/29] target/arm: skip GIC, COPDBG and PMU fields during KVM writeback Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 17/29] target/arm: Add composite property type to model definitions Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 18/29] target/arm: define pauth composite property Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 19/29] target/arm: define sve " Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 20/29] target/arm: Introduce stub files required for qmp support Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 21/29] target/arm/qmp: add named models and properties to cpu-model-expansion Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 22/29] target/arm/kvm: introduce kvm_arm_get_host_isar helper Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 23/29] target/arm/qmp: add query-arm-cpu-props-info Khushit Shah
2026-06-19  9:25   ` Markus Armbruster
2026-06-19 11:54     ` Khushit Shah
2026-06-19  9:51   ` Daniel P. Berrangé [this message]
2026-06-19 11:06     ` Andrea Bolognani
2026-06-19 12:04     ` Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 24/29] target/arm: Report "off" for ID fields gated by vCPU init flags Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 25/29] target/arm/qmp: hook blockers in query-cpu-definitions Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 26/29] target/arm: Support exposing cache information for named cpu models Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 27/29] target/arm: Provide default cache hierarchy Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 28/29] target/arm: supported-values and blockers for CCSIDR cache properties Khushit Shah
2026-06-05  8:33 ` [RFC PATCH v2 29/29] target/arm/kvm: fix host model writeback when kernel supports EL2 Khushit Shah
2026-06-12 14:50 ` [RFC PATCH v2 00/29] target/arm: Named CPU models for Arm64 on KVM Eric Auger
2026-06-15  5:45   ` Khushit Shah
2026-06-15 16:15     ` Eric Auger

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=ajURCGaS94gwV_px@redhat.com \
    --to=berrange@redhat.com \
    --cc=abologna@redhat.com \
    --cc=armbru@redhat.com \
    --cc=cohuck@redhat.com \
    --cc=eric.auger@redhat.com \
    --cc=gshan@redhat.com \
    --cc=jdenemar@redhat.com \
    --cc=khushit.shah@nutanix.com \
    --cc=kvmarm@lists.linux.dev \
    --cc=mark.caveayland@nutanix.com \
    --cc=maz@kernel.org \
    --cc=oliver.upton@linux.dev \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=sebott@redhat.com \
    --cc=shaju.abraham@nutanix.com \
    --cc=skolothumtho@nvidia.com \
    --cc=yangjinqian1@huawei.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 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.