From owner-svn-src-all@FreeBSD.ORG Tue Feb 8 12:49:02 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E6987106566B; Tue, 8 Feb 2011 12:49:01 +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 D6D2D8FC18; Tue, 8 Feb 2011 12:49:01 +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 p18Cn1pK046324; Tue, 8 Feb 2011 12:49:01 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p18Cn1ot046317; Tue, 8 Feb 2011 12:49:01 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201102081249.p18Cn1ot046317@svn.freebsd.org> From: Adrian Chadd Date: Tue, 8 Feb 2011 12:49:01 +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: r218436 - in head/sys/dev/ath/ath_hal: . ar5210 ar5211 ar5212 ar9002 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Feb 2011 12:49:02 -0000 Author: adrian Date: Tue Feb 8 12:49:01 2011 New Revision: 218436 URL: http://svn.freebsd.org/changeset/base/218436 Log: There's apparently a bug with Merlin (AR9280) and later chipsets where putting descriptors (not buffers) across a 4k page boundary can cause issues. I've not seen it in production myself but it apparently can cause problems. So, in preparation for addressing this workaround, (re)-expose the particular HAL capability bit which marks whether the chipset has support for cross-4k- boundary transactions or not. A subsequent commit will modify the descriptor allocation to avoid allocating descriptor entries that straddle a 4k page boundary. Modified: head/sys/dev/ath/ath_hal/ah_internal.h head/sys/dev/ath/ath_hal/ar5210/ar5210_attach.c head/sys/dev/ath/ath_hal/ar5211/ar5211_attach.c head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Modified: head/sys/dev/ath/ath_hal/ah_internal.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah_internal.h Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ah_internal.h Tue Feb 8 12:49:01 2011 (r218436) @@ -195,7 +195,8 @@ typedef struct { halForcePpmSupport : 1, halEnhancedPmSupport : 1, halMbssidAggrSupport : 1, - halBssidMatchSupport : 1; + halBssidMatchSupport : 1, + hal4kbSplitTransSupport : 1; uint32_t halWirelessModes; uint16_t halTotalQueues; uint16_t halKeyCacheSize; Modified: head/sys/dev/ath/ath_hal/ar5210/ar5210_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5210/ar5210_attach.c Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ar5210/ar5210_attach.c Tue Feb 8 12:49:01 2011 (r218436) @@ -377,6 +377,8 @@ ar5210FillCapabilityInfo(struct ath_hal | HAL_INT_FATAL ; + pCap->hal4kbSplitTransSupport = AH_TRUE; + ahpriv->ah_rxornIsFatal = AH_TRUE; return AH_TRUE; } Modified: head/sys/dev/ath/ath_hal/ar5211/ar5211_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5211/ar5211_attach.c Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ar5211/ar5211_attach.c Tue Feb 8 12:49:01 2011 (r218436) @@ -509,6 +509,8 @@ ar5211FillCapabilityInfo(struct ath_hal | HAL_INT_TIM ; + pCap->hal4kbSplitTransSupport = AH_TRUE; + /* XXX might be ok w/ some chip revs */ ahpriv->ah_rxornIsFatal = AH_TRUE; return AH_TRUE; Modified: head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c Tue Feb 8 12:49:01 2011 (r218436) @@ -860,6 +860,8 @@ ar5212FillCapabilityInfo(struct ath_hal if (AH_PRIVATE(ah)->ah_macVersion < AR_SREV_VERSION_GRIFFIN) pCap->halIntrMask &= ~HAL_INT_TBTT; + pCap->hal4kbSplitTransSupport = AH_TRUE; + return AH_TRUE; #undef IS_COBRA #undef IS_GRIFFIN_LITE Modified: head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Tue Feb 8 12:49:01 2011 (r218436) @@ -698,9 +698,7 @@ ar9280FillCapabilityInfo(struct ath_hal pCap->halBtCoexSupport = AH_TRUE; #endif pCap->halAutoSleepSupport = AH_FALSE; /* XXX? */ -#if 0 pCap->hal4kbSplitTransSupport = AH_FALSE; -#endif pCap->halRxStbcSupport = 1; pCap->halTxStbcSupport = 1; Modified: head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Tue Feb 8 12:12:48 2011 (r218435) +++ head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Tue Feb 8 12:49:01 2011 (r218436) @@ -384,9 +384,7 @@ ar9285FillCapabilityInfo(struct ath_hal pCap->halBtCoexSupport = AH_TRUE; #endif pCap->halAutoSleepSupport = AH_FALSE; /* XXX? */ -#if 0 pCap->hal4kbSplitTransSupport = AH_FALSE; -#endif pCap->halRxStbcSupport = 1; pCap->halTxStbcSupport = 1;