Re: [REGRESSION, bisect]vfio-pci: 'Masking broken INTx support' seen while assigning SRIOV-VF devices after commit 2170dd04316e0754("vfio-pci: Mask INTx if a device is not capabable of enabling it")

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

 



On 06/03/18 17:05, Arjun Vynipadath wrote:
> Hi Alexey,
> Commit 2170dd0("vfio-pci: Mask INTx if a device is not capabable of enabling it") is causing 'Masking broken INTx support' messages everytime we powerup a VM with a SRIOV Virtual Function device attached. 
> 
> PCI SRIOV Virtual Functions aren't allowed to support traditional INTx Pin Interrupts as per Section 5 of the Single Root I/O Virtualization and Sharing Specification, Revision 1.0 (September 11, 2007).
> Can you make us sure if this is what you intended?

The PCI device does not support INTx, VFIO detects it and masks the
support, all correct. VFIO does not make distinction between PF and VF,
hence no special handling for SRIOV. If the message is the only problem, we
could do something like this, I am not sure there is much value in it though:


diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
index b0f7594..b181ca6 100644
--- a/drivers/vfio/pci/vfio_pci.c
+++ b/drivers/vfio/pci/vfio_pci.c
@@ -245,7 +245,13 @@ static int vfio_pci_enable(struct vfio_pci_device *vdev)

        if (likely(!nointxmask)) {
                if (vfio_pci_nointx(pdev)) {
-                       dev_info(&pdev->dev, "Masking broken INTx support\n");
+                       u8 pin = 0;
+
+                       pci_read_config_byte(vdev->pdev, PCI_INTERRUPT_PIN,
+                                            &pin);
+                       if (pin)
+                               dev_info(&pdev->dev,
+                                        "Masking broken INTx support\n");
                        vdev->nointx = true;
                        pci_intx(pdev, 0);



-- 
Alexey



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux