[lkml]   [2003]   [Aug]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRE: [PATCH][2.6][5/5]Support for HPET based timer

> -----Original Message-----
> From: Vojtech Pavlik []
> On Tue, Aug 19, 2003 at 06:28:40PM -0700, Pallipadi, Venkatesh wrote:
> >
> Yes, that is a problem. We could do some switchover from PIT
> to HPET (or
> from legacy to IOAPIC IRQs) after APICs are initialized,
> though I don't
> like the idea very much. Best would be to remove the dependence on the
> timer interrupt ticking so early. Or moving APIC detection earlier.

I agree. Depending both on PIT and HPET is not a clean solution. Also, I
am not that
comfortable with moving APIC detection earlier, as it can possibly break
things on different platforms. It will surely need lot more testing.

The way I got standard mode to work was by removing the dependency on
the early timer tick.
IIRC, the dependency is basically coming from Bogomips calculation and
also halt_works_ok
check. We can try and delay this until IOAPIC initialization.

> Well, the APIC should have quite a number of free pins, which
> means that
> the HPET shouldn't need to share an interrupt.

We interacted with some server folks, and they were of the opinion that
they may not be able to give a dedicated interrupt for HPET, as already
they have too many devices sitting on PCI these days. If they have to
give a dedicated IRQ for HPET, they may have to share some other
devices, which may result in performance loss. Another reason against it
was, if they give a dedicated IRQ and the OS decides against using HPET
(or older version of OS), then an IRQ will be needlessly wasted (kind of
a chicken and egg problem).

> Regarding lost and late
> delivered timer interrupts - that happens nevertheless with drivers
> disabling interrupts for a long time. The kernel timekeeping code can
> cope with that.

I agree that kernel can cope with the timer interrupt inaccuracy. But,
IMO, delays due to driver disabling the interrupts is more of an
exception case. With timer in shared interrupt, this will become more of
a common case.

Our thinking was to have a two phased approach. Have the legacy mode
enabled first. Make sure that the code around HPET interrupts is fully
optimized and is working fine. This mode is any way _required_ for
systems without IOAPIC and systems running UP kernels / with IOAPIC
disabled. Later we can add an option to use HPET standard mode.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:47    [W:0.049 / U:1.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site