diff options
author | KONRAD Frederic <fred.konrad@greensocs.com> | 2013-03-18 17:37:25 +0100 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2013-03-18 13:08:40 -0500 |
commit | 3400c455048a8db26db1b537ea32fa21335ea301 (patch) | |
tree | de9219ca74a7a5f819d69c5e62b449e86c943815 /hw/s390x/virtio-ccw.h | |
parent | 55d11e01cca9b83b8cdccbd29d4f078cbe4a185c (diff) |
virtio-blk-ccw switch to new API.
Here the virtio-ccw-s390 is modified for the new API. The device
virtio-ccw-s390 extends virtio-ccw-device as before. It creates and
connects a virtio-ccw during the init. The properties are not modified.
Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 1363624648-16906-9-git-send-email-fred.konrad@greensocs.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/s390x/virtio-ccw.h')
-rw-r--r-- | hw/s390x/virtio-ccw.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/hw/s390x/virtio-ccw.h b/hw/s390x/virtio-ccw.h index 88c46c081b..3993bc53b0 100644 --- a/hw/s390x/virtio-ccw.h +++ b/hw/s390x/virtio-ccw.h @@ -72,7 +72,6 @@ struct VirtioCcwDevice { SubchDev *sch; VirtIODevice *vdev; char *bus_id; - VirtIOBlkConf blk; NICConf nic; uint32_t host_features[VIRTIO_CCW_FEATURE_SIZE]; virtio_serial_conf serial; @@ -94,6 +93,19 @@ typedef struct VirtualCssBus { #define VIRTUAL_CSS_BUS(obj) \ OBJECT_CHECK(VirtualCssBus, (obj), TYPE_VIRTUAL_CSS_BUS) +/* virtio-blk-ccw */ + +#define TYPE_VIRTIO_BLK_CCW "virtio-blk-ccw" +#define VIRTIO_BLK_CCW(obj) \ + OBJECT_CHECK(VirtIOBlkCcw, (obj), TYPE_VIRTIO_BLK_CCW) + +typedef struct VirtIOBlkCcw { + VirtioCcwDevice parent_obj; + VirtIOBlock vdev; + VirtIOBlkConf blk; +} VirtIOBlkCcw; + + VirtualCssBus *virtual_css_bus_init(void); void virtio_ccw_device_update_status(SubchDev *sch); VirtIODevice *virtio_ccw_get_vdev(SubchDev *sch); |