Return-path: Received: from wolverine01.qualcomm.com ([199.106.114.254]:62921 "EHLO wolverine01.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754657Ab1LGLXb (ORCPT ); Wed, 7 Dec 2011 06:23:31 -0500 Cc: Jouni Malinen , , Rodriguez Luis , Balasubramanian senthilkumar , Vasanthakumar Thiagarajan , Rajkumar Manoharan , Vivek Natarajan , , Mohammed Shafi Shajakhan From: Mohammed Shafi Shajakhan To: "John W. Linville" Subject: [PATCH 1/2] ath9k: validate for non-zero BSSID Date: Wed, 7 Dec 2011 16:51:38 +0530 Message-ID: <1323256899-16453-1-git-send-email-mohammed@qca.qualcomm.com> (sfid-20111207_122336_510050_F66057EC) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-wireless-owner@vger.kernel.org List-ID: From: Mohammed Shafi Shajakhan before concluding that the recieved beacon is for us, let us make sure that the BSSID is non-zero. when I configured ad-hoc mode as creator and left it for some time without joining I found we recieved few frames whose BSSID is zero, which we concluded wrongly as 'my_beacons' Signed-off-by: Mohammed Shafi Shajakhan --- drivers/net/wireless/ath/ath9k/recv.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c index e031841..ad5176d 100644 --- a/drivers/net/wireless/ath/ath9k/recv.c +++ b/drivers/net/wireless/ath/ath9k/recv.c @@ -1823,6 +1823,7 @@ int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp) hdr = (struct ieee80211_hdr *) (hdr_skb->data + rx_status_len); rxs = IEEE80211_SKB_RXCB(hdr_skb); if (ieee80211_is_beacon(hdr->frame_control) && + !is_zero_ether_addr(common->curbssid) && !compare_ether_addr(hdr->addr3, common->curbssid)) rs.is_mybeacon = true; else -- 1.7.0.4