protonscr

dinput hid_joystick_enum_device stops iterating at index 0 with null GUID when non-joystick hidraw devices occupy lower indices, preventing HOTAS/flight stick detection

protonclosed
ValveSoftware/Proton#9576 · opened 2026-03-15 by odelik · updated 2026-03-15 · 1 comments · github
1 matching comments, n / p to jump
Oodelik 2026-03-15 github

Compatibility Report

  • Name of the game with compatibility issues:
  • Steam AppID of the game: 1222730 (Star Wars Squadrons)

System Information

I confirm:

  • [x] that I haven't found an existing compatibility report for this game.
  • [x] that I have checked whether there are updates for my system available.

Symptoms

When multiple non-joystick HID devices (cooler, headset, keyboard, mouse) are connected and occupy lower hidraw indices than a flight stick, dinput8_EnumDevices fails to enumerate the joystick. The device is correctly detected by the OS and accessible with correct permissions, but the game never sees it.

  • Flight stick correctly detected by OS (lsusb, ls /dev/hidraw*)
  • /dev/hidraw7 has correct 0666 permissions
  • PROTON_ENABLE_HIDRAW=0x3344/0x43f4 set in launch options
  • GE-Proton correctly creates hidraw device internally
  • Flight stick does NOT appear in game's control settings

Reproduction

  1. Connect a HOTAS/flight stick alongside additional USB HID devices
  2. Verify flight stick appears at hidraw index greater than 2 or higher
  3. Ensure all hidraw devices have 0666 permissions
  4. Set launch options: PROTON_ENABLE_HIDRAW=0x3344/0x43f4 %command%
  5. Launch Star Wars Squadrons (app ID 1222730)
  6. Open controls settings and observe that the flight stick will not appear
  7. Run with
  8. Observe hid_joystick_device_open index 0, guid {00000000...} in log

Log Evidence

Wine correctly discovers the device:

00c4:trace:hid:hidraw_device_create dev 0x7f..., node "/dev/hidraw7", 
  desc {vid 3344, pid 43f4, version 0100, input 0, is_hidraw 1, bus_type 1}
00c4:trace:hid:bus_main_thread creating hidraw device 3344:43f4 
  with usages 0001:0004
00c4:trace:hid:driver_add_device Adding device to PDO ..., 
  id L"USB\\VID_3344&PID_43F4&MI_00"\\L"256&FF&0&0&0"

But DirectInput enumeration fails:

0138:trace:dinput:dinput8_EnumDevices iface ..., type 0x4, flags 0x1
0138:trace:dinput:hid_joystick_enum_device type 0x4, flags 0x1, 
  instance ..., version 0x800, index 0
0138:trace:dinput:hid_joystick_device_open index 0, 
  guid {00000000-0000-0000-0000-000000000000}

This pattern repeats identically on every launch across multiple
Proton log captures. The enumeration never progresses beyond index 0
and never reaches my flight stick at hidraw7. Even when non-joystick hidraw devices had Permission denied errors
in testing, the same null GUID was observed:

00c4:trace:hid:maybe_add_devnode Unable to open "/dev/hidraw2", 
  ignoring: Permission denied
00c4:trace:hid:maybe_add_devnode Unable to open "/dev/hidraw1", 
  ignoring: Permission denied

Potential Root Cause

Based upon my interpretation of the logs, it looks like hid_joystick_enum_device in dlls/dinput/joystick_hid.c stops
iterating when it encounters a non-joystick device at index 0,
returning a null GUID instead of continuing to higher indices where
the joystick resides. This is consistent across all executions
regardless of whether the non-joystick devices are accessible or
return permission denied.

Workaround

Restricting non-joystick hidraw devices to root-only 0600 permissions
via udev rules causes Wine to skip them during enumeration, allowing
it to reach the flight stick at hidraw7.

Below are the udev rules I have added on my system:

/etc/udev/rules.d/60-virpil-input.rules:

SUBSYSTEM=="hidraw", ATTRS{idVendor}=="3344", MODE="0666", TAG+="uaccess"
SUBSYSTEM=="usb", ATTRS{idVendor}=="3344", MODE="0666", TAG+="uaccess"

/etc/udev/rules.d/60-nzxt-input.rules:

SUBSYSTEM=="hidraw", ATTRS{idVendor}=="1e71", MODE="0600"

/etc/udev/rules.d/60-steelseries-input.rules:

SUBSYSTEM=="hidraw", ATTRS{idVendor}=="1038", MODE="0600"

Related Issues

  • ValveSoftware/Proton#9034
  • systemd/systemd#22681
Kkisak-valve maintainer 2026-03-15 github

Hello @odelik, we're using one issue report per unofficially supported game title, so I've gone ahead and transferred this issue report to https://github.com/ValveSoftware/Proton/issues/4238#issuecomment-4064017401.