All of lore.kernel.org
 help / color / mirror / Atom feed
* question on update_wall_time_one_tick()
@ 2004-10-07 20:13 Chris Friesen
  2004-10-07 20:32 ` question on update_wall_time_one_tick() -- doh! Chris Friesen
  0 siblings, 1 reply; 2+ messages in thread
From: Chris Friesen @ 2004-10-07 20:13 UTC (permalink / raw)
  To: Linux kernel


If we call update_wall_time_one_tick(), with a mode of ADJ_OFFSET_SINGLESHOT, 
the offset can be up to +/-512000 usec.

However, in update_wall_time_one_tick(), the offset adjustment each tick is 
limited to the range of -tickadj < x < tickadj.  On many current systems, 
tickadj is 1.  Thus, a large adjustment takes a *long* time.

While we are doing this offset change, if someone else requests another offset, 
it will totally overwrite any unapplied portion of the offset from the previous 
call:

	/* Changes by adjtime() do not take effect till next tick. */
	if (time_next_adjust != 0) {
		time_adjust = time_next_adjust;
		time_next_adjust = 0;
	}

Thus, doing an offset of +512000, immediately followed by an offset of -512000, 
will leave you with a significant negative offset.

Is this the desired behaviour?

Chris

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: question on update_wall_time_one_tick() -- doh!
  2004-10-07 20:13 question on update_wall_time_one_tick() Chris Friesen
@ 2004-10-07 20:32 ` Chris Friesen
  0 siblings, 0 replies; 2+ messages in thread
From: Chris Friesen @ 2004-10-07 20:32 UTC (permalink / raw)
  To: Linux kernel

Friesen, Christopher [CAR:VC21:EXCH] wrote:

> Thus, doing an offset of +512000, immediately followed by an offset of 
> -512000, will leave you with a significant negative offset.
> 
> Is this the desired behaviour?

Just realized this was the old adjtime() behaviour.  Wasn't clear from the 
adjtimex() man page.

Chris

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-10-07 20:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-10-07 20:13 question on update_wall_time_one_tick() Chris Friesen
2004-10-07 20:32 ` question on update_wall_time_one_tick() -- doh! Chris Friesen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.