Bug 1025477 - VFIO MSI affinity
Summary: VFIO MSI affinity
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm
Version: 7.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Alex Williamson
QA Contact: Virtualization Bugs
URL:
Whiteboard:
: 1004373 (view as bug list)
Depends On:
Blocks: 896690 969793
TreeView+ depends on / blocked
 
Reported: 2013-10-31 19:06 UTC by Alex Williamson
Modified: 2014-06-18 03:40 UTC (History)
10 users (show)

Fixed In Version: qemu-kvm-1.5.3-17.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-13 09:49:42 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Alex Williamson 2013-10-31 19:06:52 UTC
Description of problem:
VFIO is missing affinity support for MSI (MSI-X is already present)

Version-Release number of selected component (if applicable):


How reproducible:
100%

Steps to Reproduce:
1. Attempt to change IRQ affinity of a vfio-pci assigned device using MSI interrupts
2.
3.

Actual results:
interrupted vcpu unchanged

Expected results:
interrupted vcpu tracks user request

Additional info:

Comment 2 Miroslav Rezanina 2013-11-07 15:56:20 UTC
Fix included in qemu-kvm-1.5.3-17.el7

Comment 4 Xu Han 2013-11-18 06:51:22 UTC
Reproduce this bug with components:
qemu-kvm-1.5.3-16.el7.x86_64

Steps:
1. boot guest with vfio-pci assigned device using MSI interrupts(82579LM NIC).
/usr/libexec/qemu-kvm -nodefaults -M q35 -m 1G -cpu SandyBridge -smp 4,cores=2,threads=2,sockets=1 -monitor stdio -boot menu=on -rtc base=localtime,clock=host,driftfix=slew -qmp tcp:0:5555,server,nowait -vga qxl -drive file=/home/rhel7base.qcow2,format=qcow2,id=guest-img,if=none,werror=stop,rerror=stop -device virtio-blk-pci,scsi=off,drive=guest-img,id=os-disk -spice disable-ticketing,port=5931 \
-device vfio-pci,host=00:19.0,id=hostnet

2. get IRQ num and affinity of vfio-pci assigned device.
# cat /proc/interrupts | grep ens3
# cat /proc/irq/43/smp_affinity

3. change IRQ affinity of that device.
# echo 2 > /proc/irq/43/smp_affinity

Results:
After step1, check msi information on guest.
# lspci -vvv -s 00:03.0 | grep -i msi
	Capabilities: [d0] MSI: Enable+ Count=1/1 Maskable- 64bit+

After step2
# cat /proc/interrupts | grep ens3
 43:      50821          0          0          0   PCI-MSI-edge      ens3
# cat /proc/irq/43/smp_affinity
4

After step3, interrupted vcpu unchanged.
# cat /proc/irq/43/smp_affinity
4
# cat /proc/interrupts | grep ens3
 43:      51947          0          0          0   PCI-MSI-edge      ens3


Verify this bug with component:
qemu-kvm-1.5.3-19.el7.x86_64

Same steps as above.

Results:
After step2
# cat /proc/interrupts | grep ens3
 43:      43186          0        453          0   PCI-MSI-edge      ens3
# cat /proc/irq/43/smp_affinity
1

After step3, interrupted vcpu tracks user request.
# cat /proc/irq/43/smp_affinity
2
# cat /proc/interrupts | grep ens3
 43:      44167       2881        453          0   PCI-MSI-edge      ens3


Base on these test results above, this bug has been fixed.

Comment 6 Alex Williamson 2013-12-04 16:18:53 UTC
*** Bug 1004373 has been marked as a duplicate of this bug. ***

Comment 7 Ludek Smid 2014-06-13 09:49:42 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


Note You need to log in before you can comment on or make changes to this bug.