0001
0002
0003
0004
0005
0006
0007
0008
0009 #ifndef PM_H_INCLUDED
0010 #define PM_H_INCLUDED
0011
0012
0013
0014
0015 struct cw1200_common;
0016 struct cw1200_suspend_state;
0017
0018 struct cw1200_pm_state {
0019 struct cw1200_suspend_state *suspend_state;
0020 struct timer_list stay_awake;
0021 struct platform_device *pm_dev;
0022 spinlock_t lock;
0023 };
0024
0025 #ifdef CONFIG_PM
0026 int cw1200_pm_init(struct cw1200_pm_state *pm,
0027 struct cw1200_common *priv);
0028 void cw1200_pm_deinit(struct cw1200_pm_state *pm);
0029 int cw1200_wow_suspend(struct ieee80211_hw *hw,
0030 struct cfg80211_wowlan *wowlan);
0031 int cw1200_can_suspend(struct cw1200_common *priv);
0032 int cw1200_wow_resume(struct ieee80211_hw *hw);
0033 void cw1200_pm_stay_awake(struct cw1200_pm_state *pm,
0034 unsigned long tmo);
0035 #else
0036 static inline void cw1200_pm_stay_awake(struct cw1200_pm_state *pm,
0037 unsigned long tmo)
0038 {
0039 }
0040 static inline int cw1200_can_suspend(struct cw1200_common *priv)
0041 {
0042 return 0;
0043 }
0044 #endif
0045 #endif