Re: [PATCH] i386: Selectable Frequency of the Timer Interrupt

Benjamin LaHaise
2005-07-13T19:54:43Z

On Wed, Jul 13, 2005 at 09:41:15PM +0200, Vojtech Pavlik wrote:
> The RTC historically used to have a lower quality (cheaper) crystal than
> the 14.318 MHz crystal used for everything else. But with the spread
> spectrum modulation of frequency, the PIT may finally be worse to
> consider the RTC again.

32.768kHz crystals are pretty much standard for use in digital clocks.
Checking an electronics catalogue shows a fairly reasonable -60ppm to
+30ppm rating over the operating temperature range (implying the device
is tuned for 20C room temperature).

> Another BIG problem with RTC is that it doesn't allow reading its
> internal counter like the PIT does, making TSC interpolation even harder.

That's one thing I truely dislike about the current timer code. If we
could program the RTC interrupt to come into the system as an NMI (iirc
oprofile already has code to do this), we could get much better TSC
interpolation since we would be sampling the TSC at a much smaller, less
variable offset, which can only be a good thing.

-ben
--
"Time is what keeps everything from happening all at once." -- John Wheeler