rtlwifi: remove superfluous condition
authorHeinrich Schuchardt <xypron.glpk@gmx.de>
Tue, 2 Aug 2016 19:26:21 +0000 (21:26 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Sat, 3 Sep 2016 10:03:03 +0000 (13:03 +0300)
If sta == NULL, the changed line will not be reached.
So no need to check that sta != NULL here.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/realtek/rtlwifi/core.c

index 41f77f8a309e751be975a4ed2abdccc61fd6dc10..7aee5ebb147daa6e46a865939cb67152ccaf2ab5 100644 (file)
@@ -1135,7 +1135,7 @@ static void rtl_op_bss_info_changed(struct ieee80211_hw *hw,
                                        mac->mode = WIRELESS_MODE_AC_24G;
                        }
 
-                       if (vif->type == NL80211_IFTYPE_STATION && sta)
+                       if (vif->type == NL80211_IFTYPE_STATION)
                                rtlpriv->cfg->ops->update_rate_tbl(hw, sta, 0);
                        rcu_read_unlock();