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: <20250707152226.q6wkavbmfca6y7k4@skbuf>
Date: Mon, 7 Jul 2025 18:22:26 +0300
From: Vladimir Oltean <vladimir.oltean@....com>
To: Maxime Chevallier <maxime.chevallier@...tlin.com>
Cc: davem@...emloft.net, netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org, thomas.petazzoni@...tlin.com,
	Andrew Lunn <andrew@...n.ch>, Jakub Kicinski <kuba@...nel.org>,
	Eric Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>,
	Russell King <linux@...linux.org.uk>,
	Florian Fainelli <f.fainelli@...il.com>,
	Heiner Kallweit <hkallweit1@...il.com>,
	Köry Maincent <kory.maincent@...tlin.com>,
	Oleksij Rempel <o.rempel@...gutronix.de>,
	Simon Horman <horms@...nel.org>, Shuah Khan <shuah@...nel.org>,
	linux-kselftest@...r.kernel.org
Subject: Re: [PATCH net-next 2/3] selftests: ethtool: Drop the unused
 old_netdevs variable

On Wed, Jul 02, 2025 at 10:28:04AM +0200, Maxime Chevallier wrote:
> old_netdevs is unused in ethtool-common.sh. Only the UDP tunnels test
> uses that variable, but it maintains it locally.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@...tlin.com>
> ---

The story seems to be told by commits
fbb8531e58bd ("selftests: extract common functions in ethtool-common.sh") and
9e48ee80ac4e ("selftests: refactor get_netdev_name function").

make_netdev() returns the name of the newly created netdevsim interface.
It used to be implemented by comparing the "before" and "after" of
"ls /sys/class/net". But the name can instead be retrieved from /sys/bus/netdevsim,
and "ls /sys/class/net" is a left-over that was never fully cleaned up.

Meanwhile, udp_tunnel_nic.sh still uses the old and racy method of
finding the netdevsim name, based on the before/after comparison.
It seems like a case of not converging the entire netdevsim test suite
towards the same solution: ethtool-common.sh modified the logic in Nov
2020, udp_tunnel_nic.sh had the logic since Jul 2020.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ