From: Eric Blake <eblake@redhat.com>
To: Markus Armbruster <armbru@redhat.com>,
Alexey Kirillov <lekiravi@yandex-team.ru>
Cc: Laurent Vivier <lvivier@redhat.com>,
Thomas Huth <thuth@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Stefan Weil <sw@weilnetz.de>, Jason Wang <jasowang@redhat.com>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
Vincenzo Maffione <v.maffione@gmail.com>,
"yc-core@yandex-team.ru" <yc-core@yandex-team.ru>,
Paolo Bonzini <pbonzini@redhat.com>,
Samuel Thibault <samuel.thibault@ens-lyon.org>,
Giuseppe Lettieri <g.lettieri@iet.unipi.it>,
Luigi Rizzo <rizzo@iet.unipi.it>
Subject: Re: [PATCH v3 1/4] qapi: net: Add query-netdevs command
Date: Tue, 8 Sep 2020 07:36:47 -0500 [thread overview]
Message-ID: <b632d444-bdf9-648b-9d55-a9e72efb8fbc@redhat.com> (raw)
In-Reply-To: <871rjdrca0.fsf@dusky.pond.sub.org>
On 9/7/20 7:39 AM, Markus Armbruster wrote:
>>>
>>> This is union Netdev plus a common member @peer-id, less the variant
>>> members for NetClientDriver values 'nic' and 'hubport'.
>>>
>>> Can 'type: 'nic' and 'type': 'hubport' occur?
>>
>> No, it can't. We don't support NIC/hubport in query-netdevs, so we neither create this
>> structure for them, nor store config.
>
> Same for 'none', I guess.
>
> As defined, NetdevInfo allows types 'none', 'nic', and 'hubport', it
> just has no variant members for them. The fact that they can't occur is
> not coded into the type, and therefore not visible in introspection.
>
> To make introspection more precise, we'd have to define a new enum type.
> How much that would complicate the C code is unclear.
>
> Do we need it to be more precise? Eric, got an opinion?
Is the problem that a new enum would be duplicating things? Is it worth
allowing one enum to have a 'base':'OtherEnum' in the schema to reduce
some of the duplication?
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org
next prev parent reply other threads:[~2020-09-08 12:39 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-01 18:23 [PATCH v3 0/4] Introducing QMP query-netdevs command Alexey Kirillov
2020-09-01 18:23 ` [PATCH v3 1/4] qapi: net: Add " Alexey Kirillov
2020-09-02 11:23 ` Markus Armbruster
2020-09-07 10:37 ` Alexey Kirillov
2020-09-07 12:39 ` Markus Armbruster
2020-09-08 12:36 ` Eric Blake [this message]
2020-09-08 14:31 ` Markus Armbruster
2020-09-16 9:37 ` Alexey Kirillov
2020-09-16 11:28 ` Markus Armbruster
2020-09-08 15:52 ` Alexey Kirillov
2020-09-09 11:41 ` Markus Armbruster
2020-09-09 12:45 ` Alexey Kirillov
2020-09-08 14:29 ` Markus Armbruster
2020-09-08 15:52 ` Alexey Kirillov
2020-09-01 18:23 ` [PATCH v3 2/4] tests: Add tests for " Alexey Kirillov
2020-09-01 18:23 ` [PATCH v3 3/4] hmp: Use QMP query-netdevs in hmp_info_network Alexey Kirillov
2020-09-01 18:23 ` [PATCH v3 4/4] net: Do not use legacy info_str for backends Alexey Kirillov
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=b632d444-bdf9-648b-9d55-a9e72efb8fbc@redhat.com \
--to=eblake@redhat.com \
--cc=armbru@redhat.com \
--cc=g.lettieri@iet.unipi.it \
--cc=jasowang@redhat.com \
--cc=lekiravi@yandex-team.ru \
--cc=lvivier@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rizzo@iet.unipi.it \
--cc=samuel.thibault@ens-lyon.org \
--cc=sw@weilnetz.de \
--cc=thuth@redhat.com \
--cc=v.maffione@gmail.com \
--cc=yc-core@yandex-team.ru \
/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).