svn commit: r222299 - head/sys/dev/ath/ath_hal
Adrian Chadd
adrian at FreeBSD.org
Thu May 26 08:20:15 UTC 2011
Author: adrian
Date: Thu May 26 08:20:14 2011
New Revision: 222299
URL: http://svn.freebsd.org/changeset/base/222299
Log:
Add temp sense to the EEPROM variable list;
Export the temperature sense variables to ah_eeprom_9287.c
Modified:
head/sys/dev/ath/ath_hal/ah_eeprom.h
head/sys/dev/ath/ath_hal/ah_eeprom_9287.c
Modified: head/sys/dev/ath/ath_hal/ah_eeprom.h
==============================================================================
--- head/sys/dev/ath/ath_hal/ah_eeprom.h Thu May 26 06:43:10 2011 (r222298)
+++ head/sys/dev/ath/ath_hal/ah_eeprom.h Thu May 26 08:20:14 2011 (r222299)
@@ -101,7 +101,9 @@ enum {
AR_EEP_ANTGAINMAX_2, /* int8_t* */
AR_EEP_WRITEPROTECT, /* use ath_hal_eepromGetFlag */
AR_EEP_PWR_TABLE_OFFSET,/* int8_t* */
- AR_EEP_PWDCLKIND /* uint8_t* */
+ AR_EEP_PWDCLKIND, /* uint8_t* */
+ AR_EEP_TEMPSENSE_SLOPE, /* int8_t* */
+ AR_EEP_TEMPSENSE_SLOPE_PAL_ON, /* int8_t* */
};
typedef struct {
Modified: head/sys/dev/ath/ath_hal/ah_eeprom_9287.c
==============================================================================
--- head/sys/dev/ath/ath_hal/ah_eeprom_9287.c Thu May 26 06:43:10 2011 (r222298)
+++ head/sys/dev/ath/ath_hal/ah_eeprom_9287.c Thu May 26 08:20:14 2011 (r222299)
@@ -63,28 +63,10 @@ v9287EepromGet(struct ath_hal *ah, int p
return pBase->opCapFlags;
case AR_EEP_RFSILENT:
return pBase->rfSilent;
-#if 0
- case AR_EEP_OB_5:
- return pModal[CHAN_A_IDX].ob;
- case AR_EEP_DB_5:
- return pModal[CHAN_A_IDX].db;
- case AR_EEP_OB_2:
- return pModal[CHAN_B_IDX].ob;
- case AR_EEP_DB_2:
- return pModal[CHAN_B_IDX].db;
-#endif
case AR_EEP_TXMASK:
return pBase->txMask;
case AR_EEP_RXMASK:
return pBase->rxMask;
-#if 0
- case AR_EEP_RXGAIN_TYPE:
- return IS_VERS(>=, AR5416_EEP_MINOR_VER_17) ?
- pBase->rxGainType : AR5416_EEP_RXGAIN_ORIG;
- case AR_EEP_TXGAIN_TYPE:
- return IS_VERS(>=, AR5416_EEP_MINOR_VER_19) ?
- pBase->txGainType : AR5416_EEP_TXGAIN_ORIG;
-#endif
case AR_EEP_OL_PWRCTRL:
HALASSERT(val == AH_NULL);
return pBase->openLoopPwrCntl ? HAL_OK : HAL_EIO;
@@ -117,6 +99,18 @@ v9287EepromGet(struct ath_hal *ah, int p
case AR_EEP_PWR_TABLE_OFFSET:
*(int8_t *) val = pBase->pwrTableOffset;
return HAL_OK;
+ case AR_EEP_TEMPSENSE_SLOPE:
+ if (IS_VERS(>=, AR9287_EEP_MINOR_VER_2))
+ *(int8_t *)val = pBase->tempSensSlope;
+ else
+ *(int8_t *)val = 0;
+ return HAL_OK;
+ case AR_EEP_TEMPSENSE_SLOPE_PAL_ON:
+ if (IS_VERS(>=, AR9287_EEP_MINOR_VER_3))
+ *(int8_t *)val = pBase->tempSensSlopePalOn;
+ else
+ *(int8_t *)val = 0;
+ return HAL_OK;
default:
HALASSERT(0);
return HAL_EINVAL;
@@ -135,10 +129,6 @@ v9287EepromSet(struct ath_hal *ah, int p
case AR_EEP_ANTGAINMAX_2:
ee->ee_antennaGainMax[1] = (int8_t) v;
return HAL_OK;
- case AR_EEP_ANTGAINMAX_5:
- ee->ee_antennaGainMax[0] = (int8_t) v;
- return HAL_OK;
- }
return HAL_EINVAL;
}
More information about the svn-src-all
mailing list