diff options
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn-rs.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c index 0e6161d7c764..bfcac5608d87 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c | |||
@@ -868,14 +868,14 @@ static void rs_tx_status(void *priv_r, struct ieee80211_supported_band *sband, | |||
868 | rs_get_tbl_info_from_mcs(tx_rate, priv->band, &tbl_type, | 868 | rs_get_tbl_info_from_mcs(tx_rate, priv->band, &tbl_type, |
869 | &rs_index); | 869 | &rs_index); |
870 | rs_collect_tx_data(curr_tbl, rs_index, | 870 | rs_collect_tx_data(curr_tbl, rs_index, |
871 | info->status.ampdu_ack_len, | 871 | info->status.ampdu_len, |
872 | info->status.ampdu_ack_map); | 872 | info->status.ampdu_ack_len); |
873 | 873 | ||
874 | /* Update success/fail counts if not searching for new mode */ | 874 | /* Update success/fail counts if not searching for new mode */ |
875 | if (lq_sta->stay_in_tbl) { | 875 | if (lq_sta->stay_in_tbl) { |
876 | lq_sta->total_success += info->status.ampdu_ack_map; | 876 | lq_sta->total_success += info->status.ampdu_ack_len; |
877 | lq_sta->total_failed += (info->status.ampdu_ack_len - | 877 | lq_sta->total_failed += (info->status.ampdu_len - |
878 | info->status.ampdu_ack_map); | 878 | info->status.ampdu_ack_len); |
879 | } | 879 | } |
880 | } else { | 880 | } else { |
881 | /* | 881 | /* |
@@ -2078,10 +2078,12 @@ static void rs_rate_scale_perform(struct iwl_priv *priv, | |||
2078 | } | 2078 | } |
2079 | /* Else we have enough samples; calculate estimate of | 2079 | /* Else we have enough samples; calculate estimate of |
2080 | * actual average throughput */ | 2080 | * actual average throughput */ |
2081 | 2081 | if (window->average_tpt != ((window->success_ratio * | |
2082 | /* Sanity-check TPT calculations */ | 2082 | tbl->expected_tpt[index] + 64) / 128)) { |
2083 | BUG_ON(window->average_tpt != ((window->success_ratio * | 2083 | IWL_ERR(priv, "expected_tpt should have been calculated by now\n"); |
2084 | tbl->expected_tpt[index] + 64) / 128)); | 2084 | window->average_tpt = ((window->success_ratio * |
2085 | tbl->expected_tpt[index] + 64) / 128); | ||
2086 | } | ||
2085 | 2087 | ||
2086 | /* If we are searching for better modulation mode, check success. */ | 2088 | /* If we are searching for better modulation mode, check success. */ |
2087 | if (lq_sta->search_better_tbl && | 2089 | if (lq_sta->search_better_tbl && |