public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 net-next 0/3] Implement PTP support in netdevsim
@ 2026-02-25 15:38 Maciek Machnikowski
  2026-02-25 15:38 ` [PATCH v3 net-next 1/3] ptp_mock: Expose ptp_clock_info to external drivers Maciek Machnikowski
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Maciek Machnikowski @ 2026-02-25 15:38 UTC (permalink / raw)
  To: netdev
  Cc: kuba, maciek, richardcochran, milena.olech, willemdebruijn.kernel,
	andrew, vadim.fedorenko, horms

This patchset adds support to the PTP HW timestamping emulation in the
netdevsim. It uses existing binding between netdevsim and ptp_mock
driver to generate transmit and receive timestamps.

It also adds the selftest to verify the hw timestamping functionality
running over netdevsim.

v2:
- Added selftest/net/ptp.sh
- Modified ptp_mock to use spin_lock_bh
- Populate ethtool defaults using ethtool_op_get_ts_info

v3:
- Fixed shellcheck issues in the selftest/net/ptp.sh
- Added selftest/net/ptp.sh to the selftest/net/Makefile
- Modified ptp_mock to use spin_lock_irqsave

Maciek Machnikowski (3):
  ptp_mock: Expose ptp_clock_info to external drivers
  netdevsim: Implement basic ptp support
  selftests:net: Implement ptp4l sync test using netdevsim

 drivers/net/netdevsim/ethtool.c      |  11 +++
 drivers/net/netdevsim/netdev.c       |  90 +++++++++++++++++++++++
 drivers/net/netdevsim/netdevsim.h    |   1 +
 drivers/ptp/ptp_mock.c               |  22 ++++--
 include/linux/ptp_mock.h             |   5 ++
 tools/testing/selftests/net/Makefile |   1 +
 tools/testing/selftests/net/ptp.sh   | 105 +++++++++++++++++++++++++++
 7 files changed, 227 insertions(+), 8 deletions(-)
 create mode 100755 tools/testing/selftests/net/ptp.sh

-- 
2.53.0


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2026-03-04 15:48 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-25 15:38 [PATCH v3 net-next 0/3] Implement PTP support in netdevsim Maciek Machnikowski
2026-02-25 15:38 ` [PATCH v3 net-next 1/3] ptp_mock: Expose ptp_clock_info to external drivers Maciek Machnikowski
2026-02-26  1:57   ` Jakub Kicinski
2026-02-25 15:38 ` [PATCH v3 net-next 2/3] netdevsim: Implement basic ptp support Maciek Machnikowski
2026-02-25 16:32   ` Sai Krishna Gajula
2026-02-26  2:01   ` Jakub Kicinski
2026-03-04 12:41     ` Maciek Machnikowski
2026-03-04 15:19   ` Willem de Bruijn
2026-03-04 15:48     ` Willem de Bruijn
2026-02-25 15:38 ` [PATCH v3 net-next 3/3] selftests:net: Implement ptp4l sync test using netdevsim Maciek Machnikowski
2026-02-25 16:45   ` Sai Krishna Gajula
2026-03-04 12:44     ` Maciek Machnikowski
2026-02-26  2:41   ` Jakub Kicinski
2026-03-04 15:21   ` Willem de Bruijn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox