diff options
author | Liad Kaufman <liad.kaufman@intel.com> | 2015-09-01 09:36:25 -0400 |
---|---|---|
committer | Luca Coelho <luciano.coelho@intel.com> | 2016-07-05 17:48:55 -0400 |
commit | 28d0793ed212e4714cea79aeb77e62de99b139c1 (patch) | |
tree | 3089d9852759a319cdc0956c01f7ecd47372e691 /drivers/net/wireless/intel/iwlwifi | |
parent | 93f436e2c7feacb04a21bbfb984a7afd87fb4623 (diff) |
iwlwifi: mvm: update aux queue in dqa mode
In DQA mode the AUX queue is mapped elsewhere than in non-
DQA mode. Update the code to reflect this.
Signed-off-by: Liad Kaufman <liad.kaufman@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi')
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 2 | ||||
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 15 | ||||
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 18 |
3 files changed, 27 insertions, 8 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h b/drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h index b06380d8473b..a1d3d95499d6 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h +++ b/drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | |||
@@ -90,6 +90,7 @@ enum { | |||
90 | * DQA queue numbers | 90 | * DQA queue numbers |
91 | * | 91 | * |
92 | * @IWL_MVM_DQA_CMD_QUEUE: a queue reserved for sending HCMDs to the FW | 92 | * @IWL_MVM_DQA_CMD_QUEUE: a queue reserved for sending HCMDs to the FW |
93 | * @IWL_MVM_DQA_AUX_QUEUE: a queue reserved for aux frames | ||
93 | * @IWL_MVM_DQA_P2P_DEVICE_QUEUE: a queue reserved for P2P device frames | 94 | * @IWL_MVM_DQA_P2P_DEVICE_QUEUE: a queue reserved for P2P device frames |
94 | * @IWL_MVM_DQA_GCAST_QUEUE: a queue reserved for P2P GO/SoftAP GCAST frames | 95 | * @IWL_MVM_DQA_GCAST_QUEUE: a queue reserved for P2P GO/SoftAP GCAST frames |
95 | * @IWL_MVM_DQA_BSS_CLIENT_QUEUE: a queue reserved for BSS activity, to ensure | 96 | * @IWL_MVM_DQA_BSS_CLIENT_QUEUE: a queue reserved for BSS activity, to ensure |
@@ -108,6 +109,7 @@ enum { | |||
108 | */ | 109 | */ |
109 | enum iwl_mvm_dqa_txq { | 110 | enum iwl_mvm_dqa_txq { |
110 | IWL_MVM_DQA_CMD_QUEUE = 0, | 111 | IWL_MVM_DQA_CMD_QUEUE = 0, |
112 | IWL_MVM_DQA_AUX_QUEUE = 1, | ||
111 | IWL_MVM_DQA_P2P_DEVICE_QUEUE = 2, | 113 | IWL_MVM_DQA_P2P_DEVICE_QUEUE = 2, |
112 | IWL_MVM_DQA_GCAST_QUEUE = 3, | 114 | IWL_MVM_DQA_GCAST_QUEUE = 3, |
113 | IWL_MVM_DQA_BSS_CLIENT_QUEUE = 4, | 115 | IWL_MVM_DQA_BSS_CLIENT_QUEUE = 4, |
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/ops.c b/drivers/net/wireless/intel/iwlwifi/mvm/ops.c index 063ebbeb8481..a08db009d32a 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/ops.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/ops.c | |||
@@ -577,18 +577,21 @@ iwl_op_mode_mvm_start(struct iwl_trans *trans, const struct iwl_cfg *cfg, | |||
577 | 577 | ||
578 | mvm->restart_fw = iwlwifi_mod_params.restart_fw ? -1 : 0; | 578 | mvm->restart_fw = iwlwifi_mod_params.restart_fw ? -1 : 0; |
579 | 579 | ||
580 | mvm->aux_queue = 15; | ||
581 | if (!iwl_mvm_is_dqa_supported(mvm)) { | 580 | if (!iwl_mvm_is_dqa_supported(mvm)) { |
582 | mvm->first_agg_queue = 16; | ||
583 | mvm->last_agg_queue = mvm->cfg->base_params->num_of_queues - 1; | 581 | mvm->last_agg_queue = mvm->cfg->base_params->num_of_queues - 1; |
582 | |||
583 | if (mvm->cfg->base_params->num_of_queues == 16) { | ||
584 | mvm->aux_queue = 11; | ||
585 | mvm->first_agg_queue = 12; | ||
586 | } else { | ||
587 | mvm->aux_queue = 15; | ||
588 | mvm->first_agg_queue = 16; | ||
589 | } | ||
584 | } else { | 590 | } else { |
591 | mvm->aux_queue = IWL_MVM_DQA_AUX_QUEUE; | ||
585 | mvm->first_agg_queue = IWL_MVM_DQA_MIN_DATA_QUEUE; | 592 | mvm->first_agg_queue = IWL_MVM_DQA_MIN_DATA_QUEUE; |
586 | mvm->last_agg_queue = IWL_MVM_DQA_MAX_DATA_QUEUE; | 593 | mvm->last_agg_queue = IWL_MVM_DQA_MAX_DATA_QUEUE; |
587 | } | 594 | } |
588 | if (mvm->cfg->base_params->num_of_queues == 16) { | ||
589 | mvm->aux_queue = 11; | ||
590 | mvm->first_agg_queue = 12; | ||
591 | } | ||
592 | mvm->sf_state = SF_UNINIT; | 595 | mvm->sf_state = SF_UNINIT; |
593 | mvm->cur_ucode = IWL_UCODE_INIT; | 596 | mvm->cur_ucode = IWL_UCODE_INIT; |
594 | mvm->drop_bcn_ap_mode = true; | 597 | mvm->drop_bcn_ap_mode = true; |
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/sta.c b/drivers/net/wireless/intel/iwlwifi/mvm/sta.c index 9d4ebc9439a0..cf0681765ec4 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/sta.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/sta.c | |||
@@ -1309,8 +1309,9 @@ int iwl_mvm_add_aux_sta(struct iwl_mvm *mvm) | |||
1309 | lockdep_assert_held(&mvm->mutex); | 1309 | lockdep_assert_held(&mvm->mutex); |
1310 | 1310 | ||
1311 | /* Map Aux queue to fifo - needs to happen before adding Aux station */ | 1311 | /* Map Aux queue to fifo - needs to happen before adding Aux station */ |
1312 | iwl_mvm_enable_ac_txq(mvm, mvm->aux_queue, mvm->aux_queue, | 1312 | if (!iwl_mvm_is_dqa_supported(mvm)) |
1313 | IWL_MVM_TX_FIFO_MCAST, 0, wdg_timeout); | 1313 | iwl_mvm_enable_ac_txq(mvm, mvm->aux_queue, mvm->aux_queue, |
1314 | IWL_MVM_TX_FIFO_MCAST, 0, wdg_timeout); | ||
1314 | 1315 | ||
1315 | /* Allocate aux station and assign to it the aux queue */ | 1316 | /* Allocate aux station and assign to it the aux queue */ |
1316 | ret = iwl_mvm_allocate_int_sta(mvm, &mvm->aux_sta, BIT(mvm->aux_queue), | 1317 | ret = iwl_mvm_allocate_int_sta(mvm, &mvm->aux_sta, BIT(mvm->aux_queue), |
@@ -1318,6 +1319,19 @@ int iwl_mvm_add_aux_sta(struct iwl_mvm *mvm) | |||
1318 | if (ret) | 1319 | if (ret) |
1319 | return ret; | 1320 | return ret; |
1320 | 1321 | ||
1322 | if (iwl_mvm_is_dqa_supported(mvm)) { | ||
1323 | struct iwl_trans_txq_scd_cfg cfg = { | ||
1324 | .fifo = IWL_MVM_TX_FIFO_MCAST, | ||
1325 | .sta_id = mvm->aux_sta.sta_id, | ||
1326 | .tid = IWL_MAX_TID_COUNT, | ||
1327 | .aggregate = false, | ||
1328 | .frame_limit = IWL_FRAME_LIMIT, | ||
1329 | }; | ||
1330 | |||
1331 | iwl_mvm_enable_txq(mvm, mvm->aux_queue, mvm->aux_queue, 0, &cfg, | ||
1332 | wdg_timeout); | ||
1333 | } | ||
1334 | |||
1321 | ret = iwl_mvm_add_int_sta_common(mvm, &mvm->aux_sta, NULL, | 1335 | ret = iwl_mvm_add_int_sta_common(mvm, &mvm->aux_sta, NULL, |
1322 | MAC_INDEX_AUX, 0); | 1336 | MAC_INDEX_AUX, 0); |
1323 | 1337 | ||