Whenever I wake my machine from sleep, my USB audio interface is not recognized anymore. It works again as expected after un- and re-plugging the cable, or after a reboot. But obviously it's annoying to do that several times a day.
usbreset is not an option because the device does not show up in lsusb. I tried adding a kernel parameter to prevent the system from disabling USB before sleep, but somehow I'm unable to update the GRUB config. When I run sudo grub-mkconfig -o /boot/grub/grub.cfg I get this output:
[lenny@archlinux ~]$ sudo grub-mkconfig -o /boot/grub/grub.cfg [sudo] password for lenny: insmod: ERROR: could not load module part_gpt: No such file or directory I also tried to check whether there is an option in the UEFI that disables USB ports during sleep but I was unable to find anything. I use a Gigabyte B550 Aorus PRO (v2 if I'm not mistaken).
Any ideas on how to troubleshoot this?
Edit: Here is my output of lsusb:
[meekah@archlinux ~]$ lsusb -t /: Bus 001.Port 001: Dev 001, Class=root_hub, Driver=xhci_hcd/10p, 480M |__ Port 006: Dev 002, If 0, Class=Hub, Driver=hub/4p, 480M |__ Port 001: Dev 004, If 0, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 001: Dev 004, If 1, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 003: Dev 006, If 0, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 003: Dev 006, If 1, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 003: Dev 006, If 2, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 004: Dev 008, If 0, Class=Audio, Driver=snd-usb-audio, 480M |__ Port 004: Dev 008, If 1, Class=Audio, Driver=snd-usb-audio, 480M |__ Port 004: Dev 008, If 2, Class=Audio, Driver=snd-usb-audio, 480M |__ Port 004: Dev 008, If 3, Class=Application Specific Interface, Driver=[none], 480M |__ Port 007: Dev 003, If 0, Class=Human Interface Device, Driver=usbhid, 12M |__ Port 010: Dev 005, If 0, Class=Hub, Driver=hub/4p, 480M |__ Port 001: Dev 007, If 0, Class=Vendor Specific Class, Driver=xone-dongle, 480M /: Bus 002.Port 001: Dev 001, Class=root_hub, Driver=xhci_hcd/4p, 10000M /: Bus 003.Port 001: Dev 001, Class=root_hub, Driver=xhci_hcd/4p, 480M /: Bus 004.Port 001: Dev 001, Class=root_hub, Driver=xhci_hcd/4p, 10000M [meekah@archlinux ~]$ lsusb Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 001 Device 002: ID 05e3:0608 Genesys Logic, Inc. Hub Bus 001 Device 003: ID 048d:5702 Integrated Technology Express, Inc. RGB LED Controller Bus 001 Device 004: ID 0c45:7016 Microdia USB DEVICE Bus 001 Device 005: ID 05e3:0608 Genesys Logic, Inc. Hub Bus 001 Device 006: ID 04d9:a067 Holtek Semiconductor, Inc. USB Gaming Mouse Bus 001 Device 007: ID 045e:02fe Microsoft Corp. XBOX ACC Bus 001 Device 008: ID 1397:0507 BEHRINGER International GmbH UMC202HD 192k Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub [meekah@archlinux ~]$ As you can see, my audio interface is on bus 1, as is my keyboard and mouse. But, after running the following command, the devices do not properly turn on again:
sudo sh -c 'echo 0 > /sys/bus/usb/devices/usb1/bConfigurationValue; sleep 2; echo 0 > /sys/bus/usb/devices/usb1/bConfigurationValue'
I tried making the sleep longer, but that only resulted in the LEDs of my keyboard turning back on after, even though it did not actually work. After replugging the keyboard, it still does not work. It seems to me like the USB controller does not properly turn on again.
Edit 2: I managed to get grub working again (anyone stumbling upon this, it looks like my /etc/default/grub contents were replaced with the contents of /boot/grub/grub.cfg. I'm not entirely sure that was the issue, I just reinstalled grub using pacman) and added a linux kernel parameter: usbcore.autosuspend=-1, but after sleep my audio interface is still gone.
Edit 3: I also noticed that a restart does not fix this issue. Only powering down the system and booting completely from scratch or replugging fixes it.
Edit 4: Now I had my machine sleep over night, and now the audio interface was properly recognized after waking. Just to try it out I put it to sleep again and woke it after a few seconds, and the audio interface was gone again.
Edit 5: After tonight's sleep, it did not recognize the audio interface. This time I put my machine into sleep manually, I'm not sure if it was automatically last time.
/sys/bus/usb/devices/2-1/authorized, but I don't see any directories inusb, just a few files namedhiddev0,hiddev1andhiddev2. Also,usbresetseems to be unable to reset hubs.