diff options
author | Eliad Peller <eliad@wizery.com> | 2012-08-16 13:52:47 +0300 |
---|---|---|
committer | Luciano Coelho <luca@coelho.fi> | 2012-09-27 12:13:53 +0300 |
commit | 001e39a8effd5a9774153ca6ca67849a93b95852 (patch) | |
tree | ac108b863deb0a3b6da887bbf31fb97262067ec0 /drivers/net/wireless/ti/wlcore/init.c | |
parent | 4137c17c8c88eca51a9e9d53c5eea0ea3d49940e (diff) | |
download | linux-001e39a8effd5a9774153ca6ca67849a93b95852.tar.bz2 |
wlcore: use dynamic keep-alive template ids
Currently, all the (station) roles use the same
keep-alive template id (0). However, the klv
template ids shouldn't be shared by different
roles.
Implement a simple klv_templates bitmap, and let
each role allocate its own klv template id on
role initialization.
[Arik - remove invalidation of KLV template when getting into "idle".
This is already handled in unjoin]
Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: Luciano Coelho <luca@coelho.fi>
Diffstat (limited to 'drivers/net/wireless/ti/wlcore/init.c')
-rw-r--r-- | drivers/net/wireless/ti/wlcore/init.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/drivers/net/wireless/ti/wlcore/init.c b/drivers/net/wireless/ti/wlcore/init.c index a3c867786df8..32d157f62f31 100644 --- a/drivers/net/wireless/ti/wlcore/init.c +++ b/drivers/net/wireless/ti/wlcore/init.c @@ -141,7 +141,7 @@ int wl1271_init_templates_config(struct wl1271 *wl) if (ret < 0) return ret; - for (i = 0; i < CMD_TEMPL_KLV_IDX_MAX; i++) { + for (i = 0; i < WLCORE_MAX_KLV_TEMPLATES; i++) { ret = wl1271_cmd_template_set(wl, WL12XX_INVALID_ROLE_ID, CMD_TEMPL_KLV, NULL, sizeof(struct ieee80211_qos_hdr), @@ -371,15 +371,7 @@ static int wl1271_sta_hw_init_post_mem(struct wl1271 *wl, struct ieee80211_vif *vif) { struct wl12xx_vif *wlvif = wl12xx_vif_to_data(vif); - int ret, i; - - /* disable all keep-alive templates */ - for (i = 0; i < CMD_TEMPL_KLV_IDX_MAX; i++) { - ret = wl1271_acx_keep_alive_config(wl, wlvif, i, - ACX_KEEP_ALIVE_TPL_INVALID); - if (ret < 0) - return ret; - } + int ret; /* disable the keep-alive feature */ ret = wl1271_acx_keep_alive_mode(wl, wlvif, false); |