Thread (4 messages) 4 messages, 3 authors, 2016-09-03
STALE3570d REVIEWED: 1 (0M)

[PATCH 1/1 v2] rtlwifi: remove superfluous condition

From: Heinrich Schuchardt <hidden>
Date: 2016-08-02 19:26:59
Also in: lkml, netdev
Subsystem: realtek wireless driver (rtlwifi family), the rest · Maintainers: Ping-Ke Shih, Linus Torvalds

If sta == NULL, the changed line will not be reached.
So no need to check that sta != NULL here.

v2:
	fix typo

Signed-off-by: Heinrich Schuchardt <redacted>
Acked-by: Larry Finger <redacted>
---
 drivers/net/wireless/realtek/rtlwifi/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/realtek/rtlwifi/core.c b/drivers/net/wireless/realtek/rtlwifi/core.c
index 41f77f8..7aee5ebb1 100644
--- a/drivers/net/wireless/realtek/rtlwifi/core.c
+++ b/drivers/net/wireless/realtek/rtlwifi/core.c
@@ -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();
 
-- 
2.1.4
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help