All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Liviu Ionescu <ilg@livius.net>,
	Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Cc: "Andreas Färber" <afaerber@suse.de>,
	"QEMU Developers" <Qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [RFC] QDev explicit constructors & destructors
Date: Wed, 24 Jun 2015 10:51:12 +0200	[thread overview]
Message-ID: <558A6F80.2060609@redhat.com> (raw)
In-Reply-To: <5B7FDD61-18AF-4024-9254-7B96582540E9@livius.net>



On 23/06/2015 22:10, Liviu Ionescu wrote:
> I suggest your review should start from use cases like this:
> 
>     DeviceState *dev = my_dev_alloc(NULL, TYPE_MYTYPE);
>     my_dev_prop_set_bool(dev, "param", true);
>     my_dev_construct(OBJECT(dev), NULL);
>     my_dev_prop_set_uint32(dev, "xyz", 123);
>     my_dev_realize(dev);
> 
> please ignore the fictional function names, and just assume that constructing the object requires a parameter that is given on the command line, so it does not exist statically at .instance_init time.
> 
> the point here is that "xyz" is an alias, created during construction time.

Can you explain this with real function names and parameters?

Paolo

      parent reply	other threads:[~2015-06-24  8:51 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-15 10:48 [Qemu-devel] [RFC] QDev explicit constructors & destructors Liviu Ionescu
2015-06-15 11:13 ` Liviu Ionescu
2015-06-15 13:35 ` Liviu Ionescu
2015-06-22 20:48   ` Liviu Ionescu
2015-06-23  7:47     ` Markus Armbruster
2015-06-23  9:12       ` Liviu Ionescu
2015-06-23 10:39   ` Andreas Färber
2015-06-23 12:58     ` Liviu Ionescu
2015-06-23 14:25       ` Andreas Färber
2015-06-23 16:15         ` Liviu Ionescu
2015-06-23 18:31         ` Peter Crosthwaite
2015-06-23 19:10           ` Liviu Ionescu
2015-06-23 20:57             ` Peter Crosthwaite
2015-06-23 21:24               ` Liviu Ionescu
2015-06-23 19:27           ` Andreas Färber
2015-06-23 20:10           ` Liviu Ionescu
2015-06-24  7:30             ` Liviu Ionescu
2015-06-24  8:29               ` Peter Crosthwaite
2015-06-24  9:29                 ` Liviu Ionescu
2015-06-24  9:51                   ` Paolo Bonzini
2015-06-24 13:41                     ` Andreas Färber
2015-06-24 13:50                   ` Andreas Färber
2015-06-24 14:11                     ` Liviu Ionescu
2015-06-24 14:18                       ` Andreas Färber
2015-06-24 14:39                         ` Liviu Ionescu
2015-06-24 14:41                           ` Andreas Färber
2015-06-24 20:14                       ` Liviu Ionescu
2015-06-24  8:51             ` Paolo Bonzini [this message]

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=558A6F80.2060609@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=Qemu-devel@nongnu.org \
    --cc=afaerber@suse.de \
    --cc=ilg@livius.net \
    --cc=peter.crosthwaite@xilinx.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.