Re: [patch 8/9] Add time_update_mt_guess()

2007-02-01 Thread Jiri Bohac
On Thu, Feb 01, 2007 at 12:28:50PM +0100, Andi Kleen wrote: > On Thursday 01 February 2007 11:00, [EMAIL PROTECTED] wrote: > > +inline u64 mt_to_nsec(u64 mt) > > +{ > > + u64 ret; > > + ret = ((mt & 0xff) * vxtime.mt_q) >> 32; > > + mt >>= 24; > > + ret += ((mt & 0xff) * vxtime.mt_

Re: [patch 8/9] Add time_update_mt_guess()

2007-02-01 Thread Andi Kleen
On Thursday 01 February 2007 11:00, [EMAIL PROTECTED] wrote: > Index: linux-2.6.20-rc5/arch/x86_64/kernel/apic.c > === > --- linux-2.6.20-rc5.orig/arch/x86_64/kernel/apic.c > +++ linux-2.6.20-rc5/arch/x86_64/kernel/apic.c > @@ -63,6 +

[patch 8/9] Add time_update_mt_guess()

2007-02-01 Thread jbohac
time_update_mt_guess() is the core of the TSC->MT approximation magic. Called periodically from the LAPIC timer interrupt handler, it fine-tunes all the per-CPU offsets and ratios needed by guess_mt() to approximate the MT using any processor's TSC. We also need to update these from the cpufreq