From: Maxime Chevallier <maxime.chevallier@bootlin.com>
To: davem@davemloft.net, Rob Herring <robh+dt@kernel.org>
Cc: Maxime Chevallier <maxime.chevallier@bootlin.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
devicetree@vger.kernel.org, thomas.petazzoni@bootlin.com,
Andrew Lunn <andrew@lunn.ch>,
Florian Fainelli <f.fainelli@gmail.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
linux-arm-kernel@lists.infradead.org,
Richard Cochran <richardcochran@gmail.com>,
Horatiu.Vultur@microchip.com, Allan.Nielsen@microchip.com,
UNGLinuxDriver@microchip.com
Subject: [PATCH net-next 0/6] net: Introduce Ethernet Inband Extensions
Date: Thu, 19 May 2022 15:56:41 +0200 [thread overview]
Message-ID: <20220519135647.465653-1-maxime.chevallier@bootlin.com> (raw)
Hello everyone,
This series introduces support for Ethernet in-band extensions, a
mechanism proposed by Cisco as part of the USXGMII spec.
The idea is to leverage the 7 bytes preamble to convey meaningful data,
in what's called an "extension".
This series adds the QUSGMII mode, which is a quad variant of the
USXGMII standard, and adds its support in the lan966x driver. In
QUSGMII, extensions can be used.
The only extension support thus far is the PCH mode, a way to convey
part of a timestamp into the ethernet preamble. That's a pretty
straightfoward extension, documented in the Cisco spec. Other extensions
can exist, each being identified by a 2 bits code in the preamble,
parsed by the hardware.
We therefore need an API to synchronise which mode is supported by a
given PHY, then a way to enable it in the PHY, from the MAC's control.
This is done through a new phy_driver callback, .inband_ext_config(),
that the MAC driver will call to ask a PHY driver to enable a given
extension.
The PCH mode that is added in this series is used to offload a bit
the MDIO bus when doing PHY-side timestamping, by conveying the nanoseconds
part of the timestamp into the preamble. The MAC driver then extracts
the timestamp (using lan966x's IFH mechanism), puts the nanosecond part
in the SKB. The RX deferred timestamping then asks the PHY for the rest
of the timestamp.
Other modes exists, such as Microchip's MCH mode, but this series only
include PCH since it's simple enough and keeps the code reviewable.
Thanks,
Maxime
Maxime Chevallier (6):
net: phy: Introduce QUSGMII PHY mode
dt-bindings: net: ethernet-controller: add QUSGMII mode
net: lan966x: Add QUSGMII support for lan966x
net: phy: Add support for inband extensions
net: lan966x: Allow using PCH extension for PTP
net: phy: micrel: Add QUSGMII support and PCH extension
.../bindings/net/ethernet-controller.yaml | 1 +
Documentation/networking/phy.rst | 9 ++
.../ethernet/microchip/lan966x/lan966x_main.c | 14 +--
.../ethernet/microchip/lan966x/lan966x_main.h | 6 ++
.../microchip/lan966x/lan966x_phylink.c | 9 +-
.../ethernet/microchip/lan966x/lan966x_port.c | 33 ++++--
.../ethernet/microchip/lan966x/lan966x_ptp.c | 93 +++++++++++++++-
.../ethernet/microchip/lan966x/lan966x_regs.h | 72 +++++++++++++
drivers/net/phy/micrel.c | 102 ++++++++++++++++--
drivers/net/phy/phy.c | 68 ++++++++++++
drivers/net/phy/phylink.c | 3 +
include/linux/phy.h | 28 ++++-
12 files changed, 413 insertions(+), 25 deletions(-)
--
2.36.1
next reply other threads:[~2022-05-19 13:57 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-19 13:56 Maxime Chevallier [this message]
2022-05-19 13:56 ` [PATCH net-next 1/6] net: phy: Introduce QUSGMII PHY mode Maxime Chevallier
2022-05-19 13:56 ` [PATCH net-next 2/6] dt-bindings: net: ethernet-controller: add QUSGMII mode Maxime Chevallier
2022-06-01 21:10 ` Rob Herring
2022-05-19 13:56 ` [PATCH net-next 3/6] net: lan966x: Add QUSGMII support for lan966x Maxime Chevallier
2022-05-19 14:26 ` Russell King (Oracle)
2022-07-27 13:48 ` Maxime Chevallier
2022-05-19 13:56 ` [PATCH net-next 4/6] net: phy: Add support for inband extensions Maxime Chevallier
2022-05-19 14:10 ` Andrew Lunn
2022-05-19 14:28 ` Andrew Lunn
2022-05-19 13:56 ` [PATCH net-next 5/6] net: lan966x: Allow using PCH extension for PTP Maxime Chevallier
2022-05-19 13:56 ` [PATCH net-next 6/6] net: phy: micrel: Add QUSGMII support and PCH extension Maxime Chevallier
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=20220519135647.465653-1-maxime.chevallier@bootlin.com \
--to=maxime.chevallier@bootlin.com \
--cc=Allan.Nielsen@microchip.com \
--cc=Horatiu.Vultur@microchip.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=f.fainelli@gmail.com \
--cc=hkallweit1@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=richardcochran@gmail.com \
--cc=robh+dt@kernel.org \
--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;
as well as URLs for NNTP newsgroup(s).