]> git.ipfire.org Git - thirdparty/qemu.git/commit
pci-assign: Enable MSIX on device to match guest
authorAlex Williamson <alex.williamson@redhat.com>
Mon, 7 Jan 2013 04:30:31 +0000 (21:30 -0700)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Wed, 16 Jan 2013 05:05:44 +0000 (23:05 -0600)
commit006c747440b1b22aa5bbef89442ef037741adabc
tree4a6d68c42a05d16a74309649ec0a8d8412d64e96
parentf042cca009607d4571cbe87323967535fe63daf7
pci-assign: Enable MSIX on device to match guest

When a guest enables MSIX on a device we evaluate the MSIX vector
table, typically find no unmasked vectors and don't switch the device
to MSIX mode.  This generally works fine and the device will be
switched once the guest enables and therefore unmasks a vector.
Unfortunately some drivers enable MSIX, then use interfaces to send
commands between VF & PF or PF & firmware that act based on the host
state of the device.  These therefore may break when MSIX is managed
lazily.  This change re-enables the previous test used to enable MSIX
(see qemu-kvm a6b402c9), which basically guesses whether a vector
will be used based on the data field of the vector table.

Cc: qemu-stable@nongnu.org
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
(cherry picked from commit feb9a2ab4b0260d8d680a7ffd25063dafc7ec628)

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
hw/kvm/pci-assign.c