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] [day] [month] [year] [list]
Message-ID: <Z74OgoixUyD5BLDs@shell.armlinux.org.uk>
Date: Tue, 25 Feb 2025 18:40:02 +0000
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Bjørn Mork <bjorn@...k.no>
Cc: Maxime Chevallier <maxime.chevallier@...tlin.com>, davem@...emloft.net,
	Andrew Lunn <andrew@...n.ch>, Jakub Kicinski <kuba@...nel.org>,
	Eric Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>,
	Heiner Kallweit <hkallweit1@...il.com>, netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org, thomas.petazzoni@...tlin.com,
	Florian Fainelli <f.fainelli@...il.com>,
	Köry Maincent <kory.maincent@...tlin.com>,
	Simon Horman <horms@...nel.org>,
	Romain Gantois <romain.gantois@...tlin.com>,
	Antoine Tenart <atenart@...nel.org>,
	Marek Behún <kabel@...nel.org>
Subject: Re: [PATCH net-next 0/2] net: phy: sfp: Add single-byte SMBus SFP
 access

On Tue, Feb 25, 2025 at 07:07:41PM +0100, Bjørn Mork wrote:
> "Russell King (Oracle)" <linux@...linux.org.uk> writes:
> 
> >> I believe you are reading more into the spec than what's actually there.
> >
> > So I'm making up the quote above from SFF-8472.  Okay, if that's where
> > this discussion is going, I'm done here.
> 
> No, not at all.  That was not what I meant.  Please accept my apologies.
> This came out wrong. You are absolutely correct about reading the 16bit
> diagnostic registers you quoted. I would never doubt that. I have an
> extreme respect for you and your knowledge of these standards and the
> practical hardware implications.
> 
> It was the conclusion that this fact prevents SMBus hosts I wanted to
> question.  I still don't see that.  Some SMBus hosts might be able do 2
> byte reads.  And if they can't, then I believe they can safely ignore
> these registers without being out of spec.  Like the proposed solution.

It doesn't prevent SMBus hosts, but it does prevent SMBus hosts from
being able to be used *reliably* with the diagnostics "EEPROM" to read
the values in a coherent manner.

It also prevents being able to identify the Nokia 3FE46541AA module,
because the module's I2C locks the bus when a single-byte read of
offset 0x51 in the "identity" EEPROM at 0xA0/0x50.

We do already have single-byte mode in the SFP driver, which is
necessary to work around the broken I2C interface on RTL8672 and
RTL9601C which emulate that EEPROM.

There's a lot of "brokenness" out there, and what I've learnt from
dealing with SFPs over the last 10+ years is to be cautious about
*everything*. One thing that can be guaranteed is that a module will
be broken in unexpected ways, and using a different behaviour for
working modules will turn out to break.

The Nokia 3FE46541AA is a brilliant example of a module that
emulates all accesses and fails with single-byte reads, thus making
it incompatible with a SMBus that can only read single bytes.

-- 
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