cfg80211: fix disassociation warning due to misuse of wdev->current_bss
authorPavel Roskin <proski@gnu.org>
Thu, 6 Aug 2009 08:52:42 +0000 (04:52 -0400)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 14 Aug 2009 13:12:45 +0000 (09:12 -0400)
WARN_ON was triggered at mlme.c:213 when dissociating from an AP.

wdev->current_bss->pub.bssid should be used in place of
wdev->current_bss for BSSID comparison.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/wireless/mlme.c

index 525e8e247b30e6f921c76a81314fe2bd9d22f110..b44b6c024c14c7926ea8866f1ff834d03f2280ce 100644 (file)
@@ -198,7 +198,7 @@ static void __cfg80211_send_disassoc(struct net_device *dev,
                return;
 
        if (wdev->current_bss &&
-           memcmp(wdev->current_bss, bssid, ETH_ALEN) == 0) {
+           memcmp(wdev->current_bss->pub.bssid, bssid, ETH_ALEN) == 0) {
                for (i = 0; i < MAX_AUTH_BSSES; i++) {
                        if (wdev->authtry_bsses[i] || wdev->auth_bsses[i])
                                continue;