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: <87qzyfc5f0.fsf@nvidia.com>
Date: Thu, 17 Jul 2025 15:21:11 +0200
From: Petr Machata <petrm@...dia.com>
To: Simon Horman <horms@...nel.org>
CC: Dennis Chen <dechen@...hat.com>, <netdev@...r.kernel.org>, Jakub Kicinski
	<kuba@...nel.org>, Andrew Lunn <andrew+netdev@...n.ch>, "David S. Miller"
	<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Paolo Abeni
	<pabeni@...hat.com>, <linux-kernel@...r.kernel.org>, Petr Machata
	<petrm@...dia.com>
Subject: Re: [PATCH] netdevsim: remove redundant branch


Simon Horman <horms@...nel.org> writes:

> On Wed, Jul 16, 2025 at 12:57:50PM -0400, Dennis Chen wrote:
>> bool notify is referenced nowhere else in the function except to check
>> whether or not to call rtnl_offload_xstats_notify(). Remove it and move
>> the call to the previous branch.
>> 
>> Signed-off-by: Dennis Chen <dechen@...hat.com>
>> ---
>>  drivers/net/netdevsim/hwstats.c | 5 +----
>>  1 file changed, 1 insertion(+), 4 deletions(-)
>
> Thanks Dennis,
>
> This looks like a nice clean-up to me.
>
> I guess this is an artefact of the development of this code as this pattern
> has been present since the code was added by Petr Machata (CCed) in
> commit 1a6d7ae7d63c ("netdevsim: Introduce support for L3 offload xstats").
>
> Reviewed-by: Simon Horman <horms@...nel.org>

Thanks for the CC!

There was some locking / cleanup business originally that necessitated
the variable. That went away during internal review, but this was left
behind. I agree it can be cleaned up.

Reviewed-by: Petr Machata <petrm@...dia.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ