From: Stefan Hajnoczi <stefanha@redhat.com>
To: Kevin Wolf <kwolf@redhat.com>
Cc: qemu-devel@nongnu.org, "Michal Privoznik" <mprivozn@redhat.com>,
"Hanna Reitz" <hreitz@redhat.com>,
qemu-block@nongnu.org, "Michael S. Tsirkin" <mst@redhat.com>,
"Daniel P. Berrangé" <berrange@redhat.com>,
"Michael Roth" <michael.roth@amd.com>,
"Eduardo Habkost" <eduardo@habkost.net>,
"Eric Blake" <eblake@redhat.com>,
"Markus Armbruster" <armbru@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>
Subject: Re: [PATCH v4 1/4] qdev-properties: alias all object class properties
Date: Thu, 21 Dec 2023 10:47:43 -0500 [thread overview]
Message-ID: <20231221154743.GA1754997@fedora> (raw)
In-Reply-To: <ZYQyFLfsOvUmeuco@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1880 bytes --]
On Thu, Dec 21, 2023 at 01:39:48PM +0100, Kevin Wolf wrote:
> Am 20.12.2023 um 14:47 hat Stefan Hajnoczi geschrieben:
> > qdev_alias_all_properties() aliases a DeviceState's qdev properties onto
> > an Object. This is used for VirtioPCIProxy types so that --device
> > virtio-blk-pci has properties of its embedded --device virtio-blk-device
> > object.
> >
> > Currently this function is implemented using qdev properties. Change the
> > function to use QOM object class properties instead. This works because
> > qdev properties create QOM object class properties, but it also catches
> > any QOM object class-only properties that have no qdev properties.
> >
> > This change ensures that properties of devices are shown with --device
> > foo,\? even if they are QOM object class properties.
> >
> > Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
>
> Reviewed-by: Kevin Wolf <kwolf@redhat.com>
>
> We should also update the comment to refer to properties in general
> rather than just qdev properties. I can squash in the following hunk.
Please go ahead. Thank you!
Stefan
> diff --git a/include/hw/qdev-properties.h b/include/hw/qdev-properties.h
> index 25743a29a0..09aa04ca1e 100644
> --- a/include/hw/qdev-properties.h
> +++ b/include/hw/qdev-properties.h
> @@ -230,8 +230,8 @@ void qdev_property_add_static(DeviceState *dev, Property *prop);
> * @target: Device which has properties to be aliased
> * @source: Object to add alias properties to
> *
> - * Add alias properties to the @source object for all qdev properties on
> - * the @target DeviceState.
> + * Add alias properties to the @source object for all properties on the @target
> + * DeviceState.
> *
> * This is useful when @target is an internal implementation object
> * owned by @source, and you want to expose all the properties of that
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2023-12-21 15:48 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-20 13:47 [PATCH v4 0/4] virtio-blk: add iothread-vq-mapping parameter Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 1/4] qdev-properties: alias all object class properties Stefan Hajnoczi
2023-12-21 12:39 ` Kevin Wolf
2023-12-21 15:47 ` Stefan Hajnoczi [this message]
2023-12-20 13:47 ` [PATCH v4 2/4] string-output-visitor: show structs as "<omitted>" Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 3/4] qdev: add IOThreadVirtQueueMappingList property type Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 4/4] virtio-blk: add iothread-vq-mapping parameter Stefan Hajnoczi
2023-12-21 13:10 ` Kevin Wolf
2024-01-18 21:28 ` Stefan Hajnoczi
2023-12-21 13:40 ` Kevin Wolf
2024-01-19 13:41 ` Stefan Hajnoczi
2023-12-21 21:07 ` [PATCH v4 0/4] " Kevin Wolf
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=20231221154743.GA1754997@fedora \
--to=stefanha@redhat.com \
--cc=armbru@redhat.com \
--cc=berrange@redhat.com \
--cc=eblake@redhat.com \
--cc=eduardo@habkost.net \
--cc=hreitz@redhat.com \
--cc=kwolf@redhat.com \
--cc=michael.roth@amd.com \
--cc=mprivozn@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.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.