input event/mouse detection from evdev/x server
Peter Hutterer
peter.hutterer at who-t.net
Sun Jan 30 19:04:10 PST 2011
On Fri, Jan 28, 2011 at 04:56:45PM +0000, Popescu, CatalinX wrote:
> Hi,
>
> I have an issue with the X server, evdev library more precisely. When a mouse (or a compatible device) is detected by the X server, the server does actually detect an event device (/dev/input/eventN) and a mouse device (/dev/input/mouseN). On the event device detection is successful, but the mouse detection fails because of the EVIOCGNAME ioctl failing. As a result the evdev module gets unloaded. Depending on which detection happens in first place the mouse will/won't work :
> - if the mouse device gets detected first the mouse will work
> - if the mouse device gets detected after the event device the evdev module will get unloaded and the mouse won't work
Note that the module refcounting is handled by libc and when the module is
unloaded it isn't actually unloaded. i.e. even if you see UnloadModule in
your log that doesn't mean the module is gone.
if your device really doesn't work in case 2, that must be caused by some
other issue. in which case the full log would help to debug.
Cheers,
Peter
> See below the /var/log/Xorg.0.log :
>
> [ 18.672] (II) config/udev: Adding input device Logitech USB-PS/2 Optical
> Mouse (/dev/input/event2)
> [ 18.672] (**) Logitech USB-PS/2 Optical Mouse: Applying InputClass
> "default"
> [ 18.672] (II) LoadModule: "evdev"
> [ 18.675] (II) Loading /usr/lib/xorg/modules/input/evdev_drv.so
> [ 18.676] (II) Module evdev: vendor="X.Org Foundation"
> [ 18.677] compiled for 1.9.0, module version = 2.4.99
> [ 18.677] Module class: X.Org XInput Driver
> [ 18.677] ABI class: X.Org XInput driver, version 11.0
> [ 18.678] (**) Logitech USB-PS/2 Optical Mouse: always reports core events
> [ 18.678] (**) Logitech USB-PS/2 Optical Mouse: Device: "/dev/input/event2"
> [ 18.683] (--) Logitech USB-PS/2 Optical Mouse: Found 3 mouse buttons
> [ 18.683] (--) Logitech USB-PS/2 Optical Mouse: Found scroll wheel(s)
> [ 18.683] (--) Logitech USB-PS/2 Optical Mouse: Found relative axes
> [ 18.683] (--) Logitech USB-PS/2 Optical Mouse: Found x and y relative axes
> [ 18.684] (II) Logitech USB-PS/2 Optical Mouse: Configuring as mouse
> [ 18.684] (**) Logitech USB-PS/2 Optical Mouse: YAxisMapping: buttons 4 and
> 5
> [ 18.684] (**) Logitech USB-PS/2 Optical Mouse: EmulateWheelButton: 4,
> EmulateWheelInertia: 10, EmulateWheelTimeo0
> [ 18.684] (II) XINPUT: Adding extended input device "Logitech USB-PS/2
> Optical Mouse" (type: MOUSE)
> [ 18.685] (**) Logitech USB-PS/2 Optical Mouse: (accel) keeping acceleration
> scheme 1
> [ 18.685] (**) Logitech USB-PS/2 Optical Mouse: (accel) acceleration profile
> 0
> [ 18.685] (**) Logitech USB-PS/2 Optical Mouse: (accel) acceleration factor:
> 2.000
> [ 18.685] (**) Logitech USB-PS/2 Optical Mouse: (accel) acceleration
> threshold: 4
> [ 18.685] (II) Logitech USB-PS/2 Optical Mouse: initialized for relative
> axes.
> [ 18.690] (II) config/udev: Adding input device Logitech USB-PS/2 Optical
> Mouse (/dev/input/mouse0)
> [ 18.691] (**) Logitech USB-PS/2 Optical Mouse: Applying InputClass
> "default"
> [ 18.691] (**) Logitech USB-PS/2 Optical Mouse: always reports core events
> [ 18.691] (**) Logitech USB-PS/2 Optical Mouse: Device: "/dev/input/mouse0"
> [ 18.695] (EE) ioctl EVIOCGNAME failed: Inappropriate ioctl for device
> [ 18.707] (II) UnloadModule: "evdev"
>
>
> Can someone explain why there are 2 input "devices" detected by X server for one physical mouse? How can this be fixed? Is it an issue with the evdev kernel driver or an issue with X server/evdev extension?
>
> Thanks.
> -catalin
More information about the xorg-devel
mailing list