aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEliad Peller <eliad@wizery.com>2012-07-03 15:51:20 +0300
committerJohn W. Linville <linville@tuxdriver.com>2012-07-10 12:10:15 -0400
commitfaae5aae2d4d7fe976d6ef62c3c209b8990124ac (patch)
tree78ab217db7c723b0917098ea0871600816aba6cb
parentwl12xx/wl18xx: use a dynamic PS timeout of 1.5sec (diff)
downloadlinux-dev-faae5aae2d4d7fe976d6ef62c3c209b8990124ac.tar.xz
linux-dev-faae5aae2d4d7fe976d6ef62c3c209b8990124ac.zip
wlcore: check ssid length against the correct element
commit 587cc28 ("wlcore: compare ssid_len before comparing ssids") introduced a new bug - the ssid length from the request struct was compared against the ssid length of another request, instead the one of the cmd. This might cause the sched scan request to fail (with -EINVAL) in many cases. Signed-off-by: Eliad Peller <eliad@wizery.com>
-rw-r--r--drivers/net/wireless/ti/wlcore/scan.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/ti/wlcore/scan.c b/drivers/net/wireless/ti/wlcore/scan.c
index b03eb9ae8ebe..dbeca1bfbb2c 100644
--- a/drivers/net/wireless/ti/wlcore/scan.c
+++ b/drivers/net/wireless/ti/wlcore/scan.c
@@ -633,7 +633,7 @@ wl12xx_scan_sched_scan_ssid_list(struct wl1271 *wl,
for (j = 0; j < cmd->n_ssids; j++)
if ((req->ssids[i].ssid_len ==
- req->ssids[j].ssid_len) &&
+ cmd->ssids[j].len) &&
!memcmp(req->ssids[i].ssid,
cmd->ssids[j].ssid,
req->ssids[i].ssid_len)) {