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: <ZZPu5DTlzNVt+7I6@shell.armlinux.org.uk>
Date: Tue, 2 Jan 2024 11:09:24 +0000
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Marek Behún <kabel@...nel.org>
Cc: netdev@...r.kernel.org, Andrew Lunn <andrew@...n.ch>,
	"David S. Miller" <davem@...emloft.net>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	Alexander Couzens <lynxis@...0.eu>,
	Daniel Golle <daniel@...rotopia.org>,
	Heiner Kallweit <hkallweit1@...il.com>,
	Willy Liu <willy.liu@...ltek.com>,
	Ioana Ciornei <ioana.ciornei@....com>,
	Marek Mojík <marek.mojik@....cz>,
	Maximilián Maliar <maximilian.maliar@....cz>
Subject: Re: [PATCH net-next 01/15] net: phy: fail early with error code if
 indirect MMD access fails

On Wed, Dec 20, 2023 at 04:55:04PM +0100, Marek Behún wrote:
> Check return values of __mdiobus_write() in mmd_phy_indirect() and
> return value of mmd_phy_indirect() itself.
> 
> Signed-off-by: Marek Behún <kabel@...nel.org>

I think the reason it was done this way is based on the reasoning that
if the bus has failed then the last read/write will also fail. However,
if we had a spurious failure (and they _do_ happen) then one of the
previous writes e.g. to the indirect address register could have failed
and we could end up corrupting a different register.

Therefore, this makes sense (and some of my commentry should probably
be in the patch description to explain why the change is being made.)

Reviewed-by: Russell King (Oracle) <rmk+kernel@...linux.org.uk>

Thanks!

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ