aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/pci/pci-driver.c15
-rw-r--r--drivers/pci/pci-sysfs.c7
-rw-r--r--drivers/pci/pci.h4
-rw-r--r--drivers/pci/probe.c2
-rw-r--r--include/linux/pci.h2
5 files changed, 0 insertions, 30 deletions
diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
index 6c94fc9489e7..8919801cb27e 100644
--- a/drivers/pci/pci-driver.c
+++ b/drivers/pci/pci-driver.c
@@ -89,10 +89,6 @@ static void pci_free_dynids(struct pci_driver *drv)
89 spin_unlock(&drv->dynids.lock); 89 spin_unlock(&drv->dynids.lock);
90} 90}
91 91
92/*
93 * Dynamic device ID manipulation via sysfs is disabled for !CONFIG_HOTPLUG
94 */
95#ifdef CONFIG_HOTPLUG
96/** 92/**
97 * store_new_id - sysfs frontend to pci_add_dynid() 93 * store_new_id - sysfs frontend to pci_add_dynid()
98 * @driver: target device driver 94 * @driver: target device driver
@@ -191,10 +187,6 @@ static struct driver_attribute pci_drv_attrs[] = {
191 __ATTR_NULL, 187 __ATTR_NULL,
192}; 188};
193 189
194#else
195#define pci_drv_attrs NULL
196#endif /* CONFIG_HOTPLUG */
197
198/** 190/**
199 * pci_match_id - See if a pci device matches a given pci_id table 191 * pci_match_id - See if a pci device matches a given pci_id table
200 * @ids: array of PCI device id structures to search in 192 * @ids: array of PCI device id structures to search in
@@ -1223,13 +1215,6 @@ void pci_dev_put(struct pci_dev *dev)
1223 put_device(&dev->dev); 1215 put_device(&dev->dev);
1224} 1216}
1225 1217
1226#ifndef CONFIG_HOTPLUG
1227int pci_uevent(struct device *dev, struct kobj_uevent_env *env)
1228{
1229 return -ENODEV;
1230}
1231#endif
1232
1233struct bus_type pci_bus_type = { 1218struct bus_type pci_bus_type = {
1234 .name = "pci", 1219 .name = "pci",
1235 .match = pci_bus_match, 1220 .match = pci_bus_match,
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index f39378d9da15..68d56f02e721 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -284,7 +284,6 @@ msi_bus_store(struct device *dev, struct device_attribute *attr,
284 return count; 284 return count;
285} 285}
286 286
287#ifdef CONFIG_HOTPLUG
288static DEFINE_MUTEX(pci_remove_rescan_mutex); 287static DEFINE_MUTEX(pci_remove_rescan_mutex);
289static ssize_t bus_rescan_store(struct bus_type *bus, const char *buf, 288static ssize_t bus_rescan_store(struct bus_type *bus, const char *buf,
290 size_t count) 289 size_t count)
@@ -377,8 +376,6 @@ dev_bus_rescan_store(struct device *dev, struct device_attribute *attr,
377 return count; 376 return count;
378} 377}
379 378
380#endif
381
382#if defined(CONFIG_PM_RUNTIME) && defined(CONFIG_ACPI) 379#if defined(CONFIG_PM_RUNTIME) && defined(CONFIG_ACPI)
383static ssize_t d3cold_allowed_store(struct device *dev, 380static ssize_t d3cold_allowed_store(struct device *dev,
384 struct device_attribute *attr, 381 struct device_attribute *attr,
@@ -424,10 +421,8 @@ struct device_attribute pci_dev_attrs[] = {
424 __ATTR(broken_parity_status,(S_IRUGO|S_IWUSR), 421 __ATTR(broken_parity_status,(S_IRUGO|S_IWUSR),
425 broken_parity_status_show,broken_parity_status_store), 422 broken_parity_status_show,broken_parity_status_store),
426 __ATTR(msi_bus, 0644, msi_bus_show, msi_bus_store), 423 __ATTR(msi_bus, 0644, msi_bus_show, msi_bus_store),
427#ifdef CONFIG_HOTPLUG
428 __ATTR(remove, (S_IWUSR|S_IWGRP), NULL, remove_store), 424 __ATTR(remove, (S_IWUSR|S_IWGRP), NULL, remove_store),
429 __ATTR(rescan, (S_IWUSR|S_IWGRP), NULL, dev_rescan_store), 425 __ATTR(rescan, (S_IWUSR|S_IWGRP), NULL, dev_rescan_store),
430#endif
431#if defined(CONFIG_PM_RUNTIME) && defined(CONFIG_ACPI) 426#if defined(CONFIG_PM_RUNTIME) && defined(CONFIG_ACPI)
432 __ATTR(d3cold_allowed, 0644, d3cold_allowed_show, d3cold_allowed_store), 427 __ATTR(d3cold_allowed, 0644, d3cold_allowed_show, d3cold_allowed_store),
433#endif 428#endif
@@ -435,9 +430,7 @@ struct device_attribute pci_dev_attrs[] = {
435}; 430};
436 431
437struct device_attribute pcibus_dev_attrs[] = { 432struct device_attribute pcibus_dev_attrs[] = {
438#ifdef CONFIG_HOTPLUG
439 __ATTR(rescan, (S_IWUSR|S_IWGRP), NULL, dev_bus_rescan_store), 433 __ATTR(rescan, (S_IWUSR|S_IWGRP), NULL, dev_bus_rescan_store),
440#endif
441 __ATTR(cpuaffinity, S_IRUGO, pci_bus_show_cpumaskaffinity, NULL), 434 __ATTR(cpuaffinity, S_IRUGO, pci_bus_show_cpumaskaffinity, NULL),
442 __ATTR(cpulistaffinity, S_IRUGO, pci_bus_show_cpulistaffinity, NULL), 435 __ATTR(cpulistaffinity, S_IRUGO, pci_bus_show_cpulistaffinity, NULL),
443 __ATTR_NULL, 436 __ATTR_NULL,
diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
index fd92aab9904b..6e993af4d30b 100644
--- a/drivers/pci/pci.h
+++ b/drivers/pci/pci.h
@@ -159,11 +159,7 @@ static inline int pci_no_d1d2(struct pci_dev *dev)
159} 159}
160extern struct device_attribute pci_dev_attrs[]; 160extern struct device_attribute pci_dev_attrs[];
161extern struct device_attribute pcibus_dev_attrs[]; 161extern struct device_attribute pcibus_dev_attrs[];
162#ifdef CONFIG_HOTPLUG
163extern struct bus_attribute pci_bus_attrs[]; 162extern struct bus_attribute pci_bus_attrs[];
164#else
165#define pci_bus_attrs NULL
166#endif
167 163
168 164
169/** 165/**
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index ec909afa90b6..034cb1c73092 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -1864,7 +1864,6 @@ struct pci_bus * __devinit pci_scan_bus(int bus, struct pci_ops *ops,
1864} 1864}
1865EXPORT_SYMBOL(pci_scan_bus); 1865EXPORT_SYMBOL(pci_scan_bus);
1866 1866
1867#ifdef CONFIG_HOTPLUG
1868/** 1867/**
1869 * pci_rescan_bus_bridge_resize - scan a PCI bus for devices. 1868 * pci_rescan_bus_bridge_resize - scan a PCI bus for devices.
1870 * @bridge: PCI bridge for the bus to scan 1869 * @bridge: PCI bridge for the bus to scan
@@ -1894,7 +1893,6 @@ EXPORT_SYMBOL(pci_add_new_bus);
1894EXPORT_SYMBOL(pci_scan_slot); 1893EXPORT_SYMBOL(pci_scan_slot);
1895EXPORT_SYMBOL(pci_scan_bridge); 1894EXPORT_SYMBOL(pci_scan_bridge);
1896EXPORT_SYMBOL_GPL(pci_scan_child_bus); 1895EXPORT_SYMBOL_GPL(pci_scan_child_bus);
1897#endif
1898 1896
1899static int __init pci_sort_bf_cmp(const struct device *d_a, const struct device *d_b) 1897static int __init pci_sort_bf_cmp(const struct device *d_a, const struct device *d_b)
1900{ 1898{
diff --git a/include/linux/pci.h b/include/linux/pci.h
index ee2179546c63..699e9a920eca 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -941,10 +941,8 @@ void set_pcie_hotplug_bridge(struct pci_dev *pdev);
941 941
942/* Functions for PCI Hotplug drivers to use */ 942/* Functions for PCI Hotplug drivers to use */
943int pci_bus_find_capability(struct pci_bus *bus, unsigned int devfn, int cap); 943int pci_bus_find_capability(struct pci_bus *bus, unsigned int devfn, int cap);
944#ifdef CONFIG_HOTPLUG
945unsigned int pci_rescan_bus_bridge_resize(struct pci_dev *bridge); 944unsigned int pci_rescan_bus_bridge_resize(struct pci_dev *bridge);
946unsigned int pci_rescan_bus(struct pci_bus *bus); 945unsigned int pci_rescan_bus(struct pci_bus *bus);
947#endif
948 946
949/* Vital product data routines */ 947/* Vital product data routines */
950ssize_t pci_read_vpd(struct pci_dev *dev, loff_t pos, size_t count, void *buf); 948ssize_t pci_read_vpd(struct pci_dev *dev, loff_t pos, size_t count, void *buf);