org.freedesktop.timedate1.NTPSynchronized not signaled: rationale?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I'm developing an application for an embedded system that needs to
wait for proper NTP synchronization. systemd-timesyncd is running and
I can read NTPSynchronized from /org/freedesktop/timedate1 using
D-Bus. I read in the manual that this property is not signaled, and
that I need to do some weird magic with timerfd's
TFD_TIMER_CANCEL_ON_SET flag.

It works, but having the ECANCELLED on the read() means that something
somewhere did clock_settime(CLOCK_REALTIME, <...>), not especially
that I got a proper NTP synchronization. Then, I still need to query
NTPSynchronized after, and retry the timerfd thing if it didn't switch
to "true", which is still some kind of polling (but very unlikely,
sure).

As a result, I'm a bit curious, what was the rationale of not simply
signaling NTPSynchronized?

Thanks,
Etienne



[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux