summaryrefslogtreecommitdiffstats
path: root/drivers/pci/pci.c
diff options
context:
space:
mode:
authorBjorn Helgaas2014-02-26 19:26:00 +0100
committerBjorn Helgaas2014-03-19 22:00:14 +0100
commit8a9d56097c142d0716234eb1cf7c8150c6dc1588 (patch)
tree9fccf9a701102d04d5fd02b2d3ca8b3d677edbab /drivers/pci/pci.c
parentPCI: Don't enable decoding if BAR hasn't been assigned an address (diff)
downloadkernel-qcow2-linux-8a9d56097c142d0716234eb1cf7c8150c6dc1588.tar.gz
kernel-qcow2-linux-8a9d56097c142d0716234eb1cf7c8150c6dc1588.tar.xz
kernel-qcow2-linux-8a9d56097c142d0716234eb1cf7c8150c6dc1588.zip
PCI: Add "weak" generic pcibios_enable_device() implementation
Many architectures implement pcibios_enable_device() the same way, so provide a default implementation in the core. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/pci.c')
-rw-r--r--drivers/pci/pci.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index dc9ce62be7aa..c3ce3d61091c 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -1185,6 +1185,11 @@ int pci_load_and_free_saved_state(struct pci_dev *dev,
}
EXPORT_SYMBOL_GPL(pci_load_and_free_saved_state);
+int __weak pcibios_enable_device(struct pci_dev *dev, int bars)
+{
+ return pci_enable_resources(dev, bars);
+}
+
static int do_pci_enable_device(struct pci_dev *dev, int bars)
{
int err;