[Bug 250724] USB gamepads are tagged as a mouse by udev

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Oct 29 15:27:39 UTC 2020


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=250724

            Bug ID: 250724
           Summary: USB gamepads are tagged as a mouse by udev
           Product: Base System
           Version: Unspecified
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: usb
          Assignee: usb at FreeBSD.org
          Reporter: doctorwhoguy at gmail.com

I have tested several USB gamecontrollers with FreeBSD, and there is something
apparently wrong with either evdev or udev because the USB game controllers are
being detected as mice instead of joysticks. I have tried both webcamd and
iichid to get them working with FreeBSD. For this example, I'll use my Logitech
Dual Action Controller.

If I plug it in, dmesg will show the device detected and attach it as a uhid
device:

uhid0 on uhub2
uhid0: <Logitech Logitech Dual Action, class 0/0, rev 1.10/3.00, addr 3> on
usbus3

If I load the iichid kernel module and plug in the controller, dmesg will show
the following output showing that it has been attached as an hid device:

ugen3.3: <Logitech Logitech Dual Action> at usbus3
usbhid0 on uhub2
usbhid0: <Logitech Logitech Dual Action, class 0/0, rev 1.10/3.00, addr 3> on
usbus3
hidbus0: <HID bus> on usbhid0
hgame0: <Logitech Logitech Dual Action Joystick> on hidbus0
hidraw0: <Logitech Logitech Dual Action Raw HID Device> on hidbus0

And /var/log/Xorg.0.log will show the following output:

[  1145.679] (II) config/udev: Adding input device Logitech Logitech Dual
Action Joystick (/dev/input/event6)
[  1145.679] (**) Logitech Logitech Dual Action Joystick: Applying InputClass
"evdev pointer catchall"
[  1145.679] (**) Logitech Logitech Dual Action Joystick: Applying InputClass
"libinput pointer catchall"
[  1145.679] (II) Using input driver 'libinput' for 'Logitech Logitech Dual
Action Joystick'
[  1145.679] (**) Logitech Logitech Dual Action Joystick: always reports core
events
[  1145.679] (**) Option "Device" "/dev/input/event6"
[  1145.679] (**) Option "_source" "server/udev"
[  1145.682] (II) event6  - Logitech Logitech Dual Action Joystick: is tagged
by udev as: Mouse
[  1145.683] (II) event6  - Logitech Logitech Dual Action Joystick: device is a
pointer
[  1145.684] (II) event6  - Logitech Logitech Dual Action Joystick: device
removed
[  1145.684] (**) Option "config_info" "udev:/dev/input/event6"
[  1145.685] (II) XINPUT: Adding extended input device "Logitech Logitech Dual
Action Joystick" (type: MOUSE, id 12)
[  1145.691] (**) Option "AccelerationScheme" "none"
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) selected
scheme none/0
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) acceleration
factor: 2.000
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) acceleration
threshold: 4
[  1145.698] (II) event6  - Logitech Logitech Dual Action Joystick: is tagged
by udev as: Mouse
[  1145.699] (II) event6  - Logitech Logitech Dual Action Joystick: device is a
pointer

If I unload iichid and run "webcamd -N Logitech-Logitech-Dual-Action -S unknown
-M 0", it will also show the same output in Xorg.0.log. Udev is capable of
tagging devices specifically as joysticks, but USB game controllers are being
tagged as mice instead. As a result, the only functionality from the controller
is that the left joystick moves the mouse cursor. So I don't know if FreeBSD's
evdev support lacks support for joysticks or if maybe there's just a problem
with correctly detecting these devices and giving them the proper tag.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-usb mailing list