aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuciano Coelho <coelho@ti.com>2011-05-27 08:34:45 -0400
committerJohn W. Linville <linville@tuxdriver.com>2011-05-31 14:47:24 -0400
commitdd08682150e1815fe5cdd0673a2f2e9cd2d55a7a (patch)
tree3c52564a8c92cb75c0b9fa49a91809412c1bdaeb
parent71005be40a7fc95edda3cc462361ce0243e4f5fa (diff)
wl12xx: fix passive and radar channel generation for scheduled scan
We were comparing bitwise AND results with a boolean, so when the boolean was set to true, it was not matching as it should. Fix this by booleanizing the bitwise AND results with !!. Signed-off-by: Luciano Coelho <coelho@ti.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/wl12xx/scan.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/wl12xx/scan.c b/drivers/net/wireless/wl12xx/scan.c
index f37e5a391976..f223e0ed0c41 100644
--- a/drivers/net/wireless/wl12xx/scan.c
+++ b/drivers/net/wireless/wl12xx/scan.c
@@ -338,8 +338,8 @@ wl1271_scan_get_sched_scan_channels(struct wl1271 *wl,
338 flags = req->channels[i]->flags; 338 flags = req->channels[i]->flags;
339 339
340 if (!(flags & IEEE80211_CHAN_DISABLED) && 340 if (!(flags & IEEE80211_CHAN_DISABLED) &&
341 ((flags & IEEE80211_CHAN_PASSIVE_SCAN) == passive) && 341 (!!(flags & IEEE80211_CHAN_PASSIVE_SCAN) == passive) &&
342 ((flags & IEEE80211_CHAN_RADAR) == radar) && 342 (!!(flags & IEEE80211_CHAN_RADAR) == radar) &&
343 (req->channels[i]->band == band)) { 343 (req->channels[i]->band == band)) {
344 wl1271_debug(DEBUG_SCAN, "band %d, center_freq %d ", 344 wl1271_debug(DEBUG_SCAN, "band %d, center_freq %d ",
345 req->channels[i]->band, 345 req->channels[i]->band,