Merge tag 'iwlwifi-next-for-kalle-2015-04-02' of https://git.kernel.org/pub/scm/linux...
[firefly-linux-kernel-4.4.55.git] / drivers / net / wireless / iwlwifi / mvm / rs.c
index 9140b0b701c75cd316c8d1063fdc1e4286339f7c..f9928f2c125f726bbf89474096bd47990bfb86eb 100644 (file)
@@ -1277,9 +1277,7 @@ void iwl_mvm_rs_tx_status(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
                                        info->status.ampdu_ack_len);
                }
        } else {
-       /*
-        * For legacy, update frame history with for each Tx retry.
-        */
+               /* For legacy, update frame history with for each Tx retry. */
                retries = info->status.rates[0].count - 1;
                /* HW doesn't send more than 15 retries */
                retries = min(retries, 15);
@@ -1615,9 +1613,9 @@ static void rs_stay_in_table(struct iwl_lq_sta *lq_sta, bool force_search)
 static void rs_update_rate_tbl(struct iwl_mvm *mvm,
                               struct ieee80211_sta *sta,
                               struct iwl_lq_sta *lq_sta,
-                              struct rs_rate *rate)
+                              struct iwl_scale_tbl_info *tbl)
 {
-       rs_fill_lq_cmd(mvm, sta, lq_sta, rate);
+       rs_fill_lq_cmd(mvm, sta, lq_sta, &tbl->rate);
        iwl_mvm_send_lq_cmd(mvm, &lq_sta->lq, false);
 }
 
@@ -2147,7 +2145,7 @@ static void rs_rate_scale_perform(struct iwl_mvm *mvm,
                        rate->type = LQ_NONE;
                        lq_sta->search_better_tbl = 0;
                        tbl = &(lq_sta->lq_info[lq_sta->active_tbl]);
-                       rs_update_rate_tbl(mvm, sta, lq_sta, &tbl->rate);
+                       rs_update_rate_tbl(mvm, sta, lq_sta, tbl);
                }
                return;
        }
@@ -2310,7 +2308,7 @@ lq_update:
        /* Replace uCode's rate table for the destination station. */
        if (update_lq) {
                tbl->rate.index = index;
-               rs_update_rate_tbl(mvm, sta, lq_sta, &tbl->rate);
+               rs_update_rate_tbl(mvm, sta, lq_sta, tbl);
        }
 
        rs_stay_in_table(lq_sta, false);
@@ -2357,8 +2355,7 @@ lq_update:
 
                        rs_dump_rate(mvm, &tbl->rate,
                                     "Switch to SEARCH TABLE:");
-                       rs_fill_lq_cmd(mvm, sta, lq_sta, &tbl->rate);
-                       iwl_mvm_send_lq_cmd(mvm, &lq_sta->lq, false);
+                       rs_update_rate_tbl(mvm, sta, lq_sta, tbl);
                } else {
                        done_search = 1;
                }
@@ -3238,7 +3235,7 @@ static void rs_fill_lq_cmd(struct iwl_mvm *mvm,
        lq_cmd->agg_frame_cnt_limit = mvmsta->max_agg_bufsize;
 
        /*
-        * In case of low latency, tell the firwmare to leave a frame in the
+        * In case of low latency, tell the firmware to leave a frame in the
         * Tx Fifo so that it can start a transaction in the same TxOP. This
         * basically allows the firmware to send bursts.
         */
@@ -3745,7 +3742,7 @@ void iwl_mvm_rate_control_unregister(void)
 
 /**
  * iwl_mvm_tx_protection - Gets LQ command, change it to enable/disable
- * Tx protection, according to this rquest and previous requests,
+ * Tx protection, according to this request and previous requests,
  * and send the LQ command.
  * @mvmsta: The station
  * @enable: Enable Tx protection?