aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx/wl1271_testmode.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/wl12xx/wl1271_testmode.c')
-rw-r--r--drivers/net/wireless/wl12xx/wl1271_testmode.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271_testmode.c b/drivers/net/wireless/wl12xx/wl1271_testmode.c
index 6e0952f79e9a..a3aa84386c88 100644
--- a/drivers/net/wireless/wl12xx/wl1271_testmode.c
+++ b/drivers/net/wireless/wl12xx/wl1271_testmode.c
@@ -199,19 +199,6 @@ static int wl1271_tm_cmd_nvs_push(struct wl1271 *wl, struct nlattr *tb[])
199 buf = nla_data(tb[WL1271_TM_ATTR_DATA]); 199 buf = nla_data(tb[WL1271_TM_ATTR_DATA]);
200 len = nla_len(tb[WL1271_TM_ATTR_DATA]); 200 len = nla_len(tb[WL1271_TM_ATTR_DATA]);
201 201
202 /*
203 * FIXME: the LEGACY NVS image support (NVS's missing the 5GHz band
204 * configurations) can be removed when those NVS files stop floating
205 * around.
206 */
207 if (len != sizeof(struct wl1271_nvs_file) &&
208 (len != WL1271_INI_LEGACY_NVS_FILE_SIZE ||
209 wl1271_11a_enabled())) {
210 wl1271_error("nvs size is not as expected: %zu != %zu",
211 len, sizeof(struct wl1271_nvs_file));
212 return -EMSGSIZE;
213 }
214
215 mutex_lock(&wl->mutex); 202 mutex_lock(&wl->mutex);
216 203
217 kfree(wl->nvs); 204 kfree(wl->nvs);
@@ -224,6 +211,7 @@ static int wl1271_tm_cmd_nvs_push(struct wl1271 *wl, struct nlattr *tb[])
224 } 211 }
225 212
226 memcpy(wl->nvs, buf, len); 213 memcpy(wl->nvs, buf, len);
214 wl->nvs_len = len;
227 215
228 wl1271_debug(DEBUG_TESTMODE, "testmode pushed nvs"); 216 wl1271_debug(DEBUG_TESTMODE, "testmode pushed nvs");
229 217