aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/pcie
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2006-12-03 23:59:07 -0500
committerPaul Mackerras <paulus@samba.org>2006-12-03 23:59:07 -0500
commit79acbb3ff2d8095b692e1502b9eb2ccec348de26 (patch)
tree6ab773e5a8f9de2cd6443362b21d0d6fffe3b35e /drivers/pci/pcie
parent19a79859e168640f8e16d7b216d211c1c52b687a (diff)
parent2b5f6dcce5bf94b9b119e9ed8d537098ec61c3d2 (diff)
Merge branch 'linux-2.6' into for-linus
Diffstat (limited to 'drivers/pci/pcie')
-rw-r--r--drivers/pci/pcie/portdrv.h4
-rw-r--r--drivers/pci/pcie/portdrv_core.c3
-rw-r--r--drivers/pci/pcie/portdrv_pci.c2
3 files changed, 5 insertions, 4 deletions
diff --git a/drivers/pci/pcie/portdrv.h b/drivers/pci/pcie/portdrv.h
index 67fcd176babd..3656e0349dd1 100644
--- a/drivers/pci/pcie/portdrv.h
+++ b/drivers/pci/pcie/portdrv.h
@@ -9,6 +9,8 @@
9#ifndef _PORTDRV_H_ 9#ifndef _PORTDRV_H_
10#define _PORTDRV_H_ 10#define _PORTDRV_H_
11 11
12#include <linux/compiler.h>
13
12#if !defined(PCI_CAP_ID_PME) 14#if !defined(PCI_CAP_ID_PME)
13#define PCI_CAP_ID_PME 1 15#define PCI_CAP_ID_PME 1
14#endif 16#endif
@@ -39,7 +41,7 @@ extern int pcie_port_device_suspend(struct pci_dev *dev, pm_message_t state);
39extern int pcie_port_device_resume(struct pci_dev *dev); 41extern int pcie_port_device_resume(struct pci_dev *dev);
40#endif 42#endif
41extern void pcie_port_device_remove(struct pci_dev *dev); 43extern void pcie_port_device_remove(struct pci_dev *dev);
42extern int pcie_port_bus_register(void); 44extern int __must_check pcie_port_bus_register(void);
43extern void pcie_port_bus_unregister(void); 45extern void pcie_port_bus_unregister(void);
44 46
45#endif /* _PORTDRV_H_ */ 47#endif /* _PORTDRV_H_ */
diff --git a/drivers/pci/pcie/portdrv_core.c b/drivers/pci/pcie/portdrv_core.c
index bd6615b4d40e..b20a9b81dae2 100644
--- a/drivers/pci/pcie/portdrv_core.c
+++ b/drivers/pci/pcie/portdrv_core.c
@@ -6,7 +6,6 @@
6 * Copyright (C) Tom Long Nguyen (tom.l.nguyen@intel.com) 6 * Copyright (C) Tom Long Nguyen (tom.l.nguyen@intel.com)
7 */ 7 */
8 8
9#include <linux/compiler.h>
10#include <linux/module.h> 9#include <linux/module.h>
11#include <linux/pci.h> 10#include <linux/pci.h>
12#include <linux/kernel.h> 11#include <linux/kernel.h>
@@ -401,7 +400,7 @@ void pcie_port_device_remove(struct pci_dev *dev)
401 pci_disable_msi(dev); 400 pci_disable_msi(dev);
402} 401}
403 402
404int __must_check pcie_port_bus_register(void) 403int pcie_port_bus_register(void)
405{ 404{
406 return bus_register(&pcie_port_bus_type); 405 return bus_register(&pcie_port_bus_type);
407} 406}
diff --git a/drivers/pci/pcie/portdrv_pci.c b/drivers/pci/pcie/portdrv_pci.c
index 037690e08f5f..b4da7954611e 100644
--- a/drivers/pci/pcie/portdrv_pci.c
+++ b/drivers/pci/pcie/portdrv_pci.c
@@ -37,7 +37,6 @@ static int pcie_portdrv_save_config(struct pci_dev *dev)
37 return pci_save_state(dev); 37 return pci_save_state(dev);
38} 38}
39 39
40#ifdef CONFIG_PM
41static int pcie_portdrv_restore_config(struct pci_dev *dev) 40static int pcie_portdrv_restore_config(struct pci_dev *dev)
42{ 41{
43 int retval; 42 int retval;
@@ -50,6 +49,7 @@ static int pcie_portdrv_restore_config(struct pci_dev *dev)
50 return 0; 49 return 0;
51} 50}
52 51
52#ifdef CONFIG_PM
53static int pcie_portdrv_suspend(struct pci_dev *dev, pm_message_t state) 53static int pcie_portdrv_suspend(struct pci_dev *dev, pm_message_t state)
54{ 54{
55 int ret = pcie_port_device_suspend(dev, state); 55 int ret = pcie_port_device_suspend(dev, state);