From owner-svn-src-head@FreeBSD.ORG Fri Mar 11 03:46:28 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 55A511065673; Fri, 11 Mar 2011 03:46:28 +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 44FFA8FC1D; Fri, 11 Mar 2011 03:46:28 +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 p2B3kSpU064962; Fri, 11 Mar 2011 03:46:28 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p2B3kSGj064960; Fri, 11 Mar 2011 03:46:28 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201103110346.p2B3kSGj064960@svn.freebsd.org> From: Adrian Chadd Date: Fri, 11 Mar 2011 03:46:28 +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: r219474 - 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: Fri, 11 Mar 2011 03:46:28 -0000 Author: adrian Date: Fri Mar 11 03:46:27 2011 New Revision: 219474 URL: http://svn.freebsd.org/changeset/base/219474 Log: Don't call ar5416SetTransmitPower() directly from ar5416SetTxPowerLimit(); this is incorrect for Kite (AR9285) and any future chipsets that override the EEPROM related routines. It meant that a direct call to set the TX power would call the v14 EEPROM AR5416/AR9280 calibration routines, rather than the v4k EEPROM routines for the AR9285. It thus read the incorrect values from the EEPROM and programmed garbage PDADC and TX power values into the hardware. Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Fri Mar 11 00:44:32 2011 (r219473) +++ head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Fri Mar 11 03:46:27 2011 (r219474) @@ -405,7 +405,7 @@ ar5416ChannelChange(struct ath_hal *ah, return AH_FALSE; /* Setup the transmit power values. */ - if (!ar5416SetTransmitPower(ah, chan, rfXpdGain)) { + if (!ah->ah_setTxPower(ah, chan, rfXpdGain)) { HALDEBUG(ah, HAL_DEBUG_ANY, "%s: error init'ing transmit power\n", __func__); return AH_FALSE; @@ -748,7 +748,7 @@ ar5416SetTxPowerLimit(struct ath_hal *ah uint16_t dummyXpdGains[2]; AH_PRIVATE(ah)->ah_powerLimit = AH_MIN(limit, MAX_RATE_POWER); - return ar5416SetTransmitPower(ah, AH_PRIVATE(ah)->ah_curchan, + return ah->ah_setTxPower(ah, AH_PRIVATE(ah)->ah_curchan, dummyXpdGains); }