linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iwlwifi: mvm: remove redundant initialization of variable phy_id
@ 2021-01-28 16:39 Colin King
  0 siblings, 0 replies; only message in thread
From: Colin King @ 2021-01-28 16:39 UTC (permalink / raw)
  To: Luca Coelho, Kalle Valo, David S . Miller, Jakub Kicinski,
	Johannes Berg, linux-wireless, netdev
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

The variable phy_id 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 <colin.king@canonical.com>
---
 drivers/net/wireless/intel/iwlwifi/mvm/quota.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/quota.c b/drivers/net/wireless/intel/iwlwifi/mvm/quota.c
index 3d0166df2002..4a0ba7f44900 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/quota.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/quota.c
@@ -90,7 +90,7 @@ static void iwl_mvm_adjust_quota_for_noa(struct iwl_mvm *mvm,
 {
 #ifdef CONFIG_NL80211_TESTMODE
 	struct iwl_mvm_vif *mvmvif;
-	int i, phy_id = -1, beacon_int = 0;
+	int i, phy_id, beacon_int = 0;
 
 	if (!mvm->noa_duration || !mvm->noa_vif)
 		return;
-- 
2.29.2


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-01-28 16:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-28 16:39 [PATCH] iwlwifi: mvm: remove redundant initialization of variable phy_id Colin King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).