Assigned ID could not be used for net-client name

Bug #1179357 reported by Amos Jianjun Kong
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Fix Released
Undecided
Unassigned

Bug Description

As discussed in maillist: http://lists.nongnu.org/archive/html/qemu-devel/2013-04/msg03582.html

[this problem still existed in latest qemu.git]

qemu -device virtio-net-pci,netdev=ndev1,id=id1 -netdev tap,id=ndev1 \
              -device e1000,netdev=ndev2,id=id2 -netdev tap,id=ndev2

(qemu) info network
virtio-net-device.0: index=0,type=nic,model=virtio-net-device,macaddr=52:54:00:12:34:56
 \ ndev1: index=0,type=tap,ifname=tap0,script=/etc/qemu-ifup,downscript=/etc/qemu-ifdown
id2: index=0,type=nic,model=e1000,macaddr=52:54:00:12:34:57
 \ ndev2: index=0,type=tap,ifname=tap1,script=/etc/qemu-ifup,downscript=/etc/qemu-ifdown

net-client name of virtio-nic should be 'id1'

(qemu) device_del virtio-net-device.0
Device 'virtio-net-device.0' not found
(qemu) device_del id1 (will cause the hot-removing action)

It's a regression caused by commit: e37da3945fa2fde161e1b217f937fc318c4b7639

commit e37da3945fa2fde161e1b217f937fc318c4b7639
Author: KONRAD Frederic <email address hidden>
Date: Thu Apr 11 16:29:58 2013 +0200

    virtio-net-pci: switch to the new API.

    Here the virtio-net-pci is modified for the new API. The device
    virtio-net-pci extends virtio-pci. It creates and connects a
    virtio-net-device during the init. The properties are not changed.

    Signed-off-by: KONRAD Frederic <email address hidden>
    Tested-by: Cornelia Huck <email address hidden>
    Message-id: <email address hidden>
    Signed-off-by: Anthony Liguori <email address hidden>

Revision history for this message
Lei Li (matrixs-zero) wrote :

Yes, I agree with that this is a bug.
The id of virtio-net-device should be 'id1' not 'virtio-net-device.0'.

Changed in qemu:
status: New → Confirmed
Changed in qemu:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers