diff options
author | Arik Nemtsov <arik@wizery.com> | 2012-06-10 17:09:22 +0300 |
---|---|---|
committer | Luciano Coelho <coelho@ti.com> | 2012-06-21 12:51:41 +0300 |
commit | 66340e5b259bd7ca67cf0ca079dd3997fa198d4b (patch) | |
tree | e11c15268619ba6998b51cebf1496849932d7ddf /drivers/net/wireless/ti/wlcore/init.c | |
parent | 26b5858a67e4316ecd8159e2c0dc5591ef68226a (diff) | |
download | linux-stable-66340e5b259bd7ca67cf0ca079dd3997fa198d4b.tar.gz linux-stable-66340e5b259bd7ca67cf0ca079dd3997fa198d4b.tar.bz2 linux-stable-66340e5b259bd7ca67cf0ca079dd3997fa198d4b.zip |
wlcore: allow setting sleep_auth before interface init
Hold a value for sta_sleep_auth that is amenable to change by debugfs.
When detecting a legal value in this variable on interface init, use it
as an override value for sleep_auth.
This makes debugging more intuitive using the debugfs value.
Increment the conf version since we added an element to the conf
structure.
Note: An AP going up will always set sleep_auth to PSM_CAM.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: Luciano Coelho <coelho@ti.com>
Diffstat (limited to 'drivers/net/wireless/ti/wlcore/init.c')
-rw-r--r-- | drivers/net/wireless/ti/wlcore/init.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/net/wireless/ti/wlcore/init.c b/drivers/net/wireless/ti/wlcore/init.c index 645abd4b660d..3fb9352bf504 100644 --- a/drivers/net/wireless/ti/wlcore/init.c +++ b/drivers/net/wireless/ti/wlcore/init.c @@ -565,7 +565,13 @@ int wl1271_init_vif_specific(struct wl1271 *wl, struct ieee80211_vif *vif) if (ret < 0) return ret; } else if (!wl->sta_count) { - if (wl->quirks & WLCORE_QUIRK_NO_ELP) { + u8 sta_auth = wl->conf.conn.sta_sleep_auth; + if (sta_auth != WL1271_PSM_ILLEGAL) { + /* Configure for power according to debugfs */ + ret = wl1271_acx_sleep_auth(wl, sta_auth); + if (ret < 0) + return ret; + } else if (wl->quirks & WLCORE_QUIRK_NO_ELP) { /* Configure for power always on */ ret = wl1271_acx_sleep_auth(wl, WL1271_PSM_CAM); if (ret < 0) |