[Madwifi-cvs] revision 1929 committed
Status: Beta
Brought to you by:
otaku
From: Pavel R. <svn...@ma...> - 2007-01-11 23:57:13
|
Project : madwifi Revision : 1929 Author : proski (Pavel Roskin) Date : 2007-01-12 00:57:09 +0100 (Fri, 12 Jan 2007) Log Message : Fix warnings in suspend/resume Affected Files: * branches/madwifi-old-openhal/ath/if_ath_pci.c updated * branches/madwifi-old-openhal/ath/if_ath_pci.h updated Modified: branches/madwifi-old-openhal/ath/if_ath_pci.c =================================================================== --- branches/madwifi-old-openhal/ath/if_ath_pci.c 2007-01-11 23:44:04 UTC (rev 1928) +++ branches/madwifi-old-openhal/ath/if_ath_pci.c 2007-01-11 23:57:09 UTC (rev 1929) @@ -255,7 +255,7 @@ #ifdef CONFIG_PM static int -ath_pci_suspend(struct pci_dev *pdev, u32 state) +ath_pci_suspend(struct pci_dev *pdev, pm_message_t state) { struct net_device *dev = pci_get_drvdata(pdev); @@ -273,8 +273,12 @@ { struct net_device *dev = pci_get_drvdata(pdev); u32 val; + int err; - pci_enable_device(pdev); + err = pci_enable_device(pdev); + if (err) + return err; + PCI_RESTORE_STATE(pdev, ((struct ath_pci_softc *)dev->priv)->aps_pmstate); /* Modified: branches/madwifi-old-openhal/ath/if_ath_pci.h =================================================================== --- branches/madwifi-old-openhal/ath/if_ath_pci.h 2007-01-11 23:44:04 UTC (rev 1928) +++ branches/madwifi-old-openhal/ath/if_ath_pci.h 2007-01-11 23:57:09 UTC (rev 1929) @@ -60,4 +60,8 @@ #define BUS_DMA_FROMDEVICE PCI_DMA_FROMDEVICE #define BUS_DMA_TODEVICE PCI_DMA_TODEVICE +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,11) +#define pm_message_t u32 +#endif + #endif /* _DEV_ATH_PCI_H_ */ |