qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 06/15] piix: create i8254 through composition


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH 06/15] piix: create i8254 through composition
Date: Tue, 31 Jan 2012 17:59:12 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:9.0) Gecko/20111222 Thunderbird/9.0

On 01/31/2012 05:47 PM, Anthony Liguori wrote:


static void object_initialize(Object *obj)
{
     PIIX3State *s = PIIX3(obj);
     ChildProperty props[] = {
       { "pic[0]", TYPE_I8259, &s->pic[0] },
       { "pic[1]", TYPE_I8259, &s->pic[1] },
     };

     object_property_add_children(obj, props, ARRAY_SIZE(props));
}

Is much nicer IMHO.

Fine, but then children devices will not use the same memory block as the parent. Not a huge difference, but worth pointing it out.

Paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]