Documentation/ptp: add the existing implementations.

The page described how to write a lower-half driver but did not say
which ones are in the tree.

- List the two lower-half drivers that register a PTP clock, the dummy
  driver and the Ethernet MAC of the STM32, with the option that
  enables each.
- Say that the clock of the STM32 driver is the PTP counter of the MAC,
  which is also the time base of the timestamps of the received
  packets, and not CLOCK_REALTIME.
- Say that both use the device number 0 by default and so cannot be
  registered at the same time.

Signed-off-by: Daniel P. Carvalho <danieloak@gmail.com>
Assisted-by: Claude:claude-sonnet-5
This commit is contained in:
Daniel P. Carvalho 2026-09-20 14:26:34 -03:00 • committed by Xiang Xiao
parent 9d861ca27e
commit bda32d3a74

View file

@ -496,6 +496,24 @@ that embeds a ``struct ptp_lowerhalf_s`` and provides the operations of
return ptp_clock_register(&priv->base, 500000, 0);
}
Existing Implementations
========================
The following lower-half drivers are available in the tree:
- ``drivers/timers/ptp_clock_dummy.c`` - The dummy driver described above,
enabled with ``CONFIG_PTP_CLOCK_DUMMY``. It is registered as ``/dev/ptp0``
at start-up.
- ``arch/arm/src/common/stm32/stm32_eth_m3m4_v1.c`` - The Ethernet MAC of the
STM32 (the legacy driver), registered with ``CONFIG_PTP_CLOCK`` and
``CONFIG_STM32_ETH_PTP`` as ``/dev/ptpN``, where N is the number of the
Ethernet interface. The clock is the PTP counter of the MAC. It is also the
time base of the hardware timestamps of the received packets, so those are
not values of ``CLOCK_REALTIME``.
Both use the device number 0 by default, so they cannot be registered at the
same time.
Integration with PTP Daemon
===========================