diff options
author | Henrik Kretzschmar <henne@nachtwindheim.de> | 2006-07-06 10:05:51 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-08-03 16:20:05 -0400 |
commit | 60854838596906ebae7f32e4de921e150e669b60 (patch) | |
tree | c91eb1672fc7d19dea6ab7379b9e555350158e95 /drivers/pci | |
parent | fd60ae404f104f12369e654af9cf03b1f1047661 (diff) |
pcie: fix warnings when CONFIG_PM=n
Signed-off-by: Henrik Kretzschmar <henne@nachtwindheim.de>
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/pcie/portdrv_pci.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/pci/pcie/portdrv_pci.c b/drivers/pci/pcie/portdrv_pci.c index 50bfc1b2f3bf..d0a37976faa6 100644 --- a/drivers/pci/pcie/portdrv_pci.c +++ b/drivers/pci/pcie/portdrv_pci.c | |||
@@ -30,23 +30,6 @@ MODULE_LICENSE("GPL"); | |||
30 | /* global data */ | 30 | /* global data */ |
31 | static const char device_name[] = "pcieport-driver"; | 31 | static const char device_name[] = "pcieport-driver"; |
32 | 32 | ||
33 | static int pcie_portdrv_save_config(struct pci_dev *dev) | ||
34 | { | ||
35 | return pci_save_state(dev); | ||
36 | } | ||
37 | |||
38 | static int pcie_portdrv_restore_config(struct pci_dev *dev) | ||
39 | { | ||
40 | int retval; | ||
41 | |||
42 | pci_restore_state(dev); | ||
43 | retval = pci_enable_device(dev); | ||
44 | if (retval) | ||
45 | return retval; | ||
46 | pci_set_master(dev); | ||
47 | return 0; | ||
48 | } | ||
49 | |||
50 | /* | 33 | /* |
51 | * pcie_portdrv_probe - Probe PCI-Express port devices | 34 | * pcie_portdrv_probe - Probe PCI-Express port devices |
52 | * @dev: PCI-Express port device being probed | 35 | * @dev: PCI-Express port device being probed |
@@ -86,6 +69,23 @@ static void pcie_portdrv_remove (struct pci_dev *dev) | |||
86 | } | 69 | } |
87 | 70 | ||
88 | #ifdef CONFIG_PM | 71 | #ifdef CONFIG_PM |
72 | static int pcie_portdrv_save_config(struct pci_dev *dev) | ||
73 | { | ||
74 | return pci_save_state(dev); | ||
75 | } | ||
76 | |||
77 | static int pcie_portdrv_restore_config(struct pci_dev *dev) | ||
78 | { | ||
79 | int retval; | ||
80 | |||
81 | pci_restore_state(dev); | ||
82 | retval = pci_enable_device(dev); | ||
83 | if (retval) | ||
84 | return retval; | ||
85 | pci_set_master(dev); | ||
86 | return 0; | ||
87 | } | ||
88 | |||
89 | static int pcie_portdrv_suspend (struct pci_dev *dev, pm_message_t state) | 89 | static int pcie_portdrv_suspend (struct pci_dev *dev, pm_message_t state) |
90 | { | 90 | { |
91 | int ret = pcie_port_device_suspend(dev, state); | 91 | int ret = pcie_port_device_suspend(dev, state); |