From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: netdev@vger.kernel.org
Cc: Andrew Lunn <andrew@lunn.ch>, Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Richard Cochran <richardcochran@gmail.com>,
Vladimir Oltean <olteanv@gmail.com>
Subject: [PATCH RFC net-next 00/20] Marvell PTP stuffs
Date: Thu, 18 Sep 2025 18:38:15 +0100 [thread overview]
Message-ID: <aMxDh17knIDhJany@shell.armlinux.org.uk> (raw)
Not for merging, and, yes, it's more than 15 patches.
As the merge window is approaching, I thought I would share my current
state with the Marvell PTP library. I don't consider this ready for
merging yet, as I still have decisions to make on the structure for
multi-port setups such as DSA. 88E6165 support is also likely broken.
You will have noticed I've pushed out some patches cleaning up stuff
in the mv88e6xxx driver, and also making it easier for PTP clock
drivers to clean up when unregistering.
This series contains potentially another independent patch, adding
the ability to get the hwtstamp configuration from a MII timestamper,
although of course, the only known user right now is the Marvell PHY
PTP support (specifically 88E1510) in this series.
One of the things I don't like about the conversion for mv88e6xxx is
the "drop the old code, plug in the new". The hwtstamp.c changes
are split up, but they result in stuff becoming non-functional during
the transition.
The only thing I can think of doing to solve that is to forward the
hwtstamp_set() call to both implementations, and then convert the
tx side, rx side, and remove the old.
I've been running this for about 10 days (with reboots) between two
machines, one using the PHY side as the GM, and the other using
DSA as the slave. All seems happy, no timeouts on getting the
timestamps for the Sync or Delay_Req packets:
ptp4l[3032.775]: master offset -60 s2 freq -3984 path delay 11144
ptp4l[3033.775]: master offset -16 s2 freq -3958 path delay 11144
ptp4l[3034.775]: master offset 45 s2 freq -3901 path delay 11144
ptp4l[3035.775]: master offset 203 s2 freq -3730 path delay 11144
ptp4l[3036.775]: master offset 115 s2 freq -3757 path delay 11144
ptp4l[3037.775]: master offset -186 s2 freq -4023 path delay 11144
ptp4l[3038.775]: master offset -244 s2 freq -4137 path delay 11144
ptp4l[3039.775]: master offset -122 s2 freq -4088 path delay 11137
I've tested both L2 and L4 configurations. Whether I get these to
a point that I can post some of them for real next week is uncertain,
and I certainly won't post them unless I feel they are ready -
especially not before I'm happy with the library.
drivers/net/dsa/mv88e6xxx/Kconfig | 1 +
drivers/net/dsa/mv88e6xxx/chip.c | 10 +
drivers/net/dsa/mv88e6xxx/chip.h | 63 +--
drivers/net/dsa/mv88e6xxx/hwtstamp.c | 664 ++++++++++++------------------
drivers/net/dsa/mv88e6xxx/hwtstamp.h | 26 +-
drivers/net/dsa/mv88e6xxx/ptp.c | 527 +++++++++---------------
drivers/net/dsa/mv88e6xxx/ptp.h | 30 +-
drivers/net/phy/Kconfig | 13 +
drivers/net/phy/Makefile | 1 +
drivers/net/phy/marvell.c | 15 +-
drivers/net/phy/marvell_ptp.c | 369 +++++++++++++++++
drivers/net/phy/marvell_ptp.h | 17 +
drivers/net/phy/phy.c | 3 +
drivers/ptp/Kconfig | 4 +
drivers/ptp/Makefile | 2 +
drivers/ptp/ptp_marvell_tai.c | 445 ++++++++++++++++++++
drivers/ptp/ptp_marvell_ts.c | 778 +++++++++++++++++++++++++++++++++++
include/linux/marvell_ptp.h | 159 +++++++
include/linux/mii_timestamper.h | 3 +
19 files changed, 2318 insertions(+), 812 deletions(-)
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
next reply other threads:[~2025-09-18 17:38 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-18 17:38 Russell King (Oracle) [this message]
2025-09-18 17:38 ` [PATCH RFC net-next 01/20] ptp: marvell: add core support for Marvell PTP Russell King
2025-09-18 17:39 ` [PATCH RFC net-next 02/20] net: phy: add hwtstamp_get() method for mii timestampers Russell King (Oracle)
2025-09-18 20:38 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 03/20] net: phy: marvell: add PHY PTP support Russell King
2025-09-18 20:12 ` Andrew Lunn
2025-09-18 20:33 ` Russell King (Oracle)
2025-09-19 1:47 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 04/20] net: dsa: mv88e6xxx: split out set_ptp_cpu_port() code Russell King (Oracle)
2025-09-18 20:46 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 05/20] net: dsa: mv88e6xxx: convert PTP clock_read() method to take chip Russell King (Oracle)
2025-09-18 20:13 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 06/20] net: dsa: mv88e6xxx: convert PTP ptp_verify() " Russell King (Oracle)
2025-09-18 20:48 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 07/20] net: dsa: mv88e6xxx: convert PTP ptp_enable() " Russell King (Oracle)
2025-09-18 20:48 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 08/20] net: dsa: mv88e6xxx: convert mv88e6xxx_hwtstamp_work() " Russell King (Oracle)
2025-09-18 20:51 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 09/20] net: dsa: mv88e6xxx: always verify PTP_PF_NONE Russell King (Oracle)
2025-09-18 20:14 ` Andrew Lunn
2025-09-18 17:39 ` [PATCH RFC net-next 10/20] net: dsa: mv88e6xxx: only support EXTTS for pins Russell King (Oracle)
2025-09-19 11:29 ` Vadim Fedorenko
2025-09-19 13:50 ` Russell King (Oracle)
2025-09-18 17:39 ` [PATCH RFC net-next 11/20] net: dsa: mv88e6xxx: split out EXTTS pin setup Russell King (Oracle)
2025-09-18 20:59 ` Andrew Lunn
2025-09-28 9:51 ` Russell King (Oracle)
2025-09-18 17:39 ` [PATCH RFC net-next 12/20] net: dsa: mv88e6xxx: move EXTTS flag validation and pin lookup Russell King (Oracle)
2025-09-18 17:39 ` [PATCH RFC net-next 13/20] net: dsa: mv88e6xxx: convert to marvell TAI Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 14/20] net: dsa: mv88e6xxx: convert mv88e6xxx_cc_coeffs to marvell_tai_param Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 15/20] net: dsa: mv88e6xxx: allow generic core to configure global regs Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 16/20] net: dsa: mv88e6xxx: add beginnings of generic Marvell PTP ts layer Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 17/20] net: dsa: mv88e6xxx: switch tx timestamping to core Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 18/20] net: dsa: mv88e6xxx: switch rx " Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 19/20] net: dsa: mv88e6xxx: switch hwtstamp config to core XXX Fix 6165 Russell King (Oracle)
2025-09-18 17:40 ` [PATCH RFC net-next 20/20] net: dsa: mv88e6xxx: add ptp irq support Russell King (Oracle)
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=aMxDh17knIDhJany@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=andrew+netdev@lunn.ch \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.com \
--cc=pabeni@redhat.com \
--cc=richardcochran@gmail.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).