Mellanox ConnectX-3 and vfio

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

When I tried to assign a ConnectX-3 HCA to Qemu using vfio, the
following error message appeared in the kernel log:

[ 2238.319227] genirq: Flags mismatch irq 16. 00000000
(vfio-intx(0000:01:00.0)) vs. 00000080 (ehci_hcd:usb1)

>From linux/interrupt.h:

	#define IRQF_SHARED		0x00000080

In vfio_pci.c I found the following:

	vdev->pci_2_3 = pci_intx_mask_supported(pdev);

and in drivers/pci/quirks.c I found the following:

static u16 mellanox_broken_intx_devs[] = {
	PCI_DEVICE_ID_MELLANOX_HERMON_SDR,
	PCI_DEVICE_ID_MELLANOX_HERMON_DDR,
	PCI_DEVICE_ID_MELLANOX_HERMON_QDR,
	PCI_DEVICE_ID_MELLANOX_HERMON_DDR_GEN2,
	PCI_DEVICE_ID_MELLANOX_HERMON_QDR_GEN2,
	PCI_DEVICE_ID_MELLANOX_HERMON_EN,
	PCI_DEVICE_ID_MELLANOX_HERMON_EN_GEN2,
	PCI_DEVICE_ID_MELLANOX_CONNECTX_EN,
	PCI_DEVICE_ID_MELLANOX_CONNECTX_EN_T_GEN2,
	PCI_DEVICE_ID_MELLANOX_CONNECTX_EN_GEN2,
	PCI_DEVICE_ID_MELLANOX_CONNECTX_EN_5_GEN2,
	PCI_DEVICE_ID_MELLANOX_CONNECTX2,
	PCI_DEVICE_ID_MELLANOX_CONNECTX3,
	PCI_DEVICE_ID_MELLANOX_CONNECTX3_PRO,
};

static void mellanox_check_broken_intx_masking(struct pci_dev *pdev)
{
	__be32 __iomem *fw_ver;
	u16 fw_major;
	u16 fw_minor;
	u16 fw_subminor;
	u32 fw_maj_min;
	u32 fw_sub_min;
	int i;

	for (i = 0; i < ARRAY_SIZE(mellanox_broken_intx_devs); i++) {
		if (pdev->device == mellanox_broken_intx_devs[i]) {
			pdev->broken_intx_masking = 1;
			return;
		}
	}
	[ ... ]
}

I think that code was added by commit d76d2fe05fd9 ("PCI: Convert
Mellanox broken INTx quirks to be for listed devices only").

Does anyone know whether the mellanox_broken_intx_devs[] table is
up-to-date? I'm using a ConnectX-3 VPI adapter and have installed the
latest firmware:

# mstflint -d 01:00.0 q
Image type:            FS2
FW Version:            2.42.5000
FW Release Date:       5.9.2017
Product Version:       02.42.50.00
Rom Info:              type=PXE version=3.4.752
Device ID:             4099
Description:           Node             Port1            Port2
 Sys image
GUIDs:                 [ ... ]
MACs:                  [ ... ]
VSD:
PSID:                  MT_1090120019

Thanks,

Bart.



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux