Re: [rfc][patch] API for timer hooks
From: Nish Aravamudan
Date: Tue Aug 16 2005 - 17:24:57 EST
On 8/16/05, Stas Sergeev <stsp@xxxxxxxx> wrote:
> Hello.
>
> john stultz wrote:
> > Interesting. Could you explain why the soft-timer interface doesn't<>
> > suffice?
> I'll try to explain why *I think*
> it doesn't suffice, please correct
> me if my assumptions are wrong.
>
> There are two (bad) things about the
> PC-Speaker driver:
> 1. It needs the higher interrupt frequency.
> Since there seem to be no API to change
> the timer frequency at runtime, the driver
> does this itself. Now I have googled out
> the thread
> [PATCH] i386: Selectable Frequency of the Timer Interrupt
> but it doesn't look like it ended up
> with some patch applied, or where is it?
This thread resulted in CONFIG_HZ. You get to choose between 100, 250
or 1000. It was not meant to allow runtime HZ modifications.
> 2. It needs its handler to be executed
> first in the chain. Otherwise the quality
> is poor because of the latency.
Yeah, that's a tougher one :)
> My approach solves both problems by
> introducing the grabbing ability.
> This is a rather simple patch, and since
> it allows to do some cleanup, I though
> it could be usefull not only for the
> speaker driver.
> But if you can tell me how to achieve
> at least the point 1 (that is, speed up the
> timer at run-time quite arbitrary) without
> the kernel mods, then it would be a real
> salvation.
Does the dynamic-tick patch help you at all? I'm not sure if it's
meant to, admittedly. I'm also not sure if it has any cap on the
maximum HZ it attempts to reprogram the hardware to... Mucking with HZ
at run-time is going to break lots of stuff, though...well, not
necessarily, depends on how you muck with jiffies :)
Thanks,
Nish
-
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/