Driver Conflict Between Xbox Controller Dongle And USB WiFi

I’m a gamer using Xbox One Controller. One of the issues I faced recently since I migrated my daily driver from Windows to Linux is to connect my controller to the machine to actually game. It needs a few tinkering to work, unlike how convenient it is to plug-and-play on Windows, which is pretty fine because I’d never got a chance to understand those driver stuff if it wasn’t because the accidental conflict between the controller dongle and my USB WiFi stick.

TLDR

If you use xone to wirelessly connect your controller, and you happen to have a USB WiFi on your machine, you want to make sure your WiFi driver isn’t mt76x2u. Use one with chip from Realtek or Intel, or still MediaTek but with careful pick, so that the driver of that chip doesn’t conflict.

And blacklist the mt76x2u as instructed in xone.

The Problem

My desktop runs Debian Testing (trixie at the moment). I got an official Xbox One Controller with wireless dongle/adapter. I got a USB WiFi with unknown chip initially, which turned out to be a MediaTek chip. I’d like to use the controller wirelessly so the xone Xbox Controller driver is the pick.

Tip
  • Wired connection: use xone, or alternatively the built-in kernel driver xpad.
  • Wireless connection: use xone.
  • Bluetooth connection: use xpadneo.

When I installed the xone driver following the guides, my machine wireless connection was immediately cut, as if my WiFi usb is never plugged in.

I need a machine with my wireless controller connected and a working WiFi.

Troubleshoot

Why My Network Was Down Immediately

This wasn’t hard to figure out. Take a quick look into how the driver is installed, at the end of the installation script, a few lines are interesting:

1
2
3
4
5
6
7
8
9
...
install -D -m 644 install/modprobe.conf /etc/modprobe.d/xone-blacklist.conf
install -D -m 755 install/firmware.sh /usr/local/bin/xone-get-firmware.sh
...
# Avoid conflicts between mt76x2u and xone
if lsmod | grep -q '^mt76x2u'; then
    modprobe -r mt76x2u
fi
...

It removed a kernel module called mt76x2u, and inside the install/modprobe.conf, it configures to blacklist that module too, which explains why restarting machine didn’t bring my WiFi back.

A quick search of that driver name showed that it is a MediaTek USB support module. Further experiments to uninstall xone driver, reload that mt76x2u driver, then manually remove the driver mt76x2u reproduced the recovered network connection and immediate cut again. It proves that my USB WiFi really depends on that module, when direct hardware information check gives no clue what chip it uses (it’s cheap, random usb device).

What If That Module Was Not Blacklisted

With the cause discovered, I immediately decided to see if someone else had the problem and what they did. I did find a similar one, though it’s with xone’s precedent driver xow. But according the poster, both his USB WiFi and the dongle worked correctly even with that blacklist line removed… so does it mean I can do the same?

I immediately removed the line that unloads the kernel module in the script, and the line to blacklist across reboot. When installing xone without --release flag, the module was built in debug mode, sending message to dmesg, giving us a chance to see how kernel handles both devices.

Tip

“Recent version of dmesg provides a ‘follow’ option which works like tail -F” so that dmesg output can be monitored with dmesg -wH. But if your version of dmesg doesn’t have that option you need to manually poll.

Souce: https://unix.stackexchange.com/a/95852

This is what it looks like when plugging in the usb WiFi alone:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
[ +10.270200] usb 1-7.1: new high-speed USB device number 15 using xhci_hcd
[  +0.128903] usb 1-7.1: New USB device found, idVendor=0e8d, idProduct=2870, bcdDevice= 0.01
[  +0.000004] usb 1-7.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
...
[  +0.000005] usb 1-7.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  +0.000002] usb 1-7.1: Product: 802.11ac WLAN
[  +0.000002] usb 1-7.1: Manufacturer: MediaTek Inc.
[  +0.000001] usb 1-7.1: SerialNumber: 000000000
[  +0.142831] usb 1-7.1: reset high-speed USB device number 16 using xhci_hcd
[  +0.141157] mt76x2u 1-7.1:1.0: ASIC revision: 76120044
[  +0.576042] mt76x2u 1-7.1:1.0: firmware: direct-loading firmware mt7662_rom_patch.bin
[  +0.000033] mt76x2u 1-7.1:1.0: ROM patch build: 20141115060606a
[  +0.331984] mt76x2u 1-7.1:1.0: firmware: direct-loading firmware mt7662.bin
[  +0.000071] mt76x2u 1-7.1:1.0: Firmware Version: 0.0.00
[  +0.000003] mt76x2u 1-7.1:1.0: Build: 1
[  +0.000001] mt76x2u 1-7.1:1.0: Build Time: 201507311614____
[  +3.254916] ieee80211 phy4: Selected rate control algorithm 'minstrel_ht'
[  +0.011094] mt76x2u 1-7.1:1.0 wlx0013ef4f44d2: renamed from wlan0
[ +15.960061] wlx0013ef4f44d2: authenticate with 80:8f:1d:73:c2:91
[  +1.009620] wlx0013ef4f44d2: send auth to 80:8f:1d:73:c2:91 (try 1/3)
[  +0.004125] wlx0013ef4f44d2: authenticated
...

This is what it looks like when both devices are plugged in. In this situation, despite of the error messages, the network still works. Very interestingly, the conflict comes from the fact that, the controller dongle is recognized, and is instructed by kernel to work as a WiFi device lol.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
[Jan26 18:11] usb 1-6: new high-speed USB device number 17 using xhci_hcd
[  +0.251749] usb 1-6: New USB device found, idVendor=045e, idProduct=02fe, bcdDevice= 1.00
[  +0.000004] usb 1-6: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  +0.000002] usb 1-6: Product: XBOX ACC
[  +0.000001] usb 1-6: Manufacturer: Microsoft Inc.
[  +0.000002] usb 1-6: SerialNumber: 432339
[  +0.247149] usb 1-6: reset high-speed USB device number 17 using xhci_hcd
[  +0.249837] mt76x2u 1-6:1.0: ASIC revision: 76320044
[  +0.582030] mt76x2u 1-6:1.0: firmware: direct-loading firmware mt7662_rom_patch.bin
[  +0.000039] mt76x2u 1-6:1.0: ROM patch build: 20141115060606a
[  +0.326971] mt76x2u 1-6:1.0: firmware: direct-loading firmware mt7662.bin
[  +0.000068] mt76x2u 1-6:1.0: Firmware Version: 0.0.00
[  +0.000002] mt76x2u 1-6:1.0: Build: 1
[  +0.000001] mt76x2u 1-6:1.0: Build Time: 201507311614____
[  +2.395937] mt76x2u 1-6:1.0: error: MCU resp evt:9 seq:1-0
[  +0.000040] mt76x2u 1-6:1.0: error: MCU resp evt:9 seq:1-0
[  +0.000040] mt76x2u 1-6:1.0: error: MCU resp evt:9 seq:1-0
[  +0.836897] ieee80211 phy5: Selected rate control algorithm 'minstrel_ht'
[  +0.266261] mt76x2u 1-6:1.0 wlx6c5d3a187519: renamed from wlan0

# No further wireless authentication because it sort of "shadows" the real WiFi device.

A further experiment to uninstall xone but keep mt76x2u module, with only the dongle controller plugged-in, without the real WiFi device, shows that … the Xbox controller dongle can really act as a WiFi receiver lol, although there’s obviously a auth incompatibility and switch, maybe because of the 2.4GHz and 5GHz version of my WiFi.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
[  +7.233528] usb 1-7.1: new high-speed USB device number 18 using xhci_hcd
[  +0.139424] usb 1-7.1: New USB device found, idVendor=045e, idProduct=02fe, bcdDevice= 1.00
[  +0.000004] usb 1-7.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  +0.000002] usb 1-7.1: Product: XBOX ACC
[  +0.000002] usb 1-7.1: Manufacturer: Microsoft Inc.
[  +0.000001] usb 1-7.1: SerialNumber: 432339
[  +0.139266] usb 1-7.1: reset high-speed USB device number 18 using xhci_hcd
...
[  +0.000001] mt76x2u 1-7.1:1.0: Build Time: 201507311614____
[  +2.409934] mt76x2u 1-7.1:1.0: error: MCU resp evt:9 seq:1-0
[  +0.000039] mt76x2u 1-7.1:1.0: error: MCU resp evt:9 seq:1-0
[  +0.000040] mt76x2u 1-7.1:1.0: error: MCU resp evt:9 seq:1-0
[  +0.837891] ieee80211 phy6: Selected rate control algorithm 'minstrel_ht'
[  +0.009852] mt76x2u 1-7.1:1.0 wlx6c5d3a187519: renamed from wlan0
[Jan26 18:18] wlx6c5d3a187519: authenticate with 80:8f:1d:73:c2:91
[  +0.973215] wlx6c5d3a187519: send auth to 80:8f:1d:73:c2:91 (try 1/3)
[  +0.410995] wlx6c5d3a187519: send auth to 80:8f:1d:73:c2:91 (try 2/3)
[  +0.011002] wlx6c5d3a187519: send auth to 80:8f:1d:73:c2:91 (try 3/3)
[  +0.473005] wlx6c5d3a187519: authentication with 80:8f:1d:73:c2:91 timed out
[  +3.355332] wlx6c5d3a187519: authenticate with 80:8f:1d:73:c2:8f
[  +0.000012] wlx6c5d3a187519: 80 MHz not supported, disabling VHT
[  +0.851607] wlx6c5d3a187519: send auth to 80:8f:1d:73:c2:8f (try 1/3)
[  +0.006345] wlx6c5d3a187519: authenticated

Finally, if mt76x2u is disabled and xone is installed, the controller can connect just fine, with another set of message in dmesg showing the negotiation is successful.

What Did I Do

With the cause uncovered, I simply choosed to purchase a new WiFi that doesn’t use mt76x2u driver, from RealTek. There’s a nice summary from the community of USB WiFi chipset compatibility for Linux. I just picked one from it and search for usb WiFi with that chip.

I once thought about adding a wireless NIC via PCI-E to the motherboard directly but a few days ago I’ve already messed up the board when upgrading my GPU from NVidia to AMD, so I’d like to keep it running for a while to see if it stablizes, before introducing another varaible. But PCI version of NIC is also an option for you.

Either way, don’t use a conflicted version of NIC, and blacklist mt76x2u when you found an alternative.

0%