[LTP] [PATCH v3 4/4] syscalls/clock_adjtime: create clock_adjtime syscall tests

Rafael David Tinoco rafael.tinoco@linaro.org
Fri Mar 22 14:36:25 CET 2019


> On 22 Mar 2019, at 10:34, Cyril Hrubis <chrubis@suse.cz> wrote:
> 
> Hi!
>>> +	if (rval != TIME_OK)
>>> +		tst_brk(TBROK | TTERRNO, "unsynced clock or on-going leap???);
>> 
>> I choose to break test if rval > 0 mainly because it could still have
>> on-going leap operations, since clock_adjtime() is async, and also
>> because doing the test with an unsynced clock seems weird.
> 
> We should print the saved with timex_show() here and the rval at least.

Alright. v4 on its way.

> 
> It however it looks like kernel boots with STA_UNSYNC until NTP manges
> to sync the time and clears the flag but only if it manages to sync the
> clock.
> 
> See:
> 
> http://linuxelf.com/blog/2017/03/27/clock-status-unsync/
> 
> Which itself is an argument to run the test with unsynced clock, since
> not all environments have access to internet or ntp daemon running.

Valid point. I’ll allow rval being 5 then.

> 
> -- 
> Cyril Hrubis
> chrubis@suse.cz




More information about the ltp mailing list