diff options
-rw-r--r-- | drivers/pci/Makefile | 3 | ||||
-rw-r--r-- | drivers/pci/hotplug-pci.c | 20 | ||||
-rw-r--r-- | drivers/pci/probe.c | 15 |
3 files changed, 23 insertions, 15 deletions
diff --git a/drivers/pci/Makefile b/drivers/pci/Makefile index f697f3d728eb..9f04d17576d6 100644 --- a/drivers/pci/Makefile +++ b/drivers/pci/Makefile | |||
@@ -13,6 +13,9 @@ obj-$(CONFIG_HOTPLUG) += hotplug.o | |||
13 | 13 | ||
14 | # Build the PCI Hotplug drivers if we were asked to | 14 | # Build the PCI Hotplug drivers if we were asked to |
15 | obj-$(CONFIG_HOTPLUG_PCI) += hotplug/ | 15 | obj-$(CONFIG_HOTPLUG_PCI) += hotplug/ |
16 | ifdef CONFIG_HOTPLUG_PCI | ||
17 | obj-y += hotplug-pci.o | ||
18 | endif | ||
16 | 19 | ||
17 | # Build the PCI MSI interrupt support | 20 | # Build the PCI MSI interrupt support |
18 | obj-$(CONFIG_PCI_MSI) += msi.o | 21 | obj-$(CONFIG_PCI_MSI) += msi.o |
diff --git a/drivers/pci/hotplug-pci.c b/drivers/pci/hotplug-pci.c new file mode 100644 index 000000000000..a590ef682153 --- /dev/null +++ b/drivers/pci/hotplug-pci.c | |||
@@ -0,0 +1,20 @@ | |||
1 | /* Core PCI functionality used only by PCI hotplug */ | ||
2 | |||
3 | #include <linux/pci.h> | ||
4 | #include "pci.h" | ||
5 | |||
6 | |||
7 | unsigned int pci_do_scan_bus(struct pci_bus *bus) | ||
8 | { | ||
9 | unsigned int max; | ||
10 | |||
11 | max = pci_scan_child_bus(bus); | ||
12 | |||
13 | /* | ||
14 | * Make the discovered devices available. | ||
15 | */ | ||
16 | pci_bus_add_devices(bus); | ||
17 | |||
18 | return max; | ||
19 | } | ||
20 | EXPORT_SYMBOL(pci_do_scan_bus); | ||
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 34fa0397b55d..3bb2bc2a1e70 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c | |||
@@ -1040,20 +1040,6 @@ unsigned int pci_scan_child_bus(struct pci_bus *bus) | |||
1040 | return max; | 1040 | return max; |
1041 | } | 1041 | } |
1042 | 1042 | ||
1043 | unsigned int __devinit pci_do_scan_bus(struct pci_bus *bus) | ||
1044 | { | ||
1045 | unsigned int max; | ||
1046 | |||
1047 | max = pci_scan_child_bus(bus); | ||
1048 | |||
1049 | /* | ||
1050 | * Make the discovered devices available. | ||
1051 | */ | ||
1052 | pci_bus_add_devices(bus); | ||
1053 | |||
1054 | return max; | ||
1055 | } | ||
1056 | |||
1057 | struct pci_bus * pci_create_bus(struct device *parent, | 1043 | struct pci_bus * pci_create_bus(struct device *parent, |
1058 | int bus, struct pci_ops *ops, void *sysdata) | 1044 | int bus, struct pci_ops *ops, void *sysdata) |
1059 | { | 1045 | { |
@@ -1140,7 +1126,6 @@ EXPORT_SYMBOL(pci_scan_bus_parented); | |||
1140 | 1126 | ||
1141 | #ifdef CONFIG_HOTPLUG | 1127 | #ifdef CONFIG_HOTPLUG |
1142 | EXPORT_SYMBOL(pci_add_new_bus); | 1128 | EXPORT_SYMBOL(pci_add_new_bus); |
1143 | EXPORT_SYMBOL(pci_do_scan_bus); | ||
1144 | EXPORT_SYMBOL(pci_scan_slot); | 1129 | EXPORT_SYMBOL(pci_scan_slot); |
1145 | EXPORT_SYMBOL(pci_scan_bridge); | 1130 | EXPORT_SYMBOL(pci_scan_bridge); |
1146 | EXPORT_SYMBOL_GPL(pci_scan_child_bus); | 1131 | EXPORT_SYMBOL_GPL(pci_scan_child_bus); |