Systemd/src/timesync
akochetkov 5f36e3d303 timesyncd: clear ADJ_MAXERROR to keep STA_UNSYNC cleared after jump adjust (#4626)
NTP use jump adjust if system has incorrect time read from RTC during boot.
It is desireble to update RTC time as soon as NTP set correct system time.
Sometimes kernel failed to update RTC due to STA_UNSYNC get set before RTC
update finised. In that case RTC time wouldn't be updated within long time.
The commit makes RTC updates stable.

When NTP do jump time adjust using ADJ_SETOFFSET it clears STA_UNSYNC flag.
If don't clear ADJ_MAXERROR, STA_UNSYNC will be set again by kernel within
1 second (by second_overflow() function). STA_UNSYNC flag prevent RTC updates
in kernel. Sometimes the kernel is able to update RTC withing 1 second,
but sometimes it falied.
2016-11-11 18:50:46 +01:00
..
.gitignore timesyncd: read server settings from a configuration file 2014-05-06 17:02:11 +02:00
Makefile timesyncd: read server settings from a configuration file 2014-05-06 17:02:11 +02:00
timesyncd-conf.c tree-wide: rename config_parse_many to …_nulstr 2016-09-16 10:32:03 -04:00
timesyncd-conf.h tree-wide: remove Emacs lines from all files 2016-02-10 13:41:57 +01:00
timesyncd-gperf.gperf timesyncd: beef up NTP server selection logic, and acquire NTP servers from DHCP 2014-08-12 19:48:24 +02:00
timesyncd-manager.c timesyncd: clear ADJ_MAXERROR to keep STA_UNSYNC cleared after jump adjust (#4626) 2016-11-11 18:50:46 +01:00
timesyncd-manager.h tree-wide: remove Emacs lines from all files 2016-02-10 13:41:57 +01:00
timesyncd-server.c tree-wide: use mfree more 2016-10-16 23:35:39 -04:00
timesyncd-server.h tree-wide: remove Emacs lines from all files 2016-02-10 13:41:57 +01:00
timesyncd.c clock-util: make clock_is_localtime() testable and add initial tests 2016-02-26 11:28:49 +01:00
timesyncd.conf.in Do not advertise .d snippets over main config file 2015-03-03 19:10:21 -05:00