lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <IA3PR11MB89862D06204DB7141DADA5CAE501A@IA3PR11MB8986.namprd11.prod.outlook.com>
Date: Wed, 3 Sep 2025 06:09:49 +0000
From: "Loktionov, Aleksandr" <aleksandr.loktionov@...el.com>
To: Brahmajit Das <listout@...tout.xyz>, "netdev@...r.kernel.org"
	<netdev@...r.kernel.org>, "intel-wired-lan@...ts.osuosl.org"
	<intel-wired-lan@...ts.osuosl.org>
CC: "Nguyen, Anthony L" <anthony.l.nguyen@...el.com>, "Kitszel, Przemyslaw"
	<przemyslaw.kitszel@...el.com>, "andrew+netdev@...n.ch"
	<andrew+netdev@...n.ch>, "davem@...emloft.net" <davem@...emloft.net>,
	"kuba@...nel.org" <kuba@...nel.org>
Subject: RE: [Intel-wired-lan] [PATCH] net: intel: fm10k: Fix parameter idx
 set but not used



> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf
> Of Brahmajit Das
> Sent: Monday, September 1, 2025 11:31 PM
> To: netdev@...r.kernel.org; intel-wired-lan@...ts.osuosl.org
> Cc: Nguyen, Anthony L <anthony.l.nguyen@...el.com>; Kitszel,
> Przemyslaw <przemyslaw.kitszel@...el.com>; andrew+netdev@...n.ch;
> davem@...emloft.net; kuba@...nel.org; listout@...tout.xyz
> Subject: [Intel-wired-lan] [PATCH] net: intel: fm10k: Fix parameter
> idx set but not used
> 
> Variable idx is set in the loop, but is never used resulting in dead
> code. Building with GCC 16, which enables
> -Werror=unused-but-set-parameter= by default results in build error.
> This patch removes the dead code and fixes the build error.
> 
> Signed-off-by: Brahmajit Das <listout@...tout.xyz>
> ---
>  drivers/net/ethernet/intel/fm10k/fm10k_common.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_common.c
> b/drivers/net/ethernet/intel/fm10k/fm10k_common.c
> index f51a63fca513..2fcbbd5accc2 100644
> --- a/drivers/net/ethernet/intel/fm10k/fm10k_common.c
> +++ b/drivers/net/ethernet/intel/fm10k/fm10k_common.c
> @@ -457,7 +457,7 @@ void fm10k_unbind_hw_stats_q(struct
> fm10k_hw_stats_q *q, u32 idx, u32 count)
It looks for me that idx++ was removed, but idx is still passed as a parameter and unused, am I wrong?

>  {
>  	u32 i;
> 
> -	for (i = 0; i < count; i++, idx++, q++) {
> +	for (i = 0; i < count; i++, q++) {
>  		q->rx_stats_idx = 0;
>  		q->tx_stats_idx = 0;
>  	}
> --
> 2.51.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ