[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230314120254.76f8360c@kmaincent-XPS-13-7390>
Date: Tue, 14 Mar 2023 12:02:54 +0100
From: Köry Maincent <kory.maincent@...tlin.com>
To: Oleksij Rempel <o.rempel@...gutronix.de>
Cc: Vladimir Oltean <vladimir.oltean@....com>,
Horatiu Vultur <horatiu.vultur@...rochip.com>,
Michael Walle <michael@...le.cc>, Andrew Lunn <andrew@...n.ch>,
Florian Fainelli <f.fainelli@...il.com>,
Heiner Kallweit <hkallweit1@...il.com>, netdev@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org, linux-omap@...r.kernel.org,
Maxime Chevallier <maxime.chevallier@...tlin.com>,
Richard Cochran <richardcochran@...il.com>,
thomas.petazzoni@...tlin.com, Russell King <linux@...linux.org.uk>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Jonathan Corbet <corbet@....net>,
Jay Vosburgh <j.vosburgh@...il.com>,
Veaceslav Falico <vfalico@...il.com>,
Andy Gospodarek <andy@...yhouse.net>,
Claudiu Manoil <claudiu.manoil@....com>,
Alexandre Belloni <alexandre.belloni@...tlin.com>,
UNGLinuxDriver@...rochip.com, Minghao Chi <chi.minghao@....com.cn>,
Jie Wang <wangjie125@...wei.com>,
Oleksij Rempel <linux@...pel-privat.de>,
Sean Anderson <sean.anderson@...o.com>,
"Gustavo A. R. Silva" <gustavoars@...nel.org>,
Wolfram Sang <wsa+renesas@...g-engineering.com>,
Alexander Lobakin <alexandr.lobakin@...el.com>,
Marco Bonelli <marco@...eim.net>
Subject: Re: [PATCH v3 3/5] net: Let the active time stamping layer be
selectable.
On Mon, 13 Mar 2023 09:40:59 +0100
Oleksij Rempel <o.rempel@...gutronix.de> wrote:
> > But, as you point out, with Köry's/Richard's proposal, the MAC driver
> > will be bypassed when the selected timestamping layer is the PHY, and
> > that's a problem currently.
> >
> > May I suggest the following? There was another RFC which proposed the
> > introduction of a netdev notifier when timestamping is turned on/off:
> > https://lore.kernel.org/netdev/20220317225035.3475538-1-vladimir.oltean@nxp.com/
> >
> > If we have a notifier, then we can make switch drivers do things
> > differently. They can activate timestamping per se in the timestamping
> > NDO (which is only called when the MAC is the active timestamping layer),
> > and they can activate PTP traps in the netdev notifier (which is called
> > any time a timestamping status change takes place - the notifier info
> > should contain details about which net_device and timestamping layer
> > this is, for example).
> >
> > It's just a proposal of how to create an alternative notification path
> > that doesn't disturb the goals of this patch set.
I will take a look at your patch but indeed adding a timestamp notifier could
be a good idea.
> To make things even more complicated - I have a project where the DSA master
> should be used for time stamping. Due to board specific limitations, we
> are forced to use FEC PHC instead of dsa KSZ switch PHC. So, it is not
> a choice between MAC and PHY, it is more the MAC before MAC and PHY.
> PTP sync in this case will have more jitter, but it still good enough
> for this project.
> Currently I use quick hack to do so, but mainlinamble solution working for
> most use cases will be nice.
In this case it is not a PHY/MAC PTP choice anymore but more a device
PTP choice which bring a lot more of complexity. Or maybe we could simply add a
"switch" timestamp layer later on. As Andrew said we will maybe increase the
number of timestamp layers in the future.
Regards,
Köry
Powered by blists - more mailing lists