Re: mouse driver bug in 2.6.0-test7?

From: Vojtech Pavlik
Date: Tue Oct 14 2003 - 15:14:58 EST


On Tue, Oct 14, 2003 at 01:04:03PM -0700, 4Front Technologies wrote:

> >Patch considered. I'll up the samplerate default to 80, but not more,
> >since samplerates above that cause trouble for a lot of people (keyboard
> >doesn't work when you're moving the mouse).
> >
> >The "set lower rate in case ..." part of the patch doesn't make sense.
> >If the user gives a too low (less than 10) samples per second, then the
> >original code will try to set 0, which is stupid, but harmless. The
> >added code will try to access beyond the bounds of the rates[] array.
>
>
> Hi Martin/Vojtech,
>
> Martin, many thanks for your fix - it works perfectly now.
>
> Oddly enough the sample rate of 200 seems to have fixed the problem.
> Vojetech, Martin's fixes are fully functional.

Not completely. One reason wht the sample rate of 200 probably fixed the
problem is that you have very high acceleration settings in X.

Since with report rate 200 you get a medium speed movement as

+1 +1 +1 +1 +1 +1 +1 +1 +1

events, and with report rate 60 you get

+3 +3 +3

and the X mouse acceleration code is stupid enough to judge the mouse
speed from the event VALUE only, it thinks the mouse is moving much
faster in the second case.

You need to up the acceleration threshold (or disable acceleration
completely).

This also means that with report rate of 200, mouse acceleration is more
or less disabled, since you get +1's only even at quite high speeds of
mouse movement.

> If you want to keep it at 80,

I don't want to. I like the feel of a mouse at 200 samples per second,
however it causes problems on some hardware, which means I have to stay
with a more reasonable default.

> I'd recommend that you make the sample rate a module config option so that
> users may be able to tweak this for their systems.

It already is. Only the code to make it a kernel command line parameter
(when psmouse is compiled into the kernel) is missing.

> The default of 200 has been tested on VIA400 and IntelICH5 systems that I
> have.

Yes, new boards don't have any problems with it. It's the older ones
that do.

> One running Redhat9/2.6.0-test7 and the other running Gentoo 1.4/2.6.0-test7

--
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@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/