Subject: Re: Scrolling Mice crash XdecNetBSD
To: Michiel Buddingh' <ajuin@stack.nl>
From: Nathan J. Williams <nathanw@wasabisystems.com>
List: port-alpha
Date: 03/10/2005 16:06:35
"Michiel Buddingh'" <ajuin@stack.nl> writes:

> I've recently acquired an AlphaServer 300 4/266 equipped with a nice
> ZLXP-E3, and I must say, NetBSD works like a charm on it.  However,
> and I suppose I have only myself to blame for mixing 'old' and 'new'
> hardware like this, scrolling the mouse invariably crashes XdecNetBSD
> (and XalphaNetBSD too, for that matter).  

I think you're tripping over the code in
xsrc/xfree/xc/programs/Xserver/hw/netbsd/alpha/alphaMouse.c:alphaMouseEnqueueEvent(),
which checks the wscons event type and uses it to pass up an event to
the dix layer. It only handles WSCONS_EVENT_MOUSE_UP, MOUSE_DOWN,
DELTA_X, DELTA_Y, ABSOLUTE_X, and ABSOLUTE_Y. Unfortunately, scroll
mouse motion is sent as DELTA_Z events.

It would be easy to make that code ignore DELTA_Z events. It could
also have a hardcoded hack to treat them as buttons 4 and 5, which
seems to be the standard X hack as well, if you're not using XINPUT.

XFree86 won't have this problem at all.

        - Nathan