The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Maxime Chevallier <maxime.chevallier@bootlin.com>
To: davem@davemloft.net, Andrew Lunn <andrew@lunn.ch>,
	Jakub Kicinski <kuba@kernel.org>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>,
	Russell King <linux@armlinux.org.uk>,
	Heiner Kallweit <hkallweit1@gmail.com>
Cc: "Maxime Chevallier" <maxime.chevallier@bootlin.com>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	thomas.petazzoni@bootlin.com,
	"Florian Fainelli" <f.fainelli@gmail.com>,
	"Köry Maincent" <kory.maincent@bootlin.com>,
	"Simon Horman" <horms@kernel.org>,
	"Romain Gantois" <romain.gantois@bootlin.com>,
	"Antoine Tenart" <atenart@kernel.org>,
	"Marek Behún" <kabel@kernel.org>,
	"Sean Anderson" <sean.anderson@linux.dev>,
	"Bjørn Mork" <bjorn@mork.no>
Subject: [PATCH net-next v3 0/2] net: phy: sfp: Add single-byte SMBus SFP access
Date: Fri, 14 Mar 2025 17:23:16 +0100	[thread overview]
Message-ID: <20250314162319.516163-1-maxime.chevallier@bootlin.com> (raw)

Hello everyone,

This is V3 for the single-byte SMBus support for SFP cages as well as
embedded PHYs accessed over mdio-i2c.

Discussions on the previous iteration raised some questions on the
ordering of the accesses (from Andrew), after further testing it still
seems correct to me, I can properly read EEPROMS and by hacking around,
read 16 bits values (although this is disabled anyways).

This series compared to V2 changes the approach used internally to use
the degraded mode (no hwmon), by setting the i2c_block_size to 1 and
re-using the logic already in place to deal with that.

As we now have 2 scenarios for 1-byte accesses (broken EEPROM that needs
to be accessed 1 byte at a time or single-byte SMBus), I've updated some
of the in-place error logs. Users should still be plenty warned and
made aware of the situation.

I also renamed the internal helpers to reflect that we use single-byte
accesses.

The rest was left untouched (I didn't have time yet to test around with
Rollball for example or 16-bits SMBus).

As I reworked patch 1, I dropped Sean's tested-by :(

V2 : https://lore.kernel.org/netdev/20250225112043.419189-1-maxime.chevallier@bootlin.com/
V1 : https://lore.kernel.org/netdev/20250223172848.1098621-1-maxime.chevallier@bootlin.com/#t

@Maintainers: I already have a few series queued for review, let me know
if you prefer that I resend that one at a later time.

Maxime

Maxime Chevallier (2):
  net: phy: sfp: Add support for SMBus module access
  net: mdio: mdio-i2c: Add support for single-byte SMBus operations

 drivers/net/mdio/mdio-i2c.c | 79 ++++++++++++++++++++++++++++++++++-
 drivers/net/phy/sfp.c       | 82 +++++++++++++++++++++++++++++++++----
 2 files changed, 152 insertions(+), 9 deletions(-)

-- 
2.48.1


             reply	other threads:[~2025-03-14 16:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-14 16:23 Maxime Chevallier [this message]
2025-03-14 16:23 ` [PATCH net-next v3 1/2] net: phy: sfp: Add support for SMBus module access Maxime Chevallier
2025-03-21 17:50   ` Paolo Abeni
2025-03-21 18:00     ` Maxime Chevallier
2025-03-14 16:23 ` [PATCH net-next v3 2/2] net: mdio: mdio-i2c: Add support for single-byte SMBus operations Maxime Chevallier
2025-03-21 17:53   ` Paolo Abeni
2025-03-21 18:02     ` Maxime Chevallier
2025-03-21 18:15   ` Maxime Chevallier
2025-03-17 21:34 ` [PATCH net-next v3 0/2] net: phy: sfp: Add single-byte SMBus SFP access Andrew Lunn
2025-03-18  8:25   ` Maxime Chevallier
2025-03-18 12:21     ` Andrew Lunn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250314162319.516163-1-maxime.chevallier@bootlin.com \
    --to=maxime.chevallier@bootlin.com \
    --cc=andrew@lunn.ch \
    --cc=atenart@kernel.org \
    --cc=bjorn@mork.no \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=hkallweit1@gmail.com \
    --cc=horms@kernel.org \
    --cc=kabel@kernel.org \
    --cc=kory.maincent@bootlin.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=romain.gantois@bootlin.com \
    --cc=sean.anderson@linux.dev \
    --cc=thomas.petazzoni@bootlin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox