wl1251: enable beacon early termination while in power-saving mode
[pandora-wifi.git] / drivers / net / wireless / wl12xx / wl1251_ps.c
index b55cb2b..fb33ee1 100644 (file)
@@ -155,6 +155,11 @@ int wl1251_ps_set_mode(struct wl1251 *wl, enum wl1251_cmd_ps_mode mode)
                if (ret < 0)
                        return ret;
 
+               ret = wl1251_acx_bet_enable(wl, WL1251_ACX_BET_ENABLE,
+                                           WL1251_DEFAULT_BET_CONSECUTIVE);
+               if (ret < 0)
+                       return ret;
+
                ret = wl1251_cmd_ps_mode(wl, STATION_POWER_SAVE_MODE);
                if (ret < 0)
                        return ret;
@@ -172,6 +177,12 @@ int wl1251_ps_set_mode(struct wl1251 *wl, enum wl1251_cmd_ps_mode mode)
                if (ret < 0)
                        return ret;
 
+               /* disable BET */
+               ret = wl1251_acx_bet_enable(wl, WL1251_ACX_BET_DISABLE,
+                                           WL1251_DEFAULT_BET_CONSECUTIVE);
+               if (ret < 0)
+                       return ret;
+
                /* disable beacon filtering */
                ret = wl1251_acx_beacon_filter_opt(wl, false);
                if (ret < 0)