qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Zhi Yong Wu <zwu.kernel@gmail.com>
Cc: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>,
	qemu-devel@nongnu.org, stefanha@linux.vnet.ibm.com
Subject: Re: [Qemu-devel] [RFC 1/9] hostdev: introduce the infrastructure for host device model
Date: Tue, 27 Mar 2012 16:50:11 +0200	[thread overview]
Message-ID: <4F71D3A3.5030506@redhat.com> (raw)
In-Reply-To: <CAEH94LhURwxQPp652tM=Yv3u2-nNubvuX_UYDThx=PvDqyi3vQ@mail.gmail.com>

Il 27/03/2012 16:18, Zhi Yong Wu ha scritto:
> On Tue, Mar 27, 2012 at 9:58 PM, Paolo Bonzini <pbonzini@redhat.com> wrote:
>> Il 27/03/2012 13:59, Zhi Yong Wu ha scritto:
>>> On Tue, Mar 27, 2012 at 6:15 PM, Paolo Bonzini <pbonzini@redhat.com> wrote:
>>>> Il 27/03/2012 11:06, Zhi Yong Wu ha scritto:
>>>>>>>>> +#define DEFINE_HOSTDEV_PROP_PEER(_n, _s, _f)             \
>>>>>>>>> +    DEFINE_HOSTDEV_PROP(_n, _s, _f, hostdev_prop_netdev, NetClientState*)
>>>>>>>
>>>>>>> This should be simply a link<NetDev> property.
>>>>> IMHO, i don't fully understand what link<NetDev> mean. What is the
>>>>> difference between it and Child<NetDev>. Can you elaborate this?
>>>>
>>>> link<NetDev> is a pointer to another object.  child<NetDev> means that
>>> Where are link<NetDev> used?
>>
>> The peer property needs to be one.
> sorry, i don't get what it means.

Links are pointers.  As you convert host devices to QOM, pointer
properties such as drive or chardev need to become links.  Peer is
another pointer property that needs to become a link.

>>> what is relationship between the two objects?
>>
>> A has a pointer to B.
>
> I knew this, but can you say one example in QEMU device model? I
> checked QEMU code, and found that those link functions in object.c are
> not currently used. right?

Yes, that's correct.  Everything that uses PROP_PTR needs to become a
link.  We cannot do that yet because devices do not yet have a canonical
path.

>>> Moreover, -device has exposed network card info.
>>
>> ... this is extremely confused.  Each NIC device has a NIC-type
>> NetClientState.  If NetClientState is converted to QOM, all of its
> The original idea about -netdev QOM is to convert NetClientState to
> QOM, but now this idea seems to be changed.

I cannot parse this at all.  You have not converted all of
NetClientState to QOM, have you?

>>> We hope that -netdev options info can be configurated or changed
>>> purely via QOM, not command line.
>>
>> Yes, but does it buy anything or it is just a nice exercise?
> 
> buy anything? sorry, i don't understand this.

What's the advantage?  Converting chardev would give hotplug.  What can
we do with a QOMified netdev that we cannot do now?

Paolo

  reply	other threads:[~2012-03-27 14:50 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-26  5:40 [Qemu-devel] [RFC 0/9] QOM: qomify -netdev zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 1/9] hostdev: introduce the infrastructure for host device model zwu.kernel
2012-03-26  5:54   ` Zhi Yong Wu
2012-03-27  8:23   ` Paolo Bonzini
2012-03-27  9:06     ` Zhi Yong Wu
2012-03-27 10:15       ` Paolo Bonzini
2012-03-27 11:59         ` Zhi Yong Wu
2012-03-27 13:58           ` Paolo Bonzini
2012-03-27 14:18             ` Zhi Yong Wu
2012-03-27 14:50               ` Paolo Bonzini [this message]
2012-03-27 21:21                 ` Zhi Yong Wu
2012-03-28  6:41                   ` Paolo Bonzini
2012-03-28  7:50                     ` Zhi Yong Wu
2012-03-28  7:53                     ` Zhi Yong Wu
2012-03-28  8:02                       ` Paolo Bonzini
2012-03-28  8:05                         ` 陳韋任
2012-03-28  8:25                           ` Zhi Yong Wu
2012-03-28  8:29                             ` 陳韋任
2012-03-26  5:40 ` [Qemu-devel] [PATCH] net: qomify -netdev zwu.kernel
2012-03-26  5:40 ` zwu.kernel
2012-03-26  5:44   ` Zhi Yong Wu
2012-03-26  5:40 ` [Qemu-devel] [RFC 2/9] net: introduce one net host device class zwu.kernel
2012-03-27  8:30   ` Paolo Bonzini
2012-03-27  9:13     ` Zhi Yong Wu
2012-03-26  5:40 ` [Qemu-devel] [RFC 3/9] net: adjust net common part for qomify -netdev zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 4/9] net: adjust nic init API zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 5/9] net: adjust dump " zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 6/9] net: qomify -netdev user zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 7/9] net: qomify -netdev socket zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 8/9] net: qomify -netdev vde zwu.kernel
2012-03-26  5:40 ` [Qemu-devel] [RFC 9/9] net: qomify -netdev tap & -netdev bridge zwu.kernel
2012-03-26 11:54 ` [Qemu-devel] [RFC 0/9] QOM: qomify -netdev Stefan Hajnoczi
2012-03-26 14:20   ` Zhi Yong Wu
2012-03-27  8:19     ` Paolo Bonzini
2012-03-27  9:03       ` Zhi Yong Wu
2012-03-26 14:39   ` Andreas Färber
2012-03-26 14:57     ` Stefan Hajnoczi
2012-03-26 15:01     ` Zhi Yong Wu

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=4F71D3A3.5030506@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@linux.vnet.ibm.com \
    --cc=wuzhy@linux.vnet.ibm.com \
    --cc=zwu.kernel@gmail.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).