mirror of
https://github.com/torvalds/linux.git
synced 2024-11-15 00:21:59 +00:00
c259acab83
The ability to read the PHC (Physical Hardware Clock) alongside multiple system clocks is currently dependent on the specific hardware architecture. This limitation restricts the use of PTP_SYS_OFFSET_PRECISE to certain hardware configurations. The generic soultion which would work across all architectures is to read the PHC along with the latency to perform PHC-read as offered by PTP_SYS_OFFSET_EXTENDED which provides pre and post timestamps. However, these timestamps are currently limited to the CLOCK_REALTIME timebase. Since CLOCK_REALTIME is affected by NTP (or similar time synchronization services), it can experience significant jumps forward or backward. This hinders the precise latency measurements that PTP_SYS_OFFSET_EXTENDED is designed to provide. This problem could be addressed by supporting MONOTONIC_RAW timestamps within PTP_SYS_OFFSET_EXTENDED. Unlike CLOCK_REALTIME or CLOCK_MONOTONIC, the MONOTONIC_RAW timebase is unaffected by NTP adjustments. This enhancement can be implemented by utilizing one of the three reserved words within the PTP_SYS_OFFSET_EXTENDED struct to pass the clock-id for timestamps. The current behavior aligns with clock-id for CLOCK_REALTIME timebase (value of 0), ensuring backward compatibility of the UAPI. Signed-off-by: Mahesh Bandewar <maheshb@google.com> Signed-off-by: Vadim Fedorenko <vadfed@meta.com> Signed-off-by: David S. Miller <davem@davemloft.net> |
||
---|---|---|
.. | ||
Kconfig | ||
Makefile | ||
ptp_chardev.c | ||
ptp_clock.c | ||
ptp_clockmatrix.c | ||
ptp_clockmatrix.h | ||
ptp_dfl_tod.c | ||
ptp_dte.c | ||
ptp_fc3.c | ||
ptp_fc3.h | ||
ptp_idt82p33.c | ||
ptp_idt82p33.h | ||
ptp_ines.c | ||
ptp_kvm_arm.c | ||
ptp_kvm_common.c | ||
ptp_kvm_x86.c | ||
ptp_mock.c | ||
ptp_ocp.c | ||
ptp_pch.c | ||
ptp_private.h | ||
ptp_qoriq_debugfs.c | ||
ptp_qoriq.c | ||
ptp_sysfs.c | ||
ptp_vclock.c | ||
ptp_vmw.c |