Re: [patch] x86, tsc: fix SMI induced variation inquick_pit_calibrate()

From: Suresh Siddha
Date: Mon Jan 16 2012 - 22:59:48 EST


On Mon, 2012-01-16 at 17:30 -0800, Linus Torvalds wrote:
> On Mon, Jan 16, 2012 at 4:52 PM, Linus Torvalds
> <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
> >
> > Hmm. I get the feeling that we should remove that line entirely.
>
> Yeah, I really cannot come up with a single good reason to keep that
> line, and suspect that I was a bit loopy when I wrote it.
>
> So here's the suggested trivially updated patch. Does this work for people?

It does work. But it is taking almost 105 iterations or so to stabilize.
And if I boot the system in power-save mode (lowest p-state), it takes
almost 115 iterations to stabilize (close to the 25msec limit). This is
on the latest gen platform.

So I suspect we can either go back to 500ppm error tolerance:

if ((d1+d2) >= delta >> 10)
continue;

or increase the MAX_QUICK_PIT_MS bit more.

thanks,
suresh

--
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/