Problem attaching an Atheros wifi USB adapter

Until now, I had no problem attaching my Atheros wifi USB adapter to a (disposable) NetVM. This operation is not possible any more.

When I plug the USB adapter in my computer, here is what I get (on my disp-sys-usb VM):
sudo dmesg :

[  475.410490] usb 4-3: new high-speed USB device number 5 using xhci_hcd
[  475.557011] usb 4-3: New USB device found, idVendor=0cf3, idProduct=9271, bcdDevice= 1.08
[  475.557045] usb 4-3: New USB device strings: Mfr=16, Product=32, SerialNumber=48
[  475.557066] usb 4-3: Product: UB91C
[  475.557077] usb 4-3: Manufacturer: ATHEROS
[  475.557087] usb 4-3: SerialNumber: 12345
[  475.625458] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[  475.655251] cfg80211: Loaded X.509 cert 'sforshee: xxxxxxxxxxxxxxxxxx'
[  475.694156] usb 4-3: ath9k_htc: Firmware ath9k_htc/htc_9271-1.4.0.fw requested
[  475.694244] usbcore: registered new interface driver ath9k_htc
[  475.978615] usb 4-3: ath9k_htc: Transferred FW: ath9k_htc/htc_9271-1.4.0.fw, size: 51008
[  476.230388] ath9k_htc 4-3:1.0: ath9k_htc: HTC initialized with 33 credits

When I (try to) attach the USB adapter to my (disposable) NetVM, I get (on my disp-sys-usb VM):
sudo dmesg

[  505.656893] ath9k_htc: Failed to initialize the device
[  505.657006] usb 4-3: ath9k_htc: USB layer deinitialized
... [  xxxxxxxxxx] audit: ...
[  615.592286] usbip-host 4-3: 4-3 is not in match_busid table... skip!
[  615.592317] usbcore: registered new device driver usbip-host
[  615.594445] usbip-host 4-3: usbip-host: register new device (bus 4 dev 5)
[  615.599401] usbip-host 4-3: stub up
[  620.665039] usbip-host 4-3: recv a header, 0
[  620.665240] usbip-host 4-3: stopped by a call to usb_kill_urb() because of cleaning up a virtual connection
[  620.779667] usbip-host 4-3: reset high-speed USB device number 5 using xhci_hcd
[  625.962533] usbip-host 4-3: device descriptor read/64, error -110
[  641.834508] usbip-host 4-3: device descriptor read/64, error -110
[  642.050498] usbip-host 4-3: reset high-speed USB device number 5 using xhci_hcd
[  647.466509] usbip-host 4-3: device descriptor read/64, error -110
[  663.338521] usbip-host 4-3: device descriptor read/64, error -110
[  663.554530] usbip-host 4-3: reset high-speed USB device number 5 using xhci_hcd
[  668.856649] xhci_hcd 0000:00:08.0: Timeout while waiting for setup device command
[  674.488684] xhci_hcd 0000:00:08.0: Timeout while waiting for setup device command
[  674.696507] usbip-host 4-3: device not accepting address 5, error -62
[  674.810513] usbip-host 4-3: reset high-speed USB device number 5 using xhci_hcd
[  680.120624] xhci_hcd 0000:00:08.0: Timeout while waiting for setup device command
[  685.752654] xhci_hcd 0000:00:08.0: Timeout while waiting for setup device command
[  685.960528] usbip-host 4-3: device not accepting address 5, error -62
[  685.960588] usbip-host 4-3: device reset
[  685.960618] usbip-host 4-3: USB disconnect, device number 5
[  686.074484] usb 4-3: new high-speed USB device number 6 using xhci_hcd

NB 1: Attaching my yubikey to a VM works flawlessly.
NB 2:The Atheros USB adapter is recognized on a Win10 system. Moreover its blue led blinks, which does not happen in Qubes.

Any help to troubleshoot the problem would be greatly appreciated. Thanks!

Addtionnal info if it can help to troublehoot, the sudo dmesg from the NetVM:

[  119.078629] vhci_hcd vhci_hcd.0: USB/IP Virtual Host Controller
[  119.080694] vhci_hcd vhci_hcd.0: new USB bus registered, assigned bus number 1
[  119.080724] vhci_hcd: created sysfs vhci_hcd.0
[  119.080768] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 4.19
[  119.080785] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[  119.080802] usb usb1: Product: USB/IP Virtual Host Controller
[  119.080816] usb usb1: Manufacturer: Linux 4.19.132-1.pvops.qubes.x86_64 vhci_hcd
[  119.080832] usb usb1: SerialNumber: vhci_hcd.0
[  119.081933] hub 1-0:1.0: USB hub found
[  119.081951] hub 1-0:1.0: 8 ports detected
[  119.082085] vhci_hcd vhci_hcd.0: USB/IP Virtual Host Controller
[  119.082239] vhci_hcd vhci_hcd.0: new USB bus registered, assigned bus number 2
[  119.082273] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[  119.082310] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 4.19
[  119.082327] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[  119.082343] usb usb2: Product: USB/IP Virtual Host Controller
[  119.082358] usb usb2: Manufacturer: Linux 4.19.132-1.pvops.qubes.x86_64 vhci_hcd
[  119.082374] usb usb2: SerialNumber: vhci_hcd.0
[  119.084412] hub 2-0:1.0: USB hub found
[  119.084432] hub 2-0:1.0: 8 ports detected
[  119.260281] vhci_hcd vhci_hcd.0: pdev(0) rhport(0) sockfd(0)
[  119.260303] vhci_hcd vhci_hcd.0: devid(262155) speed(3) speed_str(high-speed)
[  119.478939] usb 1-1: new high-speed USB device number 2 using vhci_hcd
[  124.323424] vhci_hcd: connection closed
[  124.323463] vhci_hcd: stop threads
[  124.323485] vhci_hcd: release socket
[  124.323496] vhci_hcd: disconnect device
[  124.786906] vhci_hcd: vhci_device speed not set

Thank you for your time, much appreciated!

Just a quick question: did you try out a different USB port already (preferably one that is different from the one you tried now, for example a 2.0 port instead of a 3.0 port)?

Thank you for suggesting, Raphael.
I tried the 4 of them. None of them works.

Sorry, I have no idea what’s wrong.
I can only say what I would do to investigate this issue:
Search qubes-users–Google Groups and qubes-devel–Google Groups
Look for similar bug reports and possible solutions here:

For example, you can find #issue3628 that looks similar to your problem. There are other links to more issues like this.
I don’t know if this is a kernel problem but you could try the latest kernel. That could help but could also lead to other problems like non-functioning Ethernet .

Maybe someone more knowledgeable can help you with.

Thank you so much for replying, Raphael!

#issue3628 looks indeed to have very close symptoms. Unfortunately, I have quite a limited linux experience & knowledge and kernel thingys are currently still out of my reach.

I think my way to go will be what is suggested in #issue3628 :“I assume the best way to proceed with this issue is to wait for a fix (whether that will be the patch I submitted or another solution) to make it to the kernel upstream and then close once the fix arrived in Qubes(?).”

Thank you again so much for the time you spent on this issue! Much appreciated!!

1 Like

You’re welcome. This specific issue (#3628) has been closed and apparently fixed already, so don’t expect anything to happen there anymore.

There is an interesting discussion that could help you with your problem:

You wrote that “Until now I had no problem attaching (…)” so did this happen after creating your sys-usb (disp-sys-usb)?
Reading through issue #3778 it looks like this problem is only existing when passing your USB wifi adapter to a VM and has something to do with usbip.

What model is your wifi dongle? Maybe the easiest way to solve this problem could be trying out another (cheap) dongle? There are several mentioned at the end of this #3778 discussion.

I saw that but, since it worked flawlessy and it does not anymore, I suspect a problem of the same kind (kernel).
And if it is, my current knowledge of linux won’t be sufficient to diagnose and/or troubleshoot further.

Actually, I bought 3 different wifi USB adapters. 8 months ago, when I tried to understand why the other 2 did not work with Qubes (those 2 never worked with Qubes), I found that explanation. If my understanding is correct, this issue #3778 is related to RT2800USB, which is not the atheros wifi adapter, though. (?)

I mean that it worked flawlessy about 2 months ago. I have no idea why it stopped working when I tried again 4 days ago. As far as I remember, I have not modified my disp-sys-usb nor my disposable NetVM.

Alfa AWUS036NHA
Atheros 9271

Actually, I have already bought 3 of them. Perhaps not the good ones, though!!! I had not read #3778 at the time of the purchase. All of them were running on my Raspberry Pi. Hopefully, this is still the case and I will be luckier than with Qubes (where Atheros suddently stopped working). If so, I will connect my Qubes–ethernet cable–>Raspberry Pi–>Atheros USB wifi adaptor (or one of the 2 others). My Raspberry Pi (with IP forwarding) will be kind of an adaptor between my Qubes and my wifi USB adapter.
Certainly not the most convenient but a solution that might work with my current level of knowledge.

Thanks again for your time, researches and ideas. Very much appreciated!!