Le 10/02/2017 à 09:50, Miroslav Lichvar a écrit : > On Thu, Feb 09, 2017 at 06:26:25PM +0100, FUSTE Emmanuel wrote: >> Hello, >> >> Why timemaster launch phc2sys with the "-r" option ? >> >> It could be a complete misunderstanding of the doc/code on my side. >> But as the goal is to pass the measurement to ntpd via the ntpshm pseudo >> servo to let ntpd do the system clock adjustments and updates, "-r" is >> irrelevant and will step on/conflict with ntpd time adjustments/updates. > I can see why this could be confusing. > > The -r option enables synchronization of the system clock to the PTP > clock, but phc2sys doesn't care which servo is selected. With the > ntpshm servo, it's another process controlling the clock instead of > phc2sys. If timemaster started phc2sys without -r, it wouldn't try to > synchronize the system clock and the ntpshm servo wouldn't write any > samples for ntpd. > Ok, I dig deeper into the code and the magic is in the SERVO_UNLOCKED and zero return from ntpshm_sample(). And CLOCK_REALTIME is still registered as it is the clock against we are producing samples to be passed to ntpd/chrony.
Thank you ! Perhaps something like "With the ntpshm servo, system clock is not directly updated but samples against it are produced to allow another process to do it." Could be added after the second phrase of the "-r" description in the doc/man page. Emmanuel. ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Linuxptp-users mailing list Linuxptp-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-users