> >> -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:
>
On Mon, Jun 14, 2010 at 9:33 AM, Markus Armbruster wrote:
> Blue Swirl writes:
>
>> Convert to qdev.
>>
>> Signed-off-by: Blue Swirl
>> ---
>> hw/apic.h | 2 --
>> hw/ioapic.c | 45 ++---
>> hw/pc.h | 4 +++-
>> hw/pc_piix.c | 19 ++
Blue Swirl writes:
> Convert to qdev.
>
> Signed-off-by: Blue Swirl
> ---
> hw/apic.h|2 --
> hw/ioapic.c | 45 ++---
> hw/pc.h |4 +++-
> hw/pc_piix.c | 19 ++-
> 4 files changed, 51 insertions(+), 19 deletions(-)
>
Convert to qdev.
Signed-off-by: Blue Swirl
---
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 a/hw/apic.h b/hw/apic.h
inde