Disable clockcheck and kernel leap with ntpshm servo.

Always disable the clock sanity check when the ntpshm servo is used,
because it doesn't know when or how is the clock adjusted. Disable also
the kernel leap option as the process controlling the clock is
responsible for setting the kernel flag.

Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
master
Miroslav Lichvar 2014-06-20 16:32:51 +02:00 committed by Richard Cochran
parent 97f72ceecc
commit 93b7807aad
2 changed files with 9 additions and 0 deletions

View File

@ -1324,6 +1324,11 @@ int main(int argc, char *argv[])
goto bad_usage;
}
if (node.servo_type == CLOCK_SERVO_NTPSHM) {
node.kernel_leap = 0;
node.sanity_freq_limit = 0;
}
print_set_progname(progname);
print_set_verbose(verbose);
print_set_syslog(use_syslog);

View File

@ -300,6 +300,10 @@ int main(int argc, char *argv[])
ds->flags & DDS_SLAVE_ONLY) {
ds->clockQuality.clockClass = 255;
}
if (cfg_settings.clock_servo == CLOCK_SERVO_NTPSHM) {
cfg_settings.dds.kernel_leap = 0;
cfg_settings.dds.sanity_freq_limit = 0;
}
print_set_progname(progname);
print_set_verbose(cfg_settings.verbose);