aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorMohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>2011-07-11 10:44:14 -0400
committerJohn W. Linville <linville@tuxdriver.com>2011-07-11 15:02:21 -0400
commit9dff387046ef20547236b75dd0d095904e4c0779 (patch)
treedabcf5247f2d78df1c09ca22d6ffb3dcdf5e896a /drivers/net/wireless
parent43bf8c245237b8309153aa39d4e8f1586cf56af0 (diff)
ath9k: remove an unnecessary function declaration
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/ath/ath9k/rc.c50
1 files changed, 24 insertions, 26 deletions
diff --git a/drivers/net/wireless/ath/ath9k/rc.c b/drivers/net/wireless/ath/ath9k/rc.c
index e7fe4d9aee79..c04a6c3cac7f 100644
--- a/drivers/net/wireless/ath/ath9k/rc.c
+++ b/drivers/net/wireless/ath/ath9k/rc.c
@@ -379,7 +379,30 @@ static const struct ath_rate_table ar5416_11g_ratetable = {
379}; 379};
380 380
381static int ath_rc_get_rateindex(const struct ath_rate_table *rate_table, 381static int ath_rc_get_rateindex(const struct ath_rate_table *rate_table,
382 struct ieee80211_tx_rate *rate); 382 struct ieee80211_tx_rate *rate)
383{
384 int rix = 0, i = 0;
385 static const int mcs_rix_off[] = { 7, 15, 20, 21, 22, 23 };
386
387 if (!(rate->flags & IEEE80211_TX_RC_MCS))
388 return rate->idx;
389
390 while (i < ARRAY_SIZE(mcs_rix_off) && rate->idx > mcs_rix_off[i]) {
391 rix++; i++;
392 }
393
394 rix += rate->idx + rate_table->mcs_start;
395
396 if ((rate->flags & IEEE80211_TX_RC_40_MHZ_WIDTH) &&
397 (rate->flags & IEEE80211_TX_RC_SHORT_GI))
398 rix = rate_table->info[rix].ht_index;
399 else if (rate->flags & IEEE80211_TX_RC_SHORT_GI)
400 rix = rate_table->info[rix].sgi_index;
401 else if (rate->flags & IEEE80211_TX_RC_40_MHZ_WIDTH)
402 rix = rate_table->info[rix].cw40index;
403
404 return rix;
405}
383 406
384static void ath_rc_sort_validrates(const struct ath_rate_table *rate_table, 407static void ath_rc_sort_validrates(const struct ath_rate_table *rate_table,
385 struct ath_rate_priv *ath_rc_priv) 408 struct ath_rate_priv *ath_rc_priv)
@@ -1080,31 +1103,6 @@ static void ath_rc_update_ht(struct ath_softc *sc,
1080 1103
1081} 1104}
1082 1105
1083static int ath_rc_get_rateindex(const struct ath_rate_table *rate_table,
1084 struct ieee80211_tx_rate *rate)
1085{
1086 int rix = 0, i = 0;
1087 static const int mcs_rix_off[] = { 7, 15, 20, 21, 22, 23 };
1088
1089 if (!(rate->flags & IEEE80211_TX_RC_MCS))
1090 return rate->idx;
1091
1092 while (i < ARRAY_SIZE(mcs_rix_off) && rate->idx > mcs_rix_off[i]) {
1093 rix++; i++;
1094 }
1095
1096 rix += rate->idx + rate_table->mcs_start;
1097
1098 if ((rate->flags & IEEE80211_TX_RC_40_MHZ_WIDTH) &&
1099 (rate->flags & IEEE80211_TX_RC_SHORT_GI))
1100 rix = rate_table->info[rix].ht_index;
1101 else if (rate->flags & IEEE80211_TX_RC_SHORT_GI)
1102 rix = rate_table->info[rix].sgi_index;
1103 else if (rate->flags & IEEE80211_TX_RC_40_MHZ_WIDTH)
1104 rix = rate_table->info[rix].cw40index;
1105
1106 return rix;
1107}
1108 1106
1109static void ath_rc_tx_status(struct ath_softc *sc, 1107static void ath_rc_tx_status(struct ath_softc *sc,
1110 struct ath_rate_priv *ath_rc_priv, 1108 struct ath_rate_priv *ath_rc_priv,