one of the two assigned NICs doesn’t work in SMP guest.

Bug #953754 reported by Yongjie Ren
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Fix Released
Undecided
Unassigned

Bug Description

Environment:
------------
Host OS (ia32/ia32e/IA64):ia32e
Guest OS (ia32/ia32e/IA64):ia32e
Guest OS Type (Linux/Windows): Linux(RHEL6u1)
kvm.git Commit:186195928e8149b27cdd603a660dace454969f2b
qemu-kvm Commit: 81bdec908fb2be0ccaff1d4ee67956c509e440ad
Host Kernel Version:3.3.0-rc5
Hardware: Romley-EP, WSM-EP

Bug detailed description:
--------------------------
SMP guest cannot get two IP addresses when assign two NICs with igb driver.
I tried with Intel I350 and 82576 Ethernet Adapter.

Note:
     1. when assign two NICs, both of the drivers are igb, but the guest can only get one IP.
     2. When assign two NICs, one driver is igb, another is ixgbe, the guest can get two IP address.
     3. UP guest can get two IP.
     4. smp guest, and assign two VFs with igbvf driver, the guest can get two IP addresses.

This should be a qemu-kvm bug.
kvm + qemu-kvm = result
18619592 + 81bdec90 = bad
18619592 + b5ed4b6f = good

Reproduce steps:
----------------
1. start up a host with kvm kernel
2. /root/pcistub.sh –h 08:00.0
3. /root/pcistub.sh –h 0d:00.1
4. qemu-system-x86_64 –m 512 –smp 2 –device pci-assign,host=0d:00.1
–net none –device pci-assign,host=08:00.0 –net none –hda
/root/rhel6u1.img
5. ifconfig

Current result:
----------------
Only one can work

Expected result:
----------------
Both NICs can work

Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

And if you try with smp=4, you may see some error info from qemu.
"assigned_dev_update_msix_mmio: No such device or address
fail to set MSI-X entry number for MSIX! Invalid argument"
The message is generated from the funtion "assigned_dev_update_msix_mmio" in
hw/device-assignment.c
1035 r = kvm_assign_set_msix_entry(kvm_state, &msix_entry);
1036 if (r) {
1037 fprintf(stderr, "fail to set MSI-X entry! %s\n",
strerror(-r));
1038 break;
1039 }

Some logs:
[root@vt-nhm9 jay]# qemu-system-x86_64 -m 512 -smp 4 -device
pci-assign,host=11:00.0,id=nic1 -net none -device
pci-assign,host=11:00.1,id=nic2 -net none -hda rhel6u1.qcow
Could not open option rom 'kvmvapic.bin': No such file or directory
Could not open option rom 'vapic.bin': No such file or directory
VNC server running on `::1:5900'
assigned_dev_update_msix_mmio: No such device or address
fail to set MSI-X entry number for MSIX! Invalid argument
assigned_dev_update_msix_mmio: Invalid argument
fail to set MSI-X entry number for MSIX! Invalid argument
assigned_dev_update_msix_mmio: Invalid argument
fail to set MSI-X entry number for MSIX! Invalid argument
assigned_dev_update_msix_mmio: Invalid argument
fail to set MSI-X entry number for MSIX! Invalid argument
assigned_dev_update_msix_mmio: Invalid argument

Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :
description: updated
description: updated
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

It was fixed in latest qemu-kvm tree.
verified it against kvm + qemu-kvm: 331b646d..+ e54f008e..

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

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.