APIC timers in SMP [ QUESTION ]

Hugo Varotto (hvarotto@cs.pitt.edu)
Fri, 21 May 1999 17:19:34 -0400


Dear kernel developers,

Could somebody please route me to a place that explains how to program
the timers of the local APICS ? I found the routine "setup_APIC_timer"
in the file arch/i396/kernel/smp.c and I'm not absolutely sure if I
understand their behaviour ( in particular, there's a comment before the
definition of the RDTSC macro that says:

* The APIC timer is not exactly sync with the external timer chip, it
* closely follows bus clocks.

I'd like to be able to change the timer resolution ( sometimes to 10 ms,
sometimes less ), but I still don't get the relation between timer ticks
and the PCI bus clocks.
In the routine calibrate_APIC_clock() in the same file it seems that the
kernel is reading some info from the APIC ( in bus clocks ) and some
other info using RDTSC, and doing a comparison/relation between them.
I'd like to understand it.

If some kind soul could give me some advice, I'll appreciate it ( I
don;t want to bother, so if there's a website with the desired
information, that will be great ). I'm working with an Intel SMP machine
( dual Pentium Pro ) and kernel 2.2.1 ( yes, I know it's an old version,
but i think that this stuff hasn't changed a lot lately ).

If I'm saying something completely stupid regarding the timers, feel
free to correct me.

Thanks in advance

Hugo

--
Hugo Varotto
Computer Science Dept.
University of Pittsburgh
hvarotto@cs.pitt.edu

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