pps/ptp: Allow PHC devices to adjust PPS events for known delay
authorBen Hutchings <bhutchings@solarflare.com>
Mon, 3 Sep 2012 10:34:58 +0000 (11:34 +0100)
committerBen Hutchings <bhutchings@solarflare.com>
Fri, 7 Sep 2012 20:13:28 +0000 (21:13 +0100)
commit220a60a425146b0e37998cc0b3082f0541aad866
tree44e48c4489f8e354d17269d41db19d015d9b95fe
parentef2c7d7b59708d54213c7556a82d14de9a7e4475
pps/ptp: Allow PHC devices to adjust PPS events for known delay

Initial version by Stuart Hodgson <smhodgson@solarflare.com>

Some PHC device drivers may deliver PPS events with a significant
and variable delay, but still be able to measure precisely what
that delay is.

Add a pps_sub_ts() function for subtracting a delay from the
timestamp(s) in a PPS event, and a PTP event type (PTP_CLOCK_PPSUSR)
for which the caller provides a complete PPS event.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
drivers/ptp/ptp_clock.c
include/linux/pps_kernel.h
include/linux/ptp_clock_kernel.h