Re: [Qemu-devel] [PATCH v2 2/7] ioapic: convert to qdev

2010-06-14 Thread Markus Armbruster
Blue Swirl blauwir...@gmail.com writes: Convert to qdev. Signed-off-by: Blue Swirl blauwir...@gmail.com --- hw/apic.h|2 -- hw/ioapic.c | 45 ++--- hw/pc.h |4 +++- hw/pc_piix.c | 19 ++- 4 files changed, 51

Re: [Qemu-devel] [PATCH v2 2/7] ioapic: convert to qdev

2010-06-14 Thread Blue Swirl
On Mon, Jun 14, 2010 at 9:33 AM, Markus Armbruster arm...@redhat.com wrote: Blue Swirl blauwir...@gmail.com writes: Convert to qdev. Signed-off-by: Blue Swirl blauwir...@gmail.com ---  hw/apic.h    |    2 --  hw/ioapic.c  |   45 ++---  hw/pc.h      

Re: [Qemu-devel] [PATCH v2 2/7] ioapic: convert to qdev

2010-06-14 Thread Paul Brook
-static void ioapic_reset(void *opaque) +static void ioapic_reset(DeviceState *d) { -IOAPICState *s = opaque; +IOAPICState *s = container_of(d, IOAPICState, busdev.qdev); DO_UPCAST()? I hate it, but it's what the other devices do... Both are used: grep container_of

[Qemu-devel] [PATCH v2 2/7] ioapic: convert to qdev

2010-06-12 Thread Blue Swirl
Convert to qdev. Signed-off-by: Blue Swirl blauwir...@gmail.com --- hw/apic.h|2 -- hw/ioapic.c | 45 ++--- hw/pc.h |4 +++- hw/pc_piix.c | 19 ++- 4 files changed, 51 insertions(+), 19 deletions(-) diff --git