[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aPYKDkBaoWuxuNBl@horms.kernel.org>
Date: Mon, 20 Oct 2025 11:08:14 +0100
From: Simon Horman <horms@...nel.org>
To: Gerhard Engleder <gerhard@...leder-embedded.com>
Cc: netdev@...r.kernel.org, davem@...emloft.net, kuba@...nel.org,
edumazet@...gle.com, pabeni@...hat.com, andrew+netdev@...n.ch,
Vladimir Oltean <vladimir.oltean@....com>,
Vadim Fedorenko <vadim.fedorenko@...ux.dev>
Subject: Re: [PATCH net-next] tsnep: convert to ndo_hwtstamp_get() and
ndo_hwtstamp_set()
+ Vadim
On Fri, Oct 17, 2025 at 10:34:30PM +0200, Gerhard Engleder wrote:
> From: Vladimir Oltean <vladimir.oltean@....com>
>
> I took over this patch from Vladimir Oltean. The only change from my
> side is the adaption of the commit message. I hope I mentioned his work
> correctly in the tags.
>
> New timestamping API was introduced in commit 66f7223039c0 ("net: add
> NDOs for configuring hardware timestamping") from kernel v6.6.
>
> It is time to convert the tsnep driver to the new API, so that
> timestamping configuration can be removed from the ndo_eth_ioctl()
> path completely.
>
> The driver does not need the interface to be down in order for
> timestamping to be changed. Thus, the netif_running() restriction in
> tsnep_netdev_ioctl() is not migrated to the new API. There is no
> interaction with hardware registers for either operation, just a
> concurrency with the data path which is fine.
>
> After removing the PHY timestamping logic from tsnep_netdev_ioctl(),
> the rest is almost equivalent to phy_do_ioctl_running(), except for the
> return code on the !netif_running() condition: -EINVAL vs -ENODEV.
> Let's make the conversion to phy_do_ioctl_running() anyway, on the
> premise that a return code standardized tree-wide is less complex.
>
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>
> Signed-off-by: Gerhard Engleder <gerhard@...leder-embedded.com>
> Tested-by: Gerhard Engleder <gerhard@...leder-embedded.com>
Hi Gerhard, Vladimir, Vadim, all,
Recently Vadim has been working on converting a number of drivers to
use ndo_hwtstamp_get() and ndo_hwtstamp_set(). And this includes a
patch, rather similar to this one, for the tsnep [1].
I think it would be good to agree on the way forward here.
[1] https://lore.kernel.org/all/20251016152515.3510991-7-vadim.fedorenko@linux.dev/
...
Powered by blists - more mailing lists