]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/net/wireless/iwlwifi/mvm/rs.c
iwlwifi: mvm: remove unneeded NULL pointer check
[karo-tx-linux.git] / drivers / net / wireless / iwlwifi / mvm / rs.c
index 18a539999580410dbb9caafdae6d975d15def1fe..66e971a99d7c042400d7f903d45fe6f4252cde14 100644 (file)
@@ -1225,7 +1225,7 @@ void iwl_mvm_rs_tx_status(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
        IWL_DEBUG_RATE(mvm, "reduced txpower: %d\n", reduced_txp);
 done:
        /* See if there's a better rate or modulation mode to try. */
-       if (sta && sta->supp_rates[info->band])
+       if (sta->supp_rates[info->band])
                rs_rate_scale_perform(mvm, sta, lq_sta, tid);
 }
 
@@ -2684,6 +2684,9 @@ void iwl_mvm_rs_rate_init(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
                        lq_sta->ldpc = true;
        }
 
+       if (IWL_MVM_RS_DISABLE_MIMO)
+               lq_sta->active_mimo2_rate = 0;
+
        lq_sta->max_legacy_rate_idx = find_last_bit(&lq_sta->active_legacy_rate,
                                                    BITS_PER_LONG);
        lq_sta->max_siso_rate_idx = find_last_bit(&lq_sta->active_siso_rate,