diff options
author | John W. Linville <linville@tuxdriver.com> | 2010-07-29 14:47:07 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-07-29 14:47:07 -0400 |
commit | ae3568adf42d5d3bb3cfa505b94351c5d1ce4924 (patch) | |
tree | 112865a6e6b1e4ddf70362f3efb295c495ec85b9 /drivers/net/wireless/ath/ath9k/calib.c | |
parent | 7f3e01fee41a322747db2d7574516d9fbd3785c0 (diff) | |
parent | b7753c8cd51dce67a0b152efb456a21ff1cc241b (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/calib.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/calib.c | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/drivers/net/wireless/ath/ath9k/calib.c b/drivers/net/wireless/ath/ath9k/calib.c index 7f4c55f90e74..139289e4e933 100644 --- a/drivers/net/wireless/ath/ath9k/calib.c +++ b/drivers/net/wireless/ath/ath9k/calib.c | |||
@@ -172,26 +172,9 @@ void ath9k_hw_loadnf(struct ath_hw *ah, struct ath9k_channel *chan) | |||
172 | struct ath9k_nfcal_hist *h; | 172 | struct ath9k_nfcal_hist *h; |
173 | unsigned i, j; | 173 | unsigned i, j; |
174 | int32_t val; | 174 | int32_t val; |
175 | u8 chainmask; | 175 | u8 chainmask = (ah->rxchainmask << 3) | ah->rxchainmask; |
176 | struct ath_common *common = ath9k_hw_common(ah); | 176 | struct ath_common *common = ath9k_hw_common(ah); |
177 | 177 | ||
178 | if (AR_SREV_9300_20_OR_LATER(ah)) | ||
179 | chainmask = 0x3F; | ||
180 | else if (AR_SREV_9285(ah) || AR_SREV_9271(ah)) | ||
181 | chainmask = 0x9; | ||
182 | else if (AR_SREV_9280(ah) || AR_SREV_9287(ah)) { | ||
183 | if ((ah->rxchainmask & 0x2) || (ah->rxchainmask & 0x4)) | ||
184 | chainmask = 0x1B; | ||
185 | else | ||
186 | chainmask = 0x09; | ||
187 | } else { | ||
188 | if (ah->rxchainmask & 0x4) | ||
189 | chainmask = 0x3F; | ||
190 | else if (ah->rxchainmask & 0x2) | ||
191 | chainmask = 0x1B; | ||
192 | else | ||
193 | chainmask = 0x09; | ||
194 | } | ||
195 | h = ah->nfCalHist; | 178 | h = ah->nfCalHist; |
196 | 179 | ||
197 | for (i = 0; i < NUM_NF_READINGS; i++) { | 180 | for (i = 0; i < NUM_NF_READINGS; i++) { |
@@ -278,7 +261,7 @@ static void ath9k_hw_nf_sanitize(struct ath_hw *ah, s16 *nf) | |||
278 | 261 | ||
279 | ath_print(common, ATH_DBG_CALIBRATE, | 262 | ath_print(common, ATH_DBG_CALIBRATE, |
280 | "NF calibrated [%s] [chain %d] is %d\n", | 263 | "NF calibrated [%s] [chain %d] is %d\n", |
281 | (i > 3 ? "ext" : "ctl"), i % 3, nf[i]); | 264 | (i >= 3 ? "ext" : "ctl"), i % 3, nf[i]); |
282 | 265 | ||
283 | if (nf[i] > limit->max) { | 266 | if (nf[i] > limit->max) { |
284 | ath_print(common, ATH_DBG_CALIBRATE, | 267 | ath_print(common, ATH_DBG_CALIBRATE, |