[lkml]   [1999]   [Mar]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [patch] recover lost ticks
On Tue, Mar 16, 1999 at 11:06:34AM +0100, Ingo Molnar wrote:
> On Mon, 15 Mar 1999, Vojtech Pavlik wrote:
> > Second - there is hardware that can't be fixed, and that needs to have
> > interrupts disabled for more than 10 ms to work. Yes, for example the MS
> > SideWinder 3D Pro joystick .... (during the initialization, and subsequent
> > re-initializations).
> could you explain why exactly it needs interrupts disabled for more than
> 10 ms?

Oops. I was off by an order of magnitude here.

The MS SideWinder joystick sends its data+id packet during the init phase,
and they are 66+160 bits long. It sends this at 100 kHz, and because the
driver has to poll the gameport to watch the clock bit go up and down, it
needs interrupts disabled. Even then, when ISA DMA takes place, it gets many
missed bits. Anyway 226 * 10 us is just 2.26 ms max cli() time, which is
less, but still a lot. Would miss a tick on Alpha (unless it has more clever
interrupt handling).

Anyway, for another example, I've checked the Logitech joystick driver. It
needs to send an init sequence to the joystick, which consists of a series
of various delays and writes to the joystick port. It needs to be timed
precisely, and, so it can't allow an interrupts to happen in the middle of
the udelay() and make it take more time. The whole sequence takes 6+11+7+9 =
33 ms of cli() time. I could base this on gettimeofday() or PIT reading, and
forget the cli(), but still an interrupt at the wrong time would kill the
timing ...

Just two examples of bad behaving hardware.

Have fun,

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

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