[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200527081555.124615-1-colin.king@canonical.com>
Date: Wed, 27 May 2020 09:15:55 +0100
From: Colin King <colin.king@...onical.com>
To: Jiri Pirko <jiri@...lanox.com>, Ido Schimmel <idosch@...lanox.com>,
"David S . Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org
Cc: kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH][V2][net-next] mlxsw: spectrum_router: remove redundant initialization of pointer br_dev
From: Colin Ian King <colin.king@...onical.com>
The pointer br_dev is being initialized with a value that is never read
and is being updated with a new value later on. The initialization
is redundant and can be removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@...onical.com>
---
V2: remove stray blank line
---
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
index 71aee4914619..c425b78c6093 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
@@ -7572,7 +7572,7 @@ static struct mlxsw_sp_fid *
mlxsw_sp_rif_vlan_fid_get(struct mlxsw_sp_rif *rif,
struct netlink_ext_ack *extack)
{
- struct net_device *br_dev = rif->dev;
+ struct net_device *br_dev;
u16 vid;
int err;
--
2.25.1
Powered by blists - more mailing lists