lkml.org 
[lkml]   [2003]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] input: Fix CLOCK_TICK_RATE usage ... [8/13]
On Tue, Jun 17, 2003 at 04:08:32PM -0700, David Mosberger wrote:

> >>>>> On Wed, 18 Jun 2003 00:42:33 +0200, Vojtech Pavlik <vojtech@suse.cz> said:
>
> >> so if a legacy speaker is present, it assumes a particular
> >> frequency. In other words: it's a driver issue. On ia64, this
> >> frequency certainly has nothing to do with time-keeping and
> >> therefore doesn't belong in timex.h.
>
> Vojtech> I'm quite fine with that. However, different (sub)archs,
> Vojtech> for example the AMD Elan CPUs have a slightly different
> Vojtech> base frequency. So it looks like an arch-dependent #define
> Vojtech> is needed. I don't care about the location (timex.h indeed
> Vojtech> seems inappropriate, maybe the right location is pcspkr.c
> Vojtech> ...), or the name, but something needs to be done so that
> Vojtech> the beeps have the same sound the same on all archs.
>
> Sounds much better to me. Wouldn't something along the lines of this
> make the most sense:
>
> #ifdef __ARCH_PIT_FREQ
> # define PIT_FREQ __ARCH_PIT_FREQ
> #else
> # define PIT_FREQ 1193182
> #endif
>
> After all, it seems like the vast majority of legacy-compatible
> hardware _do_ use the standard frequency.

Now, if this was in some nice include file, along with the definition of
the i8253 PIT spinlock, that'd be great. Because not just the beeper
driver uses the PIT, also some joystick code uses it if it is available.

--
Vojtech Pavlik
SuSE Labs, SuSE CR
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

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