From: Po Liu Date: Mon, 29 Aug 2016 07:26:58 +0000 (+0800) Subject: PCI: altera: Relax device number checking to allow SR-IOV X-Git-Tag: Ubuntu-4.10.0-19.21~2461^2~2^2~2 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=d99e30b7936ad2214548e33d8de15584c741bdb4;p=mirror_ubuntu-artful-kernel.git PCI: altera: Relax device number checking to allow SR-IOV Previously we only allowed device 0 to be directly attached to the root port. But SR-IOV devices may use non-zero device numbers for VFs. Remove the restriction that only device 0 may be attached to a root port. [bhelgaas: changelog] Signed-off-by: Po Liu Signed-off-by: Bjorn Helgaas Acked-by: Ley Foon Tan --- diff --git a/drivers/pci/host/pcie-altera.c b/drivers/pci/host/pcie-altera.c index 2b7837650db8..edbe0a7a5699 100644 --- a/drivers/pci/host/pcie-altera.c +++ b/drivers/pci/host/pcie-altera.c @@ -171,13 +171,6 @@ static bool altera_pcie_valid_config(struct altera_pcie *pcie, if (bus->number == pcie->root_bus_nr && dev > 0) return false; - /* - * Do not read more than one device on the bus directly attached - * to root port, root port can only attach to one downstream port. - */ - if (bus->primary == pcie->root_bus_nr && dev > 0) - return false; - return true; }