[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20200316.150136.1540930644264923.davem@davemloft.net>
Date: Mon, 16 Mar 2020 15:01:36 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: zhengzengkai@...wei.com
Cc: aelior@...vell.com, GR-everest-linux-l2@...vell.com,
linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH net-next] qede: remove some unused code in function
qede_selftest_receive_traffic
From: Zheng Zengkai <zhengzengkai@...wei.com>
Date: Mon, 16 Mar 2020 21:05:24 +0800
> Remove set but not used variables 'sw_comp_cons' and 'hw_comp_cons'
> to fix gcc '-Wunused-but-set-variable' warning:
>
> drivers/net/ethernet/qlogic/qede/qede_ethtool.c: In function qede_selftest_receive_traffic:
> drivers/net/ethernet/qlogic/qede/qede_ethtool.c:1569:20:
> warning: variable sw_comp_cons set but not used [-Wunused-but-set-variable]
> drivers/net/ethernet/qlogic/qede/qede_ethtool.c: In function qede_selftest_receive_traffic:
> drivers/net/ethernet/qlogic/qede/qede_ethtool.c:1569:6:
> warning: variable hw_comp_cons set but not used [-Wunused-but-set-variable]
>
> After removing 'hw_comp_cons',the memory barrier 'rmb()' and its comments become useless,
> so remove them as well.
>
> Reported-by: Hulk Robot <hulkci@...wei.com>
> Signed-off-by: Zheng Zengkai <zhengzengkai@...wei.com>
Applied, thank you.
Powered by blists - more mailing lists