From owner-svn-src-head@FreeBSD.ORG Wed Jun 5 00:42:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8D30A804; Wed, 5 Jun 2013 00:42:05 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6411C193D; Wed, 5 Jun 2013 00:42:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r550g5aY051015; Wed, 5 Jun 2013 00:42:05 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r550g4mQ051010; Wed, 5 Jun 2013 00:42:04 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201306050042.r550g4mQ051010@svn.freebsd.org> From: Adrian Chadd Date: Wed, 5 Jun 2013 00:42:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r251400 - in head/sys/dev/ath/ath_hal: . ar9002 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.14 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, 05 Jun 2013 00:42:05 -0000 Author: adrian Date: Wed Jun 5 00:42:04 2013 New Revision: 251400 URL: http://svnweb.freebsd.org/changeset/base/251400 Log: Add a new capability flag to announce that the chip implements LNA mixing for the RX path. This is different to the div comb HAL flag, that says it actually can use this for RX diversity (the "slow" diversity path implemented but disabled in the AR9285 HAL code.) Tested: * AR9285, STA operation Modified: head/sys/dev/ath/ath_hal/ah.c head/sys/dev/ath/ath_hal/ah.h head/sys/dev/ath/ath_hal/ah_internal.h head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Modified: head/sys/dev/ath/ath_hal/ah.c ============================================================================== --- head/sys/dev/ath/ath_hal/ah.c Wed Jun 5 00:39:20 2013 (r251399) +++ head/sys/dev/ath/ath_hal/ah.c Wed Jun 5 00:42:04 2013 (r251400) @@ -784,6 +784,8 @@ ath_hal_getcapability(struct ath_hal *ah case HAL_CAP_MFP: /* Management frame protection setting */ *result = pCap->halMfpSupport; return HAL_OK; + case HAL_CAP_RX_LNA_MIXING: /* Hardware uses an RX LNA mixer to map 2 antennas to a 1 stream receiver */ + return pCap->halRxUsingLnaMixing ? HAL_OK : HAL_ENOTSUPP; default: return HAL_EINVAL; } Modified: head/sys/dev/ath/ath_hal/ah.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah.h Wed Jun 5 00:39:20 2013 (r251399) +++ head/sys/dev/ath/ath_hal/ah.h Wed Jun 5 00:42:04 2013 (r251400) @@ -198,6 +198,7 @@ typedef enum { HAL_CAP_BB_READ_WAR = 244, /* baseband read WAR */ HAL_CAP_SERIALISE_WAR = 245, /* serialise register access on PCI */ HAL_CAP_ENFORCE_TXOP = 246, /* Enforce TXOP if supported */ + HAL_CAP_RX_LNA_MIXING = 247, /* RX hardware uses LNA mixing */ } HAL_CAPABILITY_TYPE; /* Modified: head/sys/dev/ath/ath_hal/ah_internal.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah_internal.h Wed Jun 5 00:39:20 2013 (r251399) +++ head/sys/dev/ath/ath_hal/ah_internal.h Wed Jun 5 00:42:04 2013 (r251400) @@ -279,7 +279,8 @@ typedef struct { halAntDivCombSupport : 1, halAntDivCombSupportOrg : 1, halRadioRetentionSupport : 1, - halSpectralScanSupport : 1; + halSpectralScanSupport : 1, + halRxUsingLnaMixing : 1; uint32_t halWirelessModes; uint16_t halTotalQueues; Modified: head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Wed Jun 5 00:39:20 2013 (r251399) +++ head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Wed Jun 5 00:42:04 2013 (r251400) @@ -525,6 +525,7 @@ ar9285FillCapabilityInfo(struct ath_hal pCap->halMbssidAggrSupport = AH_TRUE; pCap->hal4AddrAggrSupport = AH_TRUE; pCap->halSpectralScanSupport = AH_TRUE; + pCap->halRxUsingLnaMixing = AH_TRUE; if (AR_SREV_KITE_12_OR_LATER(ah)) pCap->halPSPollBroken = AH_FALSE;