diff options
author | Kalle Valo <kvalo@qca.qualcomm.com> | 2012-06-14 07:20:18 -0400 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2012-06-14 07:44:49 -0400 |
commit | d987dd137bac8dca9b0015763d3106f48bb8a596 (patch) | |
tree | ef887505b3c904c548d58ec9bb6f4970a0877042 /drivers/net/wireless/ath/ath9k/btcoex.c | |
parent | c85251f8562095cd6fd63ae786354283c5318303 (diff) | |
parent | 211c17aaee644bb808fbdeef547ac99db92c01ed (diff) |
Merge remote branch 'wireless-next/master' into ath6kl-next
Conflicts:
drivers/net/wireless/ath/ath6kl/cfg80211.c
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/btcoex.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/btcoex.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/drivers/net/wireless/ath/ath9k/btcoex.c b/drivers/net/wireless/ath/ath9k/btcoex.c index ec3271993411..acd437384fe4 100644 --- a/drivers/net/wireless/ath/ath9k/btcoex.c +++ b/drivers/net/wireless/ath/ath9k/btcoex.c | |||
@@ -108,9 +108,7 @@ void ath9k_hw_btcoex_init_scheme(struct ath_hw *ah) | |||
108 | return; | 108 | return; |
109 | } | 109 | } |
110 | 110 | ||
111 | if (AR_SREV_9462(ah)) { | 111 | if (AR_SREV_9300_20_OR_LATER(ah)) { |
112 | btcoex_hw->scheme = ATH_BTCOEX_CFG_MCI; | ||
113 | } else if (AR_SREV_9300_20_OR_LATER(ah)) { | ||
114 | btcoex_hw->scheme = ATH_BTCOEX_CFG_3WIRE; | 112 | btcoex_hw->scheme = ATH_BTCOEX_CFG_3WIRE; |
115 | btcoex_hw->btactive_gpio = ATH_BTACTIVE_GPIO_9300; | 113 | btcoex_hw->btactive_gpio = ATH_BTACTIVE_GPIO_9300; |
116 | btcoex_hw->wlanactive_gpio = ATH_WLANACTIVE_GPIO_9300; | 114 | btcoex_hw->wlanactive_gpio = ATH_WLANACTIVE_GPIO_9300; |
@@ -284,11 +282,12 @@ void ath9k_hw_btcoex_enable(struct ath_hw *ah) | |||
284 | ath9k_hw_btcoex_enable_2wire(ah); | 282 | ath9k_hw_btcoex_enable_2wire(ah); |
285 | break; | 283 | break; |
286 | case ATH_BTCOEX_CFG_3WIRE: | 284 | case ATH_BTCOEX_CFG_3WIRE: |
285 | if (AR_SREV_9462(ah)) { | ||
286 | ath9k_hw_btcoex_enable_mci(ah); | ||
287 | return; | ||
288 | } | ||
287 | ath9k_hw_btcoex_enable_3wire(ah); | 289 | ath9k_hw_btcoex_enable_3wire(ah); |
288 | break; | 290 | break; |
289 | case ATH_BTCOEX_CFG_MCI: | ||
290 | ath9k_hw_btcoex_enable_mci(ah); | ||
291 | return; | ||
292 | } | 291 | } |
293 | 292 | ||
294 | REG_RMW(ah, AR_GPIO_PDPU, | 293 | REG_RMW(ah, AR_GPIO_PDPU, |
@@ -305,11 +304,12 @@ void ath9k_hw_btcoex_disable(struct ath_hw *ah) | |||
305 | int i; | 304 | int i; |
306 | 305 | ||
307 | btcoex_hw->enabled = false; | 306 | btcoex_hw->enabled = false; |
308 | if (btcoex_hw->scheme == ATH_BTCOEX_CFG_MCI) { | 307 | if (AR_SREV_9462(ah)) { |
309 | ath9k_hw_btcoex_bt_stomp(ah, ATH_BTCOEX_STOMP_NONE); | 308 | ath9k_hw_btcoex_bt_stomp(ah, ATH_BTCOEX_STOMP_NONE); |
310 | for (i = 0; i < AR9300_NUM_BT_WEIGHTS; i++) | 309 | for (i = 0; i < AR9300_NUM_BT_WEIGHTS; i++) |
311 | REG_WRITE(ah, AR_MCI_COEX_WL_WEIGHTS(i), | 310 | REG_WRITE(ah, AR_MCI_COEX_WL_WEIGHTS(i), |
312 | btcoex_hw->wlan_weight[i]); | 311 | btcoex_hw->wlan_weight[i]); |
312 | return; | ||
313 | } | 313 | } |
314 | ath9k_hw_set_gpio(ah, btcoex_hw->wlanactive_gpio, 0); | 314 | ath9k_hw_set_gpio(ah, btcoex_hw->wlanactive_gpio, 0); |
315 | 315 | ||
@@ -336,10 +336,16 @@ static void ar9003_btcoex_bt_stomp(struct ath_hw *ah, | |||
336 | enum ath_stomp_type stomp_type) | 336 | enum ath_stomp_type stomp_type) |
337 | { | 337 | { |
338 | struct ath_btcoex_hw *btcoex = &ah->btcoex_hw; | 338 | struct ath_btcoex_hw *btcoex = &ah->btcoex_hw; |
339 | const u32 *weight = AR_SREV_9462(ah) ? ar9003_wlan_weights[stomp_type] : | 339 | const u32 *weight = ar9003_wlan_weights[stomp_type]; |
340 | ar9462_wlan_weights[stomp_type]; | ||
341 | int i; | 340 | int i; |
342 | 341 | ||
342 | if (AR_SREV_9462(ah)) { | ||
343 | if ((stomp_type == ATH_BTCOEX_STOMP_LOW) && | ||
344 | btcoex->mci.stomp_ftp) | ||
345 | stomp_type = ATH_BTCOEX_STOMP_LOW_FTP; | ||
346 | weight = ar9462_wlan_weights[stomp_type]; | ||
347 | } | ||
348 | |||
343 | for (i = 0; i < AR9300_NUM_WLAN_WEIGHTS; i++) { | 349 | for (i = 0; i < AR9300_NUM_WLAN_WEIGHTS; i++) { |
344 | btcoex->bt_weight[i] = AR9300_BT_WGHT; | 350 | btcoex->bt_weight[i] = AR9300_BT_WGHT; |
345 | btcoex->wlan_weight[i] = weight[i]; | 351 | btcoex->wlan_weight[i] = weight[i]; |