aboutsummaryrefslogtreecommitdiff
path: root/hw/vfio
diff options
context:
space:
mode:
authorAlex Williamson <alex.williamson@redhat.com>2019-06-13 09:57:36 -0600
committerAlex Williamson <alex.williamson@redhat.com>2019-06-13 09:57:36 -0600
commitc60807dea5930a402b77172da17e79b26f1af48b (patch)
tree4c3eedfac27edab6cbea2c1ff0fb078adb1cf783 /hw/vfio
parent3412d8ec9810b819f8b79e8e0c6b87217c876e32 (diff)
downloadqemu-c60807dea5930a402b77172da17e79b26f1af48b.zip
qemu-c60807dea5930a402b77172da17e79b26f1af48b.tar.gz
qemu-c60807dea5930a402b77172da17e79b26f1af48b.tar.bz2
vfio/pci: Allow MSI-X relocation to fixup bogus PBA
The MSI-X relocation code can sometimes be used to work around bogus MSI-X capabilities, but this test for whether the PBA is outside of the specified BAR causes the device to error before we can apply a relocation. Let it proceed if we intend to relocate MSI-X anyway. Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Diffstat (limited to 'hw/vfio')
-rw-r--r--hw/vfio/pci.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/vfio/pci.c b/hw/vfio/pci.c
index 48f4e19..6520c05 100644
--- a/hw/vfio/pci.c
+++ b/hw/vfio/pci.c
@@ -1533,7 +1533,7 @@ static void vfio_msix_early_setup(VFIOPCIDevice *vdev, Error **errp)
if (vdev->vendor_id == PCI_VENDOR_ID_CHELSIO &&
(vdev->device_id & 0xff00) == 0x5800) {
msix->pba_offset = 0x1000;
- } else {
+ } else if (vdev->msix_relo == OFF_AUTOPCIBAR_OFF) {
error_setg(errp, "hardware reports invalid configuration, "
"MSIX PBA outside of specified BAR");
g_free(msix);