From owner-svn-src-head@freebsd.org Wed Nov 25 18:24:50 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D71F1A3764A; Wed, 25 Nov 2015 18:24:50 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 89B691081; Wed, 25 Nov 2015 18:24:50 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id tAPIOntv079843; Wed, 25 Nov 2015 18:24:49 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id tAPIOnn2079842; Wed, 25 Nov 2015 18:24:49 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201511251824.tAPIOnn2079842@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Wed, 25 Nov 2015 18:24:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r291304 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Nov 2015 18:24:50 -0000 Author: adrian Date: Wed Nov 25 18:24:49 2015 New Revision: 291304 URL: https://svnweb.freebsd.org/changeset/base/291304 Log: [ath] listen to all beacons in IBSS and software beacon miss. I added MYBEACON support a while ago to listen to beacons that are only for your configured BSSID. For AR9380 and later NICs this results in a lot less chip wakeups in station mode as it then only shows you beacons that are destined to you. However in IBSS mode you really do want to hear all beacons so you can do IBSS merges. Oops. So only use MYBEACON for STA + not-scanning, and just use BEACON for the other modes it used to use BEACON for. This doesn't completely fix IBSS merges though - there are still some conditions to chase down and fix. Modified: head/sys/dev/ath/if_ath_rx.c Modified: head/sys/dev/ath/if_ath_rx.c ============================================================================== --- head/sys/dev/ath/if_ath_rx.c Wed Nov 25 18:16:42 2015 (r291303) +++ head/sys/dev/ath/if_ath_rx.c Wed Nov 25 18:24:49 2015 (r291304) @@ -172,9 +172,14 @@ ath_calcrxfilter(struct ath_softc *sc) * * Otherwise we only really need to hear beacons from * our own BSSID. + * + * IBSS? software beacon miss? Just receive all beacons. + * We need to hear beacons/probe requests from everyone so + * we can merge ibss. */ - if (ic->ic_opmode == IEEE80211_M_STA || - ic->ic_opmode == IEEE80211_M_IBSS || sc->sc_swbmiss) { + if (ic->ic_opmode == IEEE80211_M_IBSS || sc->sc_swbmiss) { + rfilt |= HAL_RX_FILTER_BEACON; + } else if (ic->ic_opmode == IEEE80211_M_STA) { if (sc->sc_do_mybeacon && ! sc->sc_scanning) { rfilt |= HAL_RX_FILTER_MYBEACON; } else { /* scanning, non-mybeacon chips */ @@ -431,7 +436,6 @@ ath_recv_mgmt(struct ieee80211_node *ni, sc->sc_syncbeacon = 0; } - /* fall thru... */ case IEEE80211_FC0_SUBTYPE_PROBE_RESP: if (vap->iv_opmode == IEEE80211_M_IBSS &&