diff options
author | Eliad Peller <eliad@wizery.com> | 2010-10-27 08:09:58 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-11-15 13:25:25 -0500 |
commit | e285a5250c0772c5596a9137041a96b2c1f744d6 (patch) | |
tree | 01ae70dee88e075a10b887e9bba48312dba26f98 /drivers/net | |
parent | ccc83b046c03378bbaf7cf095d8d7e9b9abb24c5 (diff) |
wl1271: add recover testmode command
add RECOVER testmode command.
this command triggers a recovery sequence (by enqueueing a recovery_work).
Signed-off-by: Eliad Peller <eliad@wizery.com>
Reviewed-by: Luciano Coelho <luciano.coelho@nokia.com>
Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wireless/wl12xx/wl1271_testmode.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271_testmode.c b/drivers/net/wireless/wl12xx/wl1271_testmode.c index a3aa84386c88..55ec4428922b 100644 --- a/drivers/net/wireless/wl12xx/wl1271_testmode.c +++ b/drivers/net/wireless/wl12xx/wl1271_testmode.c | |||
@@ -37,6 +37,7 @@ enum wl1271_tm_commands { | |||
37 | WL1271_TM_CMD_CONFIGURE, | 37 | WL1271_TM_CMD_CONFIGURE, |
38 | WL1271_TM_CMD_NVS_PUSH, | 38 | WL1271_TM_CMD_NVS_PUSH, |
39 | WL1271_TM_CMD_SET_PLT_MODE, | 39 | WL1271_TM_CMD_SET_PLT_MODE, |
40 | WL1271_TM_CMD_RECOVER, | ||
40 | 41 | ||
41 | __WL1271_TM_CMD_AFTER_LAST | 42 | __WL1271_TM_CMD_AFTER_LAST |
42 | }; | 43 | }; |
@@ -248,6 +249,15 @@ static int wl1271_tm_cmd_set_plt_mode(struct wl1271 *wl, struct nlattr *tb[]) | |||
248 | return ret; | 249 | return ret; |
249 | } | 250 | } |
250 | 251 | ||
252 | static int wl1271_tm_cmd_recover(struct wl1271 *wl, struct nlattr *tb[]) | ||
253 | { | ||
254 | wl1271_debug(DEBUG_TESTMODE, "testmode cmd recover"); | ||
255 | |||
256 | ieee80211_queue_work(wl->hw, &wl->recovery_work); | ||
257 | |||
258 | return 0; | ||
259 | } | ||
260 | |||
251 | int wl1271_tm_cmd(struct ieee80211_hw *hw, void *data, int len) | 261 | int wl1271_tm_cmd(struct ieee80211_hw *hw, void *data, int len) |
252 | { | 262 | { |
253 | struct wl1271 *wl = hw->priv; | 263 | struct wl1271 *wl = hw->priv; |
@@ -272,6 +282,8 @@ int wl1271_tm_cmd(struct ieee80211_hw *hw, void *data, int len) | |||
272 | return wl1271_tm_cmd_nvs_push(wl, tb); | 282 | return wl1271_tm_cmd_nvs_push(wl, tb); |
273 | case WL1271_TM_CMD_SET_PLT_MODE: | 283 | case WL1271_TM_CMD_SET_PLT_MODE: |
274 | return wl1271_tm_cmd_set_plt_mode(wl, tb); | 284 | return wl1271_tm_cmd_set_plt_mode(wl, tb); |
285 | case WL1271_TM_CMD_RECOVER: | ||
286 | return wl1271_tm_cmd_recover(wl, tb); | ||
275 | default: | 287 | default: |
276 | return -EOPNOTSUPP; | 288 | return -EOPNOTSUPP; |
277 | } | 289 | } |