I'm trying to port an implementation of an ARM-based SoC from QEMU 1.4 to QEMU 1.5.
qom/object.c:919:void object_property_add_child(Object *, const char *, Object *, Error **): assertion failed: (child->parent == NULL)
object_property_add_child(object_get_root(), "device-name", OBJECT(dev), NULL);
after the device is created and initialized, using sysbus_create_simple().
I may have written something really stupid that used to work till QEMU 1.5 - and now it bites hard :-)
The child seems to be already added to the composition tree, as object_get_canonical_path() gives /machine/unattached/device[2] for this device.
I'm not sure about the proper way to address this issue:
* is there a way to declare the the proper device 'path' at creation time?
* should I 'remove' the device from the '/machine/unattached' tree before attempting to add it to the proper tree?
Any advice or example would be great, as I'm obviously doing something wrong, and I'd like to fix this the 'clean' way.
Thanks,
Manu.