diff options
author | Adrian Chadd <adrian@FreeBSD.org> | 2013-02-20 12:14:49 +0000 |
---|---|---|
committer | Adrian Chadd <adrian@FreeBSD.org> | 2013-02-20 12:14:49 +0000 |
commit | d7cc11edcecebe23521a58a772a2bfedfc627e67 (patch) | |
tree | 836bd846a4d341a581aafc6e908404ffda4227f7 /sys | |
parent | 71d6fe723e2f1c42dc93aece38ae201057ce2b21 (diff) | |
download | src-d7cc11edcecebe23521a58a772a2bfedfc627e67.tar.gz src-d7cc11edcecebe23521a58a772a2bfedfc627e67.zip |
Configure larger TX FIFO default and maximum level values.
This has reduced the number of TX delimiter and data underruns when
doing large UDP transfers (>100mbit).
This stops any HAL_INT_TXURN interrupts from occuring, which is a good
sign!
Obtained from: Qualcomm Atheros
Notes
Notes:
svn path=/head/; revision=247033
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/ath/ath_hal/ar5416/ar5416_attach.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c b/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c index d165540ece29..30d1161a546e 100644 --- a/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c +++ b/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c @@ -241,8 +241,24 @@ ar5416InitState(struct ath_hal_5416 *ahp5416, uint16_t devid, HAL_SOFTC sc, /* Enable all ANI functions to begin with */ AH5416(ah)->ah_ani_function = 0xffffffff; - /* Set overridable ANI methods */ - AH5212(ah)->ah_aniControl = ar5416AniControl; + /* Set overridable ANI methods */ + AH5212(ah)->ah_aniControl = ar5416AniControl; + + /* Default FIFO Trigger levels */ +#define AR_FTRIG_512B 0x00000080 // 5 bits total + /* AR9285/AR9271 need to use half the TX FIFOs */ + if (AR_SREV_KITE(ah) || AR_SREV_9271(ah)) { + AH5212(ah)->ah_txTrigLev = (AR_FTRIG_256B >> AR_FTRIG_S); + AH5212(ah)->ah_maxTxTrigLev = ((2048 / 64) - 1); + } else { + AH5212(ah)->ah_txTrigLev = (AR_FTRIG_512B >> AR_FTRIG_S); + AH5212(ah)->ah_maxTxTrigLev = ((4096 / 64) - 1); + } + ath_hal_printf(ah, "%s: trigLev=%d, maxTxTrigLev=%d\n", + __func__, + AH5212(ah)->ah_txTrigLev, + AH5212(ah)->ah_maxTxTrigLev); +#undef AR_FTRIG_512B } uint32_t |