linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Architectural question regarding IOV support in Linux 3.13.4
@ 2014-02-21 17:45 Zytaruk, Kelly
  2014-02-21 21:11 ` Bjorn Helgaas
  0 siblings, 1 reply; 12+ messages in thread
From: Zytaruk, Kelly @ 2014-02-21 17:45 UTC (permalink / raw)
  To: linux-pci@vger.kernel.org; +Cc: bhelgaas@google.com


I am working with SR-IOV and I have a question regarding the function
sriov_init() in ../drivers/pci/iov.c (linux versions 3.4.9 and 3.13.4)

In sriov_init() the code first checks whether the PF is a Root complex 
 endpoint (0x9) or an Express Endpoint (0x0) as shown in the code 
 snippet below.  If it is neither it returns the No device error.

static int sriov_init(struct pci_dev *dev, int pos)
{
         int i;
         int rc;
         int nres;
         u32 pgsz;
         u16 ctrl, total, offset, stride;
         struct pci_sriov *iov;
         struct resource *res;
         struct pci_dev *pdev;

       if (pci_pcie_type(dev) != PCI_EXP_TYPE_RC_END &&
             pci_pcie_type(dev) != PCI_EXP_TYPE_ENDPOINT)
                 return -ENODEV;

My question is why PCI_EXP_TYPE_LEG_END (0x1) is omitted as being a 
 valid endpoint.  By excluding Legacy endpoints it fails enabling 
 SR-IOV on a VGA PF.

Is there a design/specification reason why legacy was excluded or was 
 it just an assumption that VGA would never support SR-IOV?

If there is no valid reason to exclude PCI_EXP_TYPE_LEG_END, I would 
 like to discuss having it included as a valid endpoint for SR-IOV.

Thanks,
Kelly



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2014-12-02 21:26 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-21 17:45 Architectural question regarding IOV support in Linux 3.13.4 Zytaruk, Kelly
2014-02-21 21:11 ` Bjorn Helgaas
2014-02-21 22:03   ` Alex Williamson
     [not found]     ` <CAOUHufai=eoR+tgVB5Zdp6veCQgY=pHDSAESZ5cLOjPTw-R8CQ@mail.gmail.com>
2014-02-24 19:22       ` Zytaruk, Kelly
2014-02-24 20:51         ` Bjorn Helgaas
2014-02-24 21:08           ` Zytaruk, Kelly
2014-12-02 16:42           ` Zytaruk, Kelly
2014-12-02 21:01             ` Bjorn Helgaas
2014-12-02 21:11               ` Zytaruk, Kelly
2014-12-02 21:26                 ` Bjorn Helgaas
2014-02-24 20:59         ` Alex Williamson
2014-02-24 21:57           ` Yu Zhao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).