All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1 0/2] Add PTP support for TJA1103
@ 2021-04-28 12:30 Radu Pirea (NXP OSS)
  2021-04-28 12:30 ` [PATCH v1 1/2] ptp: ptp_clock: make scaled_ppm_to_ppb static inline Radu Pirea (NXP OSS)
  2021-04-28 12:30 ` [PATCH v1 2/2] phy: nxp-c45-tja11xx: add timestamping support Radu Pirea (NXP OSS)
  0 siblings, 2 replies; 8+ messages in thread
From: Radu Pirea (NXP OSS) @ 2021-04-28 12:30 UTC (permalink / raw)
  To: andrew, hkallweit1, linux, davem, kuba, richardcochran
  Cc: netdev, linux-kernel, Radu Pirea (NXP OSS)

Hi,

This is the PTP support for TJA1103.
The RX timestamp is found in the reserved2 field of the PTP package.
The TX timestamp has to be read from the phy registers. Reading of the
timestamp works with interrupts or with polling(that starts when
.nxp_c45_txtstamp is called).
The implementation of .adjtime is done by read modify write because there
is no way to atomically add/subtract a constant from the clock value.

I've moved scaled_ppm_to_ppb function from ptp_clock.c to
ptp_clock_kernel.h in  order to be able to build the driver without
PTP_1588_CLOCK=y.

Radu P.

Radu Pirea (NXP OSS) (2):
  ptp: ptp_clock: make scaled_ppm_to_ppb static inline
  phy: nxp-c45-tja11xx: add timestamping support

 drivers/net/phy/nxp-c45-tja11xx.c | 505 +++++++++++++++++++++++++++++-
 drivers/ptp/ptp_clock.c           |  21 --
 include/linux/ptp_clock_kernel.h  |  34 +-
 3 files changed, 530 insertions(+), 30 deletions(-)

-- 
2.31.1


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

end of thread, other threads:[~2021-04-29 15:12 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-28 12:30 [PATCH v1 0/2] Add PTP support for TJA1103 Radu Pirea (NXP OSS)
2021-04-28 12:30 ` [PATCH v1 1/2] ptp: ptp_clock: make scaled_ppm_to_ppb static inline Radu Pirea (NXP OSS)
2021-04-28 12:30 ` [PATCH v1 2/2] phy: nxp-c45-tja11xx: add timestamping support Radu Pirea (NXP OSS)
2021-04-28 16:07   ` kernel test robot
2021-04-28 16:07     ` kernel test robot
2021-04-28 16:07   ` [PATCH] phy: nxp-c45-tja11xx: fix boolconv.cocci warnings kernel test robot
2021-04-28 16:07     ` kernel test robot
2021-04-29 15:11   ` [PATCH v1 2/2] phy: nxp-c45-tja11xx: add timestamping support Richard Cochran

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.