Skip to content

The DSA TX timestamping situation

Vladimir Oltean netdev 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest2 patches 1 replyIn review
  2. v12 patches 2 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2gianfar: Fix TX timestamping with a stacked DSA driverdrivers/net/ethernet/freescale/gianfar.c+7 -30 replies
2/2net: dsa: Deny PTP on master if switch supports itnet/dsa/master.c+30 -00 replies

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchRichard Cochran
1/2A-b
2/2A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 net 0/2] The DSA TX timestamping situation

This series is the moral v2 of "[PATCH net] net: dsa: sja1105: Fix double delivery of TX timestamps to socket error queue" [0] which did not manage to convince public opinion (actually it didn't convince me neither).

This fixes PTP timestamping on one particular board, where the DSA switch is sja1105 and the master is gianfar. Unfortunately there is no way to make the fix more general without committing logical
inaccuracies: the SKBTX_IN_PROGRESS flag does serve a purpose, even if the sja1105 driver is not using it now: it prevents delivering a SW timestamp to the app socket when the HW timestamp will be provided. So not setting this flag (the approach from v1) might create avoidable complications in the future (not to mention that there isn't any satisfactory explanation on why that would be the correct solution).

So the goal of this change set is to create a more strict framework for DSA master devices when attached to PTP switches, and to fix the first master driver that is overstepping its duties and is delivering unsolicited TX timestamps.

[0]: https://www.spinics.net/lists/netdev/msg619699.html

Vladimir Oltean (2):
gianfar: Fix TX timestamping with a stacked DSA driver
net: dsa: Deny PTP on master if switch supports it

 drivers/net/ethernet/freescale/gianfar.c | 10 +++++---
 net/dsa/master.c                         | 30 ++++++++++++++++++++++++
 2 files changed, 37 insertions(+), 3 deletions(-)
Signature · 1 line
2.17.1