Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1562518 > unrolled thread

[PATCH] net/mlx5e: Remove unused variable

Started byArnd Bergmann <arnd@arndb.de>
First post2017-01-19 10:40 +0100
Last post2017-01-19 17:50 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] net/mlx5e: Remove unused variable Arnd Bergmann <arnd@arndb.de> - 2017-01-19 10:40 +0100
    Re: [PATCH] net/mlx5e: Remove unused variable David Miller <davem@davemloft.net> - 2017-01-19 17:50 +0100

#1562518 — [PATCH] net/mlx5e: Remove unused variable

FromArnd Bergmann <arnd@arndb.de>
Date2017-01-19 10:40 +0100
Subject[PATCH] net/mlx5e: Remove unused variable
Message-ID<t1hmi-8aB-17@gated-at.bofh.it>
A cleanup removed the only user of this variable

mlx5/core/en_ethtool.c: In function 'mlx5e_set_channels':
mlx5/core/en_ethtool.c:546:6: error: unused variable 'ncv' [-Werror=unused-variable]

Let's remove the declaration as well.

Fixes: 639e9e94160e ("net/mlx5e: Remove unnecessary checks when setting num channels")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c b/drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c
index b1b9eb6ee135..5197817e4b2f 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c
@@ -543,7 +543,6 @@ static int mlx5e_set_channels(struct net_device *dev,
 			      struct ethtool_channels *ch)
 {
 	struct mlx5e_priv *priv = netdev_priv(dev);
-	int ncv = mlx5e_get_max_num_channels(priv->mdev);
 	unsigned int count = ch->combined_count;
 	bool arfs_enabled;
 	bool was_opened;
-- 
2.9.0

[toc] | [next] | [standalone]


#1562897

FromDavid Miller <davem@davemloft.net>
Date2017-01-19 17:50 +0100
Message-ID<t1o4q-3Xc-29@gated-at.bofh.it>
In reply to#1562518
From: Arnd Bergmann <arnd@arndb.de>
Date: Thu, 19 Jan 2017 10:33:29 +0100

> A cleanup removed the only user of this variable
> 
> mlx5/core/en_ethtool.c: In function 'mlx5e_set_channels':
> mlx5/core/en_ethtool.c:546:6: error: unused variable 'ncv' [-Werror=unused-variable]
> 
> Let's remove the declaration as well.
> 
> Fixes: 639e9e94160e ("net/mlx5e: Remove unnecessary checks when setting num channels")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Applied.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web