aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/probe.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci/probe.c')
-rw-r--r--drivers/pci/probe.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 578d15f49e02..7aa71636dd3c 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -949,6 +949,7 @@ EXPORT_SYMBOL(alloc_pci_dev);
949static struct pci_dev *pci_scan_device(struct pci_bus *bus, int devfn) 949static struct pci_dev *pci_scan_device(struct pci_bus *bus, int devfn)
950{ 950{
951 struct pci_dev *dev; 951 struct pci_dev *dev;
952 struct pci_slot *slot;
952 u32 l; 953 u32 l;
953 u8 hdr_type; 954 u8 hdr_type;
954 int delay = 1; 955 int delay = 1;
@@ -997,6 +998,10 @@ static struct pci_dev *pci_scan_device(struct pci_bus *bus, int devfn)
997 dev->error_state = pci_channel_io_normal; 998 dev->error_state = pci_channel_io_normal;
998 set_pcie_port_type(dev); 999 set_pcie_port_type(dev);
999 1000
1001 list_for_each_entry(slot, &bus->slots, list)
1002 if (PCI_SLOT(devfn) == slot->number)
1003 dev->slot = slot;
1004
1000 /* Assume 32-bit PCI; let 64-bit PCI cards (which are far rarer) 1005 /* Assume 32-bit PCI; let 64-bit PCI cards (which are far rarer)
1001 set this higher, assuming the system even supports it. */ 1006 set this higher, assuming the system even supports it. */
1002 dev->dma_mask = 0xffffffff; 1007 dev->dma_mask = 0xffffffff;