Re: [PATCH] Add an offset in the cyc2ns computation to fix sched_clock jumps

From: Andreas Kleen
Date: Fri Mar 16 2007 - 14:36:36 EST


Am Fr 16.03.2007 19:30 schrieb Daniel Walker <dwalker@xxxxxxxxxx>:

> On Fri, 2007-03-16 at 19:14 +0100, Guillaume Chazarain wrote:
> > Hello,
> >
> > The scheduling problems I reported in the thread:
> > http://lkml.org/lkml/2007/3/3/128
> > are caused by the set_cyc2ns_scale() function called when the CPU
> > speed changes.
> > Changing the scale causes a warp in the value returned by
> > sched_clock().
> >
>
> Did you explain what the "werirdnes" was exactly? If not, could you?

I fixed this in my own version of the change by marking it unstable
during the transition
(concept stolen from Jiri's patch). Basically watch the notifiers for
before/after
and while the transition is in progress always ask for that underlying
monotonic ktime.

-Andi


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/