Revision 494c2717 hw/cpu/icc_bus.c

b/hw/cpu/icc_bus.c
43 43

  
44 44
static void icc_device_realize(DeviceState *dev, Error **errp)
45 45
{
46
    ICCDevice *id = ICC_DEVICE(dev);
47
    ICCDeviceClass *idc = ICC_DEVICE_GET_CLASS(id);
48

  
49
    if (idc->init) {
50
        if (idc->init(id) < 0) {
51
            error_setg(errp, "%s initialization failed.",
52
                       object_get_typename(OBJECT(dev)));
53
        }
46
    ICCDeviceClass *idc = ICC_DEVICE_GET_CLASS(dev);
47

  
48
    /* convert to QOM */
49
    if (idc->realize) {
50
        idc->realize(dev, errp);
54 51
    }
52

  
55 53
}
56 54

  
57 55
static void icc_device_class_init(ObjectClass *oc, void *data)

Also available in: Unified diff