mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 18:23:57 -06:00
virtio-net-x: forward the netclient name and type.
This forwards the name and the type of virtio-net-x to fix the bad behaviour of "info network" command. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Message-id: 1368619970-23892-3-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
8a253ec26e
commit
800ced8cac
3 changed files with 9 additions and 0 deletions
|
@ -550,10 +550,13 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev)
|
|||
|
||||
static int virtio_ccw_net_init(VirtioCcwDevice *ccw_dev)
|
||||
{
|
||||
DeviceState *qdev = DEVICE(ccw_dev);
|
||||
VirtIONetCcw *dev = VIRTIO_NET_CCW(ccw_dev);
|
||||
DeviceState *vdev = DEVICE(&dev->vdev);
|
||||
|
||||
virtio_net_set_config_size(&dev->vdev, ccw_dev->host_features[0]);
|
||||
virtio_net_set_netclient_name(&dev->vdev, qdev->id,
|
||||
object_get_typename(OBJECT(qdev)));
|
||||
qdev_set_parent_bus(vdev, BUS(&ccw_dev->bus));
|
||||
if (qdev_init(vdev) < 0) {
|
||||
return -1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue