lkml.org 
[lkml]   [2020]   [Mar]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH net-next] qede: remove some unused code in function qede_selftest_receive_traffic
From
From: Zheng Zengkai <zhengzengkai@huawei.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@huawei.com>
> Signed-off-by: Zheng Zengkai <zhengzengkai@huawei.com>

Applied, thank you.

\
 
 \ /
  Last update: 2020-03-16 23:03    [W:0.034 / U:3.744 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site