aboutsummaryrefslogtreecommitdiff
path: root/hw/s390x/virtio-ccw-scsi.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/s390x/virtio-ccw-scsi.c')
-rw-r--r--hw/s390x/virtio-ccw-scsi.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/hw/s390x/virtio-ccw-scsi.c b/hw/s390x/virtio-ccw-scsi.c
index 3cb3ad669d..6e4beef700 100644
--- a/hw/s390x/virtio-ccw-scsi.c
+++ b/hw/s390x/virtio-ccw-scsi.c
@@ -33,8 +33,7 @@ static void virtio_ccw_scsi_realize(VirtioCcwDevice *ccw_dev, Error **errp)
g_free(bus_name);
}
- qdev_set_parent_bus(vdev, BUS(&ccw_dev->bus));
- object_property_set_bool(OBJECT(vdev), true, "realized", errp);
+ qdev_realize(vdev, BUS(&ccw_dev->bus), errp);
}
static void virtio_ccw_scsi_instance_init(Object *obj)
@@ -78,8 +77,7 @@ static void vhost_ccw_scsi_realize(VirtioCcwDevice *ccw_dev, Error **errp)
VHostSCSICcw *dev = VHOST_SCSI_CCW(ccw_dev);
DeviceState *vdev = DEVICE(&dev->vdev);
- qdev_set_parent_bus(vdev, BUS(&ccw_dev->bus));
- object_property_set_bool(OBJECT(vdev), true, "realized", errp);
+ qdev_realize(vdev, BUS(&ccw_dev->bus), errp);
}
static void vhost_ccw_scsi_instance_init(Object *obj)