summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx/wl1251_ps.c
diff options
context:
space:
mode:
authorKalle Valo <kalle.valo@nokia.com>2009-08-07 13:34:56 +0300
committerJohn W. Linville <linville@tuxdriver.com>2009-08-14 09:13:41 -0400
commit4a8189227fc4718a767ffca74d13a7d552e42189 (patch)
tree3d9a110ac6b8cb1f522cbf6038ed23c6ef969665 /drivers/net/wireless/wl12xx/wl1251_ps.c
parentfe9a98460b6c8dac47d0e34bcb04850193d41565 (diff)
wl1251: move wl1251_acx_wake_up_conditions() to wl1251_ps_set_mode()
It should not be hidden inside wl1251_cmd_ps_mode(). Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Reviewed-by: Vidhya Govindan <vidhya.govindan@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx/wl1251_ps.c')
-rw-r--r--drivers/net/wireless/wl12xx/wl1251_ps.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251_ps.c b/drivers/net/wireless/wl12xx/wl1251_ps.c
index 05816778f3d..36acde0b3bd 100644
--- a/drivers/net/wireless/wl12xx/wl1251_ps.c
+++ b/drivers/net/wireless/wl12xx/wl1251_ps.c
@@ -118,6 +118,13 @@ int wl1251_ps_set_mode(struct wl1251 *wl, enum wl1251_cmd_ps_mode mode)
switch (mode) {
case STATION_POWER_SAVE_MODE:
wl1251_debug(DEBUG_PSM, "entering psm");
+
+ ret = wl1251_acx_wake_up_conditions(wl,
+ WAKE_UP_EVENT_DTIM_BITMAP,
+ wl->listen_int);
+ if (ret < 0)
+ return ret;
+
ret = wl1251_cmd_ps_mode(wl, STATION_POWER_SAVE_MODE);
if (ret < 0)
return ret;
@@ -135,6 +142,12 @@ int wl1251_ps_set_mode(struct wl1251 *wl, enum wl1251_cmd_ps_mode mode)
if (ret < 0)
return ret;
+ ret = wl1251_acx_wake_up_conditions(wl,
+ WAKE_UP_EVENT_DTIM_BITMAP,
+ wl->listen_int);
+ if (ret < 0)
+ return ret;
+
ret = wl1251_cmd_ps_mode(wl, STATION_ACTIVE_MODE);
if (ret < 0)
return ret;