summaryrefslogtreecommitdiff
path: root/drivers/pci/bus.c
diff options
context:
space:
mode:
authorMatthew Garrett <mjg@redhat.com>2012-12-05 14:33:27 -0700
committerBjorn Helgaas <bhelgaas@google.com>2012-12-05 14:38:26 -0700
commiteca0d4676d8e29c209ddce0c0c1755472ffc70a6 (patch)
tree0455ac26c96f0a383665fe353d28dbeaa3e1f14b /drivers/pci/bus.c
parentdd5fc854de5fd37adfcef8a366cd21a55aa01d3d (diff)
PCI: Add pcibios_add_device
Platforms may want to provide architecture-specific functionality during PCI enumeration. Add a pcibios_add_device() call that architectures can override to do so. Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Tested-by: Seth Forshee <seth.forshee@canonical.com>
Diffstat (limited to 'drivers/pci/bus.c')
-rw-r--r--drivers/pci/bus.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/pci/bus.c b/drivers/pci/bus.c
index 6241fd05bd41..4f22fa16a3ba 100644
--- a/drivers/pci/bus.c
+++ b/drivers/pci/bus.c
@@ -170,6 +170,11 @@ int pci_bus_add_device(struct pci_dev *dev)
int retval;
pci_fixup_device(pci_fixup_final, dev);
+
+ retval = pcibios_add_device(dev);
+ if (retval)
+ return retval;
+
retval = device_add(&dev->dev);
if (retval)
return retval;