On Mon, Dec 12, 2011 at 7:36 PM, Anthony Liguori <anth...@codemonkey.ws> wrote: > I choose the serial device to showcase what we'll eventually be able to do. > The three relevant files are: > > https://github.com/aliguori/qemu/blob/qom-next/hw/isa-serial.c > > https://github.com/aliguori/qemu/blob/qom-next/hw/mm-serial.c > > https://github.com/aliguori/qemu/blob/qom-next/hw/serial.c
I'm not sure I understand how init functions are called for derived classes. On one hand mm-serial.c calls its superclass init function, on the other hand isa-bus.c:isa_qdev_init() calls an init function that its child class must provide. One is calling its parent, the other is calling its child. Is there a consistent way of doing this and what did I miss :)? Stefan