summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEliad Peller <eliad@wizery.com>2013-07-08 23:40:27 +0400
committerEliad Peller <eliad@wizery.com>2013-07-22 14:01:48 +0400
commit335842bf1d8a4b37fb4454cc31753e385ee33a71 (patch)
tree3b7a45d12a1c432d15bc96a8374fbb0f8888e10d
parent4d1c7ac4b280f113bcfe3286eab17ad52a56be9e (diff)
downloadwl18xx-335842bf1d8a4b37fb4454cc31753e385ee33a71.tar.xz
wlcore: save last regdom configuration on stop
In order to reconfigure the correct reg domain on recovery, we have to save the current configuration before clearing it (wl->reg_ch_conf_pending is considered before configuring a new regdomain). Signed-off-by: Eliad Peller <eliad@wizery.com>
-rw-r--r--drivers/net/wireless/ti/wlcore/main.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/wireless/ti/wlcore/main.c b/drivers/net/wireless/ti/wlcore/main.c
index 902f0d08912..2f58436256e 100644
--- a/drivers/net/wireless/ti/wlcore/main.c
+++ b/drivers/net/wireless/ti/wlcore/main.c
@@ -2025,8 +2025,10 @@ static void wlcore_op_stop_locked(struct wl1271 *wl)
/*
* FW channels must be re-calibrated after recovery,
- * clear the last Reg-Domain channel configuration.
+ * save current Reg-Domain channel configuration and clear it.
*/
+ memcpy(wl->reg_ch_conf_pending, wl->reg_ch_conf_last,
+ sizeof(wl->reg_ch_conf_pending));
memset(wl->reg_ch_conf_last, 0, sizeof(wl->reg_ch_conf_last));
}