Skip to content

Commit

Permalink
virtio-s390-device: create a virtio-s390-bus during init.
Browse files Browse the repository at this point in the history
A virtio-s390-bus is created during the init. So one VirtIODevice can be
connected on the virtio-s390-device through this bus.

Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
  • Loading branch information
konrad-fred authored and Anthony Liguori committed Jan 21, 2013
1 parent ea35d4f commit 11e9235
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions hw/s390-virtio-bus.c
Expand Up @@ -503,6 +503,8 @@ static int s390_virtio_busdev_init(DeviceState *dev)
VirtIOS390Device *_dev = (VirtIOS390Device *)dev;
VirtIOS390DeviceClass *_info = VIRTIO_S390_DEVICE_GET_CLASS(dev);

virtio_s390_bus_new(&_dev->bus, _dev);

return _info->init(_dev);
}

Expand Down
1 change: 1 addition & 0 deletions hw/s390-virtio-bus.h
Expand Up @@ -96,6 +96,7 @@ struct VirtIOS390Device {
virtio_net_conf net;
VirtIOSCSIConf scsi;
VirtIORNGConf rng;
VirtioBusState bus;
};

typedef struct VirtIOS390Bus {
Expand Down

0 comments on commit 11e9235

Please sign in to comment.