From c3371d64d2b2fd029033976046cb4ca641485506 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Sat, 26 Feb 2011 04:56:53 +0300 Subject: [PATCH] iwlwifi: remove duplicate initialization rate_mask is initialized again later so this can be removed. Btw, if rate_control_send_low(sta, priv_sta, txrc) returns false, that means that "sta" is non-NULL. That's why the second initialization of rate_mask is a little simpler than the first. Signed-off-by: Dan Carpenter Acked-by: Wey-Yi Guy Signed-off-by: John W. Linville --- drivers/net/wireless/iwlegacy/iwl-3945-rs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/iwlegacy/iwl-3945-rs.c b/drivers/net/wireless/iwlegacy/iwl-3945-rs.c index 4fabc5439858..977bd2477c6a 100644 --- a/drivers/net/wireless/iwlegacy/iwl-3945-rs.c +++ b/drivers/net/wireless/iwlegacy/iwl-3945-rs.c @@ -644,7 +644,7 @@ static void iwl3945_rs_get_rate(void *priv_r, struct ieee80211_sta *sta, u32 fail_count; s8 scale_action = 0; unsigned long flags; - u16 rate_mask = sta ? sta->supp_rates[sband->band] : 0; + u16 rate_mask; s8 max_rate_idx = -1; struct iwl_priv *priv __maybe_unused = (struct iwl_priv *)priv_r; struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -- 2.30.2