diff options
author | Felix Fietkau <nbd@openwrt.org> | 2010-12-28 15:46:16 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-01-04 14:43:01 -0500 |
commit | 1c30cc19081c16b1fe73ac13f2cb2abc009cdcc4 (patch) | |
tree | af987d6d649b6dc221e098147b81b8d0523916de /drivers/net/wireless/ath/ath9k/ar9003_mac.c | |
parent | 1e1f4ad25fab29ca48b1166e74a81e9c89ddf0fb (diff) | |
download | kernel_samsung_tuna-1c30cc19081c16b1fe73ac13f2cb2abc009cdcc4.zip kernel_samsung_tuna-1c30cc19081c16b1fe73ac13f2cb2abc009cdcc4.tar.gz kernel_samsung_tuna-1c30cc19081c16b1fe73ac13f2cb2abc009cdcc4.tar.bz2 |
ath9k_hw: fix dma descriptor rx error bit parsing
An Rx DMA descriptor can have multiple error bits set, and some error
bits (e.g. MIC failure) are filtered by the driver based on other criteria.
Remove the 'else' in various error bit checks so that all error information
is properly passed to the driver.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/ar9003_mac.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/ar9003_mac.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/wireless/ath/ath9k/ar9003_mac.c b/drivers/net/wireless/ath/ath9k/ar9003_mac.c index b6e4ee4..4ceddbb 100644 --- a/drivers/net/wireless/ath/ath9k/ar9003_mac.c +++ b/drivers/net/wireless/ath/ath9k/ar9003_mac.c @@ -613,9 +613,9 @@ int ath9k_hw_process_rxdesc_edma(struct ath_hw *ah, struct ath_rx_status *rxs, * possibly be reviewing the last subframe. AR_CRCErr * is the CRC of the actual data. */ - if (rxsp->status11 & AR_CRCErr) { + if (rxsp->status11 & AR_CRCErr) rxs->rs_status |= ATH9K_RXERR_CRC; - } else if (rxsp->status11 & AR_PHYErr) { + if (rxsp->status11 & AR_PHYErr) { phyerr = MS(rxsp->status11, AR_PHYErrCode); /* * If we reach a point here where AR_PostDelimCRCErr is @@ -638,11 +638,12 @@ int ath9k_hw_process_rxdesc_edma(struct ath_hw *ah, struct ath_rx_status *rxs, rxs->rs_phyerr = phyerr; } - } else if (rxsp->status11 & AR_DecryptCRCErr) { + } + if (rxsp->status11 & AR_DecryptCRCErr) rxs->rs_status |= ATH9K_RXERR_DECRYPT; - } else if (rxsp->status11 & AR_MichaelErr) { + if (rxsp->status11 & AR_MichaelErr) rxs->rs_status |= ATH9K_RXERR_MIC; - } else if (rxsp->status11 & AR_KeyMiss) + if (rxsp->status11 & AR_KeyMiss) rxs->rs_status |= ATH9K_RXERR_DECRYPT; } |