diff options
author | Dhananjay Phadke <dhananjay@netxen.com> | 2009-06-22 16:26:20 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-06-23 07:16:42 -0400 |
commit | 01542cd1bbf995f951e2c2383d7911e96b12bec6 (patch) | |
tree | b1d9f130b2a88fa03d706d579e9799f40395849a | |
parent | 4d900f9df5f0569c2dc536701e2c11b6d50ebebf (diff) |
netxen: fix build with without CONFIG_PM
wrap pci suspend() and resume() with CONFIG_PM check.
Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/netxen/netxen_nic_main.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c index 71daa3d5f114..43ac333898bf 100644 --- a/drivers/net/netxen/netxen_nic_main.c +++ b/drivers/net/netxen/netxen_nic_main.c | |||
@@ -1178,6 +1178,7 @@ static void __devexit netxen_nic_remove(struct pci_dev *pdev) | |||
1178 | free_netdev(netdev); | 1178 | free_netdev(netdev); |
1179 | } | 1179 | } |
1180 | 1180 | ||
1181 | #ifdef CONFIG_PM | ||
1181 | static int | 1182 | static int |
1182 | netxen_nic_suspend(struct pci_dev *pdev, pm_message_t state) | 1183 | netxen_nic_suspend(struct pci_dev *pdev, pm_message_t state) |
1183 | { | 1184 | { |
@@ -1242,6 +1243,7 @@ netxen_nic_resume(struct pci_dev *pdev) | |||
1242 | 1243 | ||
1243 | return 0; | 1244 | return 0; |
1244 | } | 1245 | } |
1246 | #endif | ||
1245 | 1247 | ||
1246 | static int netxen_nic_open(struct net_device *netdev) | 1248 | static int netxen_nic_open(struct net_device *netdev) |
1247 | { | 1249 | { |
@@ -1771,8 +1773,10 @@ static struct pci_driver netxen_driver = { | |||
1771 | .id_table = netxen_pci_tbl, | 1773 | .id_table = netxen_pci_tbl, |
1772 | .probe = netxen_nic_probe, | 1774 | .probe = netxen_nic_probe, |
1773 | .remove = __devexit_p(netxen_nic_remove), | 1775 | .remove = __devexit_p(netxen_nic_remove), |
1776 | #ifdef CONFIG_PM | ||
1774 | .suspend = netxen_nic_suspend, | 1777 | .suspend = netxen_nic_suspend, |
1775 | .resume = netxen_nic_resume | 1778 | .resume = netxen_nic_resume |
1779 | #endif | ||
1776 | }; | 1780 | }; |
1777 | 1781 | ||
1778 | /* Driver Registration on NetXen card */ | 1782 | /* Driver Registration on NetXen card */ |