sys_macosx: add option to run chronyd as real-time process

Adds option -P to chronyd on MacOS X which can be used to enable the
thread time constraint scheduling policy. This near real-time scheduling
policy removes a 1usec bias from the 'System time' offset.
This commit is contained in:
Bryan Christianson
2015-08-25 08:32:14 +12:00
committed by Miroslav Lichvar
parent 5039f959e0
commit b9cfdaf666
5 changed files with 78 additions and 13 deletions

2
sys.c
View File

@@ -126,6 +126,8 @@ void SYS_SetScheduler(int SchedPriority)
{
#if defined(LINUX) && defined(HAVE_SCHED_SETSCHEDULER)
SYS_Linux_SetScheduler(SchedPriority);
#elif defined(MACOSX)
SYS_MacOSX_SetScheduler(SchedPriority);
#else
LOG_FATAL(LOGF_Sys, "scheduler priority setting not supported");
#endif