@@ -104,6 +104,7 @@ static XICSState *try_create_xics(const char *type, int nr_servers,
dev = DEVICE(object_new(type));
qdev_prop_set_uint32(dev, "nr_servers", nr_servers);
qdev_prop_set_uint32(dev, "nr_irqs", nr_irqs);
+ qdev_set_parent_bus(dev, sysbus_get_default());
object_property_set_bool(OBJECT(dev), true, "realized", &err);
if (err) {
error_propagate(errp, err);
@@ -80,7 +80,7 @@ struct XICSStateClass {
struct XICSState {
/*< private >*/
- SysBusDevice parent_obj;
+ DeviceState parent_obj;
/*< public >*/
uint32_t nr_servers;
uint32_t nr_irqs;
commit 5b17c7207938 ("xics: XICS should not be a SysBusDevice") changed the nature of the XICS object to be a descendent of TYPE_DEVICE. By doing so, the object is not on a bus and its reset handler is not called anymore. The direct consequence is that the ICP and ICS objects are not correctly initialized and so the IRQ subsystem is broken in the guest. Signed-off-by: Cédric Le Goater <clg@kaod.org> --- hw/ppc/spapr.c | 1 + include/hw/ppc/xics.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)