You are not logged in.

#1 2021-12-19 05:40:00

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

USB autosuspend issue (can't disable)

Hello, I am having an issue where I can't figure out why I can't disable usb autosuspend. My laptop's usb ports work completely fine until I have to wake from sleep. After that no usb ports work and I have to reboot so they work again. I am using kernel 5.15.10, running an HP Omen 15 2021.

I tried adding this rule to /etc/udev/rules.d/50-usb_power_save.rules according to this help page on the wiki:

ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="05c6", ATTR{idProduct}=="9205", ATTR{power/autosuspend}="-1"

I also tried adding a kernel parameter (I am using GRUB), this is my grub configuration in etc/default/grub

GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="Arch"
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet usbcore.autosuspend=-1"                                        
GRUB_CMDLINE_LINUX=""

I don't have TLP installed, and this is also an issue I've even experienced with a lot of distros after the release of kernel 5.13. This week I've installed Arch, and It's the distro I've had my best experience with, but this is still a big issue and I appreciate any help. Thank you.

Offline

#2 2021-12-19 08:02:55

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

The udev rule matches the same device as the wiki example, so I guess it's a blind copy-and-fail and you don't actually have that device nor suspect it to be the cause of the problem?
Did you check the autosuspend state of individual devices and the usbcore module before/after suspending? What makes you think the autosuspend feature is the issue here?
A common cause is a single device (could be HW or the specific kernel module) not responding properly to the (inevitable, you're suspneding…) power cycle and nuking the entire bus.
(I have that w/ some dvb-dongle)

lsusb -tv

Offline

#3 2021-12-19 15:04:58

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

So your suggestion is to individually whitelist/blacklist every device to see if it's causing any issues? I ran lsusb -tv and got this:

/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/2p, 10000M
    ID 1d6b:0003 Linux Foundation 3.0 root hub
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
    ID 1d6b:0002 Linux Foundation 2.0 root hub
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/2p, 10000M
    ID 1d6b:0003 Linux Foundation 3.0 root hub
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
    ID 1d6b:0002 Linux Foundation 2.0 root hub
    |__ Port 3: Dev 2, If 0, Class=Video, Driver=uvcvideo, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 3: Dev 2, If 1, Class=Video, Driver=uvcvideo, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 3: Dev 2, If 2, Class=Application Specific Interface, Driver=, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 4: Dev 3, If 1, Class=Wireless, Driver=btusb, 12M
        ID 8087:0029 Intel Corp. AX200 Bluetooth
    |__ Port 4: Dev 3, If 0, Class=Wireless, Driver=btusb, 12M
        ID 8087:0029 Intel Corp. AX200 Bluetooth

Offline

#4 2021-12-19 15:14:12

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

My suggestion was to check whether the autosuspend setting actually deviates from "disabled" for any device.

Anyway,  there's a webcam and bluetooth - if you can, the most reliable approach is to deactivate them in the UEFI settings.
Otherwise you'll have to blacklist the relevant kernel modules, https://wiki.archlinux.org/title/Kernel … acklisting (use the /bin/true variant - do NOT blacklist xhci_hcd, only uvcvideo and btusb)

Also, because of the S3 invocation: do you have a parallel windows installation and have you seen the 3rd link below?

Offline

#5 2021-12-19 20:40:51

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

Good evening

I set blacklist parameters for btusb and uvcvideo modules which are shown when I press "e" while grub is showing up, and I also created a .conf file in /etc/modprobe.d (I named it asissue.conf), after that ran mkinitcpio -P, yet my issue still stands.

Here is what lsusb -tv looks like now, the modules for btusb and uvcvideo don't appear now:

/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/2p, 10000M
    ID 1d6b:0003 Linux Foundation 3.0 root hub
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
    ID 1d6b:0002 Linux Foundation 2.0 root hub
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/2p, 10000M
    ID 1d6b:0003 Linux Foundation 3.0 root hub
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
    ID 1d6b:0002 Linux Foundation 2.0 root hub
    |__ Port 3: Dev 2, If 0, Class=Video, Driver=, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 3: Dev 2, If 1, Class=Video, Driver=, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 3: Dev 2, If 2, Class=Application Specific Interface, Driver=, 480M
        ID 0408:5425 Quanta Computer, Inc. 
    |__ Port 4: Dev 3, If 1, Class=Wireless, Driver=, 12M
        ID 8087:0029 Intel Corp. AX200 Bluetooth
    |__ Port 4: Dev 3, If 0, Class=Wireless, Driver=, 12M
        ID 8087:0029 Intel Corp. AX200 Bluetooth

I did look into Windows Fast Boot, and I disabled it. I am currently dual booting Win 10 and Arch on two separate drives. The default boot drive is Arch; I press f9 and select the other drive whenever I need to go to windows, which is fine for my use case.

Last edited by pinkfloofx (2021-12-19 20:42:20)

Offline

#6 2021-12-19 21:37:43

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

two separate drives. The default boot drive

Not relevant to the issue.
Un-blacklist the modules, make sure to properly reboot windows (not only shutdown) and archlinux after disabling fast-start (which is NOT the fast boot option in your BIOS) to was  over the boards ACPI tables- for the perceived symptoms it's incredibly likely to have been the cause (not 100% but more than 99%)

Offline

#7 2021-12-20 01:15:41

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

My bad, I did disable Fast Start now, un-blacklisted all modules and rebooted in both OS's. Yet, the USB ports are still unreachable in Arch after suspend.

Offline

#8 2021-12-20 07:51:21

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 8,842
Website

Re: USB autosuspend issue (can't disable)

Have you actually checked the autosuspend settings? seth has asked several times without a clear answer.

cat /sys/module/usbcore/parameters/autosuspend

If it is applied then perhaps try adding the xhci_hcd module to a file under /etc/modules-load.d/. That would only be appropriate if the lsusb output showed the drivers unloaded after suspend though. It is unclear if the last supplied output is from a non-working system.


Jin, Jîyan, Azadî

Offline

#9 2021-12-20 22:38:21

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

Hello, so I checked the autosuspend settings (I didn't understand then how to do it), after typing cat /sys/module/usbcore/parameters/autosuspend, I get -1 which is what I've been writing in the udev rules. Thanks for clarifying that.

I made a file called /etc/modules-load.d/asload.conf and only wrote xhci_hcd on it, after that ran mkinitcpio -P, rebooted and the issue is still there after suspend.

Offline

#10 2021-12-21 08:33:07

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

Have you checked dmesg/the system journal for errors on the bus? If a single device goes wild, it'll likely stick out.

Offline

#11 2021-12-21 17:37:29

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

Good morning

I was checking dmesg, I don't see anything in red or that says error in the usb hubs, I will show the output regarding the usb port modules and some other modules with errors just in case


USB

[    1.311345] xhci_hcd 0000:07:00.3: xHCI Host Controller
[    1.311362] xhci_hcd 0000:07:00.3: new USB bus registered, assigned bus number 1
[    1.311472] xhci_hcd 0000:07:00.3: hcc params 0x0268ffe5 hci version 0x110 quirks 0x0000020000000410
[    1.311855] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.15
[    1.311858] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.311859] usb usb1: Product: xHCI Host Controller
[    1.311860] usb usb1: Manufacturer: Linux 5.15.10-arch1-1 xhci-hcd
[    1.311862] usb usb1: SerialNumber: 0000:07:00.3
[    1.312008] hub 1-0:1.0: USB hub found
[    1.312015] hub 1-0:1.0: 4 ports detected
[    1.312187] xhci_hcd 0000:07:00.3: xHCI Host Controller
[    1.312189] xhci_hcd 0000:07:00.3: new USB bus registered, assigned bus number 2
[    1.312191] xhci_hcd 0000:07:00.3: Host supports USB 3.1 Enhanced SuperSpeed
[    1.312202] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[    1.312213] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.15
[    1.312215] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.312216] usb usb2: Product: xHCI Host Controller
[    1.312217] usb usb2: Manufacturer: Linux 5.15.10-arch1-1 xhci-hcd
[    1.312218] usb usb2: SerialNumber: 0000:07:00.3
[    1.312285] hub 2-0:1.0: USB hub found
[    1.312298] hub 2-0:1.0: 2 ports detected
[    1.312755] xhci_hcd 0000:07:00.4: xHCI Host Controller
[    1.312766] xhci_hcd 0000:07:00.4: new USB bus registered, assigned bus number 3
[    1.312877] xhci_hcd 0000:07:00.4: hcc params 0x0268ffe5 hci version 0x110 quirks 0x0000020000000410
[    1.313296] usb usb3: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.15
[    1.313300] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.313302] usb usb3: Product: xHCI Host Controller
[    1.313304] usb usb3: Manufacturer: Linux 5.15.10-arch1-1 xhci-hcd
[    1.313306] usb usb3: SerialNumber: 0000:07:00.4
[    1.313677] hub 3-0:1.0: USB hub found
[    1.313709] hub 3-0:1.0: 4 ports detected
[    1.314055] sdhci: Secure Digital Host Controller Interface driver
[    1.314059] sdhci: Copyright(c) Pierre Ossman
[    1.314298] xhci_hcd 0000:07:00.4: xHCI Host Controller
[    1.314304] xhci_hcd 0000:07:00.4: new USB bus registered, assigned bus number 4
[    1.314309] xhci_hcd 0000:07:00.4: Host supports USB 3.1 Enhanced SuperSpeed
[    1.314332] usb usb4: We don't know the algorithms for LPM for this host, disabling LPM.
[    1.314360] usb usb4: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.15
[    1.314363] usb usb4: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.314366] usb usb4: Product: xHCI Host Controller
[    1.314367] usb usb4: Manufacturer: Linux 5.15.10-arch1-1 xhci-hcd
[    1.314369] usb usb4: SerialNumber: 0000:07:00.4

Error

[    2.312093] sp5100_tco: SP5100/SB800 TCO WatchDog Timer Driver
[    2.312318] sp5100-tco sp5100-tco: Using 0xfeb00000 for watchdog MMIO address
[    2.312326] sp5100-tco sp5100-tco: Watchdog hardware is disabled
[    2.318550] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[    2.318760] platform regulatory.0: Direct firmware load for regulatory.db failed with error -2

there's also some errors regarding ACPI, looked a little into it and it may cause issues after sleep/suspend

[    0.431568] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P000 (20210730/dspkginit-438)
[    0.431573] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P001 (20210730/dspkginit-438)
[    0.431574] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P002 (20210730/dspkginit-438)
[    0.431576] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P003 (20210730/dspkginit-438)
[    0.431577] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P004 (20210730/dspkginit-438)
[    0.431578] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P005 (20210730/dspkginit-438)
[    0.431579] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P006 (20210730/dspkginit-438)
[    0.431581] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P007 (20210730/dspkginit-438)
[    0.431582] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P008 (20210730/dspkginit-438)
[    0.431583] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P009 (20210730/dspkginit-438)
[    0.431584] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00A (20210730/dspkginit-438)
[    0.431585] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00B (20210730/dspkginit-438)
[    0.431587] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00C (20210730/dspkginit-438)
[    0.431588] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00D (20210730/dspkginit-438)
[    0.431589] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00E (20210730/dspkginit-438)
[    0.431590] ACPI Error: AE_NOT_FOUND, While resolving a named reference package element - \_PR_.P00F (20210730/dspkginit-438)

I'm not sure how much any of this helps, though I really am thankful for all the help. This is an issue I've had in this pc regardless of distro

Offline

#12 2021-12-21 21:13:07

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

You're looking for whatever is printed around the S3 - it will not necessarily say "error" nor "usb"

Offline

#13 2022-01-11 20:40:49

pinkfloofx
Member
Registered: 2021-12-19
Posts: 7

Re: USB autosuspend issue (can't disable)

Hello, I know I dissapeared after a few weeks, holidays came up and I got a little burnt out, but now after getting back to this issue, I realized I had to run 'dmesg' after waking from suspend in order to actually see the errors in the log, which are these:

[ 1052.211781] ACPI: \_SB_.PLTF.P00F: Found 3 idle states
[ 1052.212333] CPU15 is up
[ 1052.213198] ACPI: PM: Waking up from system sleep state S3
[ 1052.219576] ACPI: EC: interrupt unblocked
[ 1052.646282] ACPI: EC: event unblocked
[ 1052.656334] pci 0000:00:00.2: can't derive routing for PCI INT A
[ 1052.656340] pci 0000:00:00.2: PCI INT A: no GSI
[ 1052.666313] usb usb1: root hub lost power or was reset
[ 1052.666318] usb usb2: root hub lost power or was reset
[ 1052.672988] usb usb3: root hub lost power or was reset
[ 1052.672992] usb usb4: root hub lost power or was reset

after reading about ACPI modules, I found that this is likely an issue regarding a DSDT in the ACPI (which is not surprising given I'm using an HP Omen laptop)

Theres other options below in the article, but I still think it's too early to add parameters like "acpi=off", but I'll be doing my best to look into changing the DSDT. I don't know how long it will take me to study this and apply this fix, but I will make a followup with results.

If there's anything I am missing or anything that can help, I appreciate it, and thank you. Just thought I'd do a followup

Last edited by pinkfloofx (2022-01-11 20:42:08)

Offline

#14 2022-01-11 21:13:52

seth
Member
Registered: 2012-09-03
Posts: 66,162

Re: USB autosuspend issue (can't disable)

lspci - is 0000:00:00.2 the iommu?
You could then try passing "iommu=soft" to the kernel and see whether that has any impact

Offline

Board footer

Powered by FluxBB