[PATCH] rtlwifi: rtl8192se: remove redundant initialization of variable rtstatus

Subsystems: realtek wireless driver (rtlwifi family), the rest

STALE2017d LANDED

Landed in mainline as 711fa16f1dfe on 2021-02-08.

3 messages, 3 authors, 2021-02-08 · open the first message on its own page

[PATCH] rtlwifi: rtl8192se: remove redundant initialization of variable rtstatus

From: Colin King <hidden>
Date: 2021-01-28 17:14:26

From: Colin Ian King <redacted>

The variable rtstatu is being initialized with a value that is never
read and it is being updated later with a new value.  The initialization
is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <redacted>
---
 drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c
index 63283d9e7485..aaa004d4d6d0 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c
@@ -1017,7 +1017,7 @@ bool rtl92s_phy_bb_config(struct ieee80211_hw *hw)
 {
 	struct rtl_priv *rtlpriv = rtl_priv(hw);
 	struct rtl_phy *rtlphy = &(rtlpriv->phy);
-	bool rtstatus = true;
+	bool rtstatus;
 	u8 pathmap, index, rf_num = 0;
 	u8 path1, path2;
 
-- 
2.29.2

Re: [PATCH] rtlwifi: rtl8192se: remove redundant initialization of variable rtstatus

From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
Date: 2021-01-28 18:48:40

On Thu, Jan 28, 2021 at 12:15 PM Colin King [off-list ref] wrote:
From: Colin Ian King <redacted>

The variable rtstatu is being initialized with a value that is never
read and it is being updated later with a new value.  The initialization
is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <redacted>
(for netdrv)

Acked-by: Willem de Bruijn <willemb@google.com>

Re: [PATCH] rtlwifi: rtl8192se: remove redundant initialization of variable rtstatus

From: Kalle Valo <hidden>
Date: 2021-02-08 10:52:35

Colin King [off-list ref] wrote:
From: Colin Ian King <redacted>

The variable rtstatu is being initialized with a value that is never
read and it is being updated later with a new value.  The initialization
is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <redacted>
Acked-by: Willem de Bruijn <willemb@google.com>
Patch applied to wireless-drivers-next.git, thanks.

711fa16f1dfe rtlwifi: rtl8192se: remove redundant initialization of variable rtstatus

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20210128171048.644669-1-colin.king@canonical.com/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help