From owner-svn-src-head@FreeBSD.ORG Tue Mar 22 07:19:49 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 749D6106566B; Tue, 22 Mar 2011 07:19:49 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 655758FC19; Tue, 22 Mar 2011 07:19:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p2M7JnUc049148; Tue, 22 Mar 2011 07:19:49 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p2M7Jnwh049146; Tue, 22 Mar 2011 07:19:49 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201103220719.p2M7Jnwh049146@svn.freebsd.org> From: Adrian Chadd Date: Tue, 22 Mar 2011 07:19:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r219862 - head/sys/dev/ath/ath_hal/ar5416 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 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: Tue, 22 Mar 2011 07:19:49 -0000 Author: adrian Date: Tue Mar 22 07:19:49 2011 New Revision: 219862 URL: http://svn.freebsd.org/changeset/base/219862 Log: Fix OFDM ANI statistics gathering for the AR5416 and later chips. I found this when trying to figure out why the RX PHY error count didn't match the OFDM error count ANI was using. It turns out there was two problems: * What this commit addresses - using the wrong mask for OFDM errors, and * The RX filter is set incorrectly after a channel scan (at least) even if interference mitigation is enabled by default. ANI is still disabled by default for the AR5416 and later chips. Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Tue Mar 22 05:50:55 2011 (r219861) +++ head/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Tue Mar 22 07:19:49 2011 (r219862) @@ -488,7 +488,7 @@ ar5416AniRestart(struct ath_hal *ah, str OS_REG_WRITE(ah, AR_PHY_ERR_1, params->ofdmPhyErrBase); OS_REG_WRITE(ah, AR_PHY_ERR_2, params->cckPhyErrBase); OS_REG_WRITE(ah, AR_PHY_ERR_MASK_1, AR_PHY_ERR_OFDM_TIMING); - OS_REG_WRITE(ah, AR_PHY_ERR_MASK_1, AR_PHY_ERR_CCK_TIMING); + OS_REG_WRITE(ah, AR_PHY_ERR_MASK_2, AR_PHY_ERR_CCK_TIMING); /* Clear the mib counters and save them in the stats */ ar5212UpdateMibCounters(ah, &ahp->ah_mibStats);