/*
--- a/drivers/net/wireless/ath/ath9k/pci.c
+++ b/drivers/net/wireless/ath/ath9k/pci.c
-@@ -316,14 +316,11 @@ static int ath_pci_resume(struct device
+@@ -316,14 +316,10 @@ static int ath_pci_resume(struct device
return 0;
}
- .poweroff = ath_pci_suspend,
- .restore = ath_pci_resume,
-};
-+
+compat_pci_suspend(ath_pci_suspend)
+compat_pci_resume(ath_pci_resume)
+
#define ATH9K_PM_OPS (&ath9k_pm_ops)
-@@ -341,7 +338,12 @@ static struct pci_driver ath_pci_driver
+@@ -341,7 +337,12 @@ static struct pci_driver ath_pci_driver
.id_table = ath_pci_id_table,
.probe = ath_pci_probe,
.remove = ath_pci_remove,
};
static int __init iwl4965_init(void)
---- a/drivers/net/wireless/iwlwifi/iwl-agn.c
-+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
-@@ -4001,7 +4001,12 @@ static struct pci_driver iwl_driver = {
- .id_table = iwl_hw_card_ids,
- .probe = iwl_pci_probe,
- .remove = __devexit_p(iwl_pci_remove),
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29))
- .driver.pm = IWL_PM_OPS,
-+#elif defined(CONFIG_PM)
-+ .suspend = iwl_pci_suspend_compat,
-+ .resume = iwl_pci_resume_compat,
-+#endif
- };
-
- static int __init iwl_init(void)
---- a/drivers/net/wireless/iwlwifi/iwl-core.c
-+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
-@@ -2014,13 +2014,9 @@ int iwl_pci_resume(struct device *device
- return 0;
+--- a/drivers/net/wireless/iwlwifi/iwl-pci.c
++++ b/drivers/net/wireless/iwlwifi/iwl-pci.c
+@@ -530,14 +530,10 @@ static int iwl_pci_resume(struct device
+ return iwl_resume(priv);
}
--const struct dev_pm_ops iwl_pm_ops = {
+-static const struct dev_pm_ops iwl_dev_pm_ops = {
- .suspend = iwl_pci_suspend,
- .resume = iwl_pci_resume,
- .freeze = iwl_pci_suspend,
- .poweroff = iwl_pci_suspend,
- .restore = iwl_pci_resume,
-};
-+const SIMPLE_DEV_PM_OPS(iwl_pm_ops, iwl_pci_suspend, iwl_pci_resume);
++const SIMPLE_DEV_PM_OPS(iwl_dev_pm_ops, iwl_pci_suspend, iwl_pci_resume);
+
+compat_pci_suspend(iwl_pci_suspend)
+compat_pci_resume(iwl_pci_resume)
- #endif /* CONFIG_PM */
---- a/drivers/net/wireless/iwlwifi/iwl-core.h
-+++ b/drivers/net/wireless/iwlwifi/iwl-core.h
-@@ -502,7 +502,12 @@ __le32 iwl_add_beacon_time(struct iwl_pr
- #ifdef CONFIG_PM
- int iwl_pci_suspend(struct device *device);
- int iwl_pci_resume(struct device *device);
-+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29))
-+int iwl_pci_suspend_compat(struct pci_dev *pdev, pm_message_t state);
-+int iwl_pci_resume_compat(struct pci_dev *pdev);
-+#else
- extern const struct dev_pm_ops iwl_pm_ops;
-+#endif
+ #define IWL_PM_OPS (&iwl_dev_pm_ops)
- #define IWL_PM_OPS (&iwl_pm_ops)
+@@ -552,7 +548,12 @@ static struct pci_driver iwl_pci_driver
+ .id_table = iwl_hw_card_ids,
+ .probe = iwl_pci_probe,
+ .remove = __devexit_p(iwl_pci_remove),
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29))
+ .driver.pm = IWL_PM_OPS,
++#elif defined(CONFIG_PM)
++ .suspend = iwl_pci_suspend_compat,
++ .resume = iwl_pci_resume_compat,
++#endif
+ };
+ int __must_check iwl_pci_register_driver(void)