aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/mvm/rs.c
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2013-10-06 04:41:20 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-10-11 03:58:52 -0400
commitffa6c7077c3f7a433312b733688b9b14f38de17e (patch)
tree91f2cff075d263b235424f0541d769da4c77b039 /drivers/net/wireless/iwlwifi/mvm/rs.c
parente9fff7767e36d1ad993f9b4c0a2b5fc173268585 (diff)
iwlwifi: mvm: BT Coex - update integration with rate control
Remove code that is not needed and always allow MIMO when in tight mode. In loose mode, we should avoid MIMO since BT can use the other antenna to Rx while we Tx. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/mvm/rs.c')
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/rs.c45
1 files changed, 2 insertions, 43 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/rs.c b/drivers/net/wireless/iwlwifi/mvm/rs.c
index 0faeecc0ab1c..a0b4cc8d9c3b 100644
--- a/drivers/net/wireless/iwlwifi/mvm/rs.c
+++ b/drivers/net/wireless/iwlwifi/mvm/rs.c
@@ -1402,29 +1402,9 @@ static int rs_move_siso_to_other(struct iwl_mvm *mvm,
1402 u8 update_search_tbl_counter = 0; 1402 u8 update_search_tbl_counter = 0;
1403 int ret; 1403 int ret;
1404 1404
1405 switch (le32_to_cpu(mvm->last_bt_notif.bt_activity_grading)) { 1405 if (tbl->action == IWL_SISO_SWITCH_MIMO2 &&
1406 case IWL_BT_COEX_TRAFFIC_LOAD_NONE: 1406 !iwl_mvm_bt_coex_is_mimo_allowed(mvm, sta))
1407 /* nothing */
1408 break;
1409 case IWL_BT_COEX_TRAFFIC_LOAD_LOW:
1410 /* avoid switching to antenna B but allow MIMO */
1411 if (tbl->action == IWL_SISO_SWITCH_ANTENNA &&
1412 tbl->ant_type == ANT_A)
1413 tbl->action = IWL_SISO_SWITCH_MIMO2;
1414 break;
1415 case IWL_BT_COEX_TRAFFIC_LOAD_HIGH:
1416 case IWL_BT_COEX_TRAFFIC_LOAD_CONTINUOUS:
1417 /* A - avoid antenna B and MIMO. B - switch to A */
1418 if (tbl->ant_type == ANT_A)
1419 valid_tx_ant =
1420 first_antenna(iwl_fw_valid_tx_ant(mvm->fw));
1421 tbl->action = IWL_SISO_SWITCH_ANTENNA; 1407 tbl->action = IWL_SISO_SWITCH_ANTENNA;
1422 break;
1423 default:
1424 IWL_ERR(mvm, "Invalid BT load %d",
1425 le32_to_cpu(mvm->last_bt_notif.bt_activity_grading));
1426 break;
1427 }
1428 1408
1429 start_action = tbl->action; 1409 start_action = tbl->action;
1430 while (1) { 1410 while (1) {
@@ -1519,27 +1499,6 @@ static int rs_move_mimo2_to_other(struct iwl_mvm *mvm,
1519 u8 update_search_tbl_counter = 0; 1499 u8 update_search_tbl_counter = 0;
1520 int ret; 1500 int ret;
1521 1501
1522 switch (le32_to_cpu(mvm->last_bt_notif.bt_activity_grading)) {
1523 case IWL_BT_COEX_TRAFFIC_LOAD_NONE:
1524 /* nothing */
1525 break;
1526 case IWL_BT_COEX_TRAFFIC_LOAD_HIGH:
1527 case IWL_BT_COEX_TRAFFIC_LOAD_CONTINUOUS:
1528 /* avoid antenna B and MIMO */
1529 if (tbl->action != IWL_MIMO2_SWITCH_SISO_A)
1530 tbl->action = IWL_MIMO2_SWITCH_SISO_A;
1531 break;
1532 case IWL_BT_COEX_TRAFFIC_LOAD_LOW:
1533 /* avoid antenna B unless MIMO */
1534 if (tbl->action == IWL_MIMO2_SWITCH_SISO_B)
1535 tbl->action = IWL_MIMO2_SWITCH_SISO_A;
1536 break;
1537 default:
1538 IWL_ERR(mvm, "Invalid BT load %d",
1539 le32_to_cpu(mvm->last_bt_notif.bt_activity_grading));
1540 break;
1541 }
1542
1543 start_action = tbl->action; 1502 start_action = tbl->action;
1544 while (1) { 1503 while (1) {
1545 lq_sta->action_counter++; 1504 lq_sta->action_counter++;