]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
iwlwifi: Send DQA enable command only if TVL is on
authorIlia Lin <ilia.lin@intel.com>
Tue, 14 May 2019 14:19:06 +0000 (17:19 +0300)
committerLuca Coelho <luciano.coelho@intel.com>
Fri, 6 Sep 2019 12:31:10 +0000 (15:31 +0300)
The newer targets don't support the DQA enablement command
and will return error status, while older targets need it.
The feature is defined by the corresponding TLV.
Send the command only if the TLV is enabled.

Signed-off-by: Ilia Lin <ilia.lin@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/fw.c

index 5de54d1559dda8e2fb62bf659b24abf9339e56cf..a57fc6198a722dce38b54230668297732e88cc20 100644 (file)
@@ -1246,9 +1246,11 @@ int iwl_mvm_up(struct iwl_mvm *mvm)
        /* reset quota debouncing buffer - 0xff will yield invalid data */
        memset(&mvm->last_quota_cmd, 0xff, sizeof(mvm->last_quota_cmd));
 
-       ret = iwl_mvm_send_dqa_cmd(mvm);
-       if (ret)
-               goto error;
+       if (fw_has_capa(&mvm->fw->ucode_capa, IWL_UCODE_TLV_CAPA_DQA_SUPPORT)) {
+               ret = iwl_mvm_send_dqa_cmd(mvm);
+               if (ret)
+                       goto error;
+       }
 
        /* Add auxiliary station for scanning */
        ret = iwl_mvm_add_aux_sta(mvm);