From owner-svn-src-head@freebsd.org Fri Jun 8 18:15:24 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CBAE61020E28; Fri, 8 Jun 2018 18:15:24 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7F9986DC5C; Fri, 8 Jun 2018 18:15:24 +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 mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 5C2E81294C; Fri, 8 Jun 2018 18:15:24 +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 w58IFOAu014691; Fri, 8 Jun 2018 18:15:24 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w58IFN23014690; Fri, 8 Jun 2018 18:15:23 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201806081815.w58IFN23014690@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Fri, 8 Jun 2018 18:15:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r334848 - in head/sys/dev/ath/ath_hal: ar5212 ar5416 X-SVN-Group: head X-SVN-Commit-Author: adrian X-SVN-Commit-Paths: in head/sys/dev/ath/ath_hal: ar5212 ar5416 X-SVN-Commit-Revision: 334848 X-SVN-Commit-Repository: base 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.26 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: Fri, 08 Jun 2018 18:15:25 -0000 Author: adrian Date: Fri Jun 8 18:15:23 2018 New Revision: 334848 URL: https://svnweb.freebsd.org/changeset/base/334848 Log: [ath_hal] Don't do ANI processing if we've reset. If we've reset then we can't trust the current state of the ANI tracking, so just wait until next time. Tested: * AR5424, STA mode (2GHz) Modified: head/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Modified: head/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c Fri Jun 8 18:09:19 2018 (r334847) +++ head/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c Fri Jun 8 18:15:23 2018 (r334848) @@ -1000,6 +1000,9 @@ ar5212AniPoll(struct ath_hal *ah, const struct ieee802 ahp->ah_stats.ast_ani_lneg++; /* restart ANI period if listenTime is invalid */ ar5212AniRestart(ah, aniState); + + /* Don't do any further ANI processing here */ + return; } /* XXX beware of overflow? */ aniState->listenTime += listenTime; Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Fri Jun 8 18:09:19 2018 (r334847) +++ head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Fri Jun 8 18:15:23 2018 (r334848) @@ -950,6 +950,9 @@ ar5416AniPoll(struct ath_hal *ah, const struct ieee802 HALDEBUG(ah, HAL_DEBUG_ANI, "%s: invalid listenTime\n", __func__); ar5416AniRestart(ah, aniState); + + /* Don't do any further processing */ + return; } /* XXX beware of overflow? */ aniState->listenTime += listenTime;