Kimplul / hid-tmff2

Linux kernel module for Thrustmaster T300RS, T248 and (experimental) TX, T128 and TS-XW wheels
GNU General Public License v3.0
206 stars 20 forks source link

Forcing hid_tmff_new to be used for the T248 wheel #127

Open mattmcadoo opened 3 hours ago

mattmcadoo commented 3 hours ago

I'm having a problem where the T248 wheel is not acting like it's using the correct kernel driver. It shows it being picked up in dmesg but lsmod is not showing it's used. lshw is showing the usbhid driver being used. According to this StackExchange post, there is a way of forcing a PCI device to use a specific driver, but I'm not seeing anything in the corresponding /sys/bus/usb/drivers that looks like kernel module.

Here's my kernel seeing the device and loading the module:

[  462.053600] usb 3-2.4: USB disconnect, device number 7
[  464.802583] usb 3-2.4: new full-speed USB device number 9 using xhci_hcd
[  464.913742] usb 3-2.4: New USB device found, idVendor=044f, idProduct=b696, bcdDevice= 1.00
[  464.913752] usb 3-2.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  464.913756] usb 3-2.4: Product: Thrustmaster Advance Racer
[  464.913759] usb 3-2.4: Manufacturer: Thrustmaster
[  465.002605] input: Thrustmaster Thrustmaster Advance Racer as /devices/pci0000:00/0000:00:03.1/0000:02:00.0/0000:03:08.0/0000:05:00.1/usb3/3-2/3-2.4/3-2.4:1.0/0003:044F:B696.0009/input/input21
[  465.002758] hid-generic 0003:044F:B696.0009: input,hidraw7: USB HID v1.00 Joystick [Thrustmaster Thrustmaster Advance Racer] on usb-0000:05:00.1-2.4/input0
[  465.036315] hid_tmff_new: loading out-of-tree module taints kernel.
[  465.067671] input: Thrustmaster Thrustmaster Advance Racer as /devices/pci0000:00/0000:00:03.1/0000:02:00.0/0000:03:08.0/0000:05:00.1/usb3/3-2/3-2.4/3-2.4:1.0/0003:044F:B696.0009/input/input22
[  465.067791] tmff2 0003:044F:B696.0009: input,hidraw7: USB HID v1.00 Joystick [Thrustmaster Thrustmaster Advance Racer] on usb-0000:05:00.1-2.4/input0
[  465.095875] tmff2 0003:044F:B696.0009: force feedback for T248

This is lshw showing the driver as usbhid:

T:  Bus=03 Lev=02 Prnt=11 Port=03 Cnt=01 Dev#=  9 Spd=12   MxCh= 0
D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=044f ProdID=b696 Rev=01.00
S:  Manufacturer=Thrustmaster
S:  Product=Thrustmaster Advance Racer
C:  #Ifs= 1 Cfg#= 1 Atr=a0 MxPwr=100mA
I:  If#= 0 Alt= 0 #EPs= 2 Cls=03(HID  ) Sub=00 Prot=00 Driver=usbhid
E:  Ad=01(O) Atr=03(Int.) MxPS=  64 Ivl=4ms
E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=2ms

Listing of /sys/bus/usb/drivers:

threadripper /sys/bus/usb/drivers # l
total 0
drwxr-xr-x 2 root root 0 Nov 17 20:43 'Philips webcam'
drwxr-xr-x 2 root root 0 Nov 17 20:43  aqc111
drwxr-xr-x 2 root root 0 Nov 17 20:43  asix
drwxr-xr-x 2 root root 0 Nov 17 20:43  ati_remote2
drwxr-xr-x 2 root root 0 Nov 17 20:43  ax88179_178a
drwxr-xr-x 2 root root 0 Nov 17 20:43  catc
drwxr-xr-x 2 root root 0 Nov 17 20:43  cdc_ether
drwxr-xr-x 2 root root 0 Nov 17 20:43  cdc_ncm
drwxr-xr-x 2 root root 0 Nov 17 20:43  cdc_subset
drwxr-xr-x 2 root root 0 Nov 17 20:43  em28xx
drwxr-xr-x 2 root root 0 Nov 17 20:43  hub
drwxr-xr-x 2 root root 0 Nov 17 20:43  iforce
drwxr-xr-x 2 root root 0 Nov 17 20:43  kaweth
drwxr-xr-x 2 root root 0 Nov 17 20:43  lan78xx
drwxr-xr-x 2 root root 0 Nov 17 20:43  net1080
drwxr-xr-x 2 root root 0 Nov 17 20:43  pegasus
drwxr-xr-x 2 root root 0 Nov 17 20:43  r8152
drwxr-xr-x 2 root root 0 Nov 17 20:43  r8152-cfgselector
drwxr-xr-x 2 root root 0 Nov 17 20:43  r8153_ecm
drwxr-xr-x 2 root root 0 Nov 17 20:43  rtl8150
drwxr-xr-x 2 root root 0 Nov 17 20:43  s2255
drwxr-xr-x 2 root root 0 Nov 17 20:43  snd-usb-audio
drwxr-xr-x 2 root root 0 Nov 17 20:43  uas
drwxr-xr-x 2 root root 0 Nov 17 20:43  usb
drwxr-xr-x 2 root root 0 Nov 17 20:43  usb-storage
drwxr-xr-x 2 root root 0 Nov 17 20:43  usb_serial_simple
drwxr-xr-x 2 root root 0 Nov 17 20:43  usbfs
drwxr-xr-x 2 root root 0 Nov 17 20:43  usbhid
drwxr-xr-x 2 root root 0 Nov 17 20:43  usblp
drwxr-xr-x 2 root root 0 Nov 17 20:43  usbserial_generic
drwxr-xr-x 2 root root 0 Nov 17 20:43  usbtv
drwxr-xr-x 2 root root 0 Nov 17 20:43  uvcvideo
drwxr-xr-x 2 root root 0 Nov 17 20:43  zaurus
mattmcadoo commented 3 hours ago

sdl2-jstest does show the wheel and doing the test for it, moving the wheel does register the movement, but this is the only thing that does, every game both native Linux and in Steam/Proton doesn't register the wheel movements. Pedals are hit or miss on being picked up.

$ sdl2-jstest -l
Found 3 joystick(s)

Joystick Name:     'Thrustmaster SimTask FarmStick Right'
Joystick GUID:     03008bc34f0400001604000011010000
Joystick Number:    0
Number of Axes:     8
Number of Buttons: 33
Number of Hats:     0
Number of Balls:    0
GameControllerConfig:
  missing (see 'gamecontrollerdb.txt' or SDL_GAMECONTROLLERCONFIG)

Joystick Name:     'Thustmaster T500 RS Gear Shift'
Joystick GUID:     030053514f04000060b6000011010000
Joystick Number:    1
Number of Axes:     2
Number of Buttons: 10
Number of Hats:     0
Number of Balls:    0
GameControllerConfig:
  missing (see 'gamecontrollerdb.txt' or SDL_GAMECONTROLLERCONFIG)

Joystick Name:     'Thrustmaster Advance Racer'
Joystick GUID:     030048cd4f04000096b6000000010000
Joystick Number:    2
Number of Axes:     9
Number of Buttons: 26
Number of Hats:     1
Number of Balls:    0
GameControllerConfig:
  missing (see 'gamecontrollerdb.txt' or SDL_GAMECONTROLLERCONFIG)