4

My suspend did not correctly since I installed a USB 3 extension card in my PC. Instead of going to S3, the computer just woke up instantly. dmesg gave the hint "usb_dev_suspend+0x0/0x20 returns -2" so I rmmod'ed the "xhci_hcd" module which did the trick.

Is there a good way for me to work around this? The builds from the Kernel Mainline PPA did not help, unfortunately, and blacklisting the module is not my favorite option. Where is the best place for me to report this issue?

1

4 Answers 4

2

This is a known bug: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/522998

From there:

If SUSPEND_MODULES="xhci" is added to /etc/pm/config.d/unload_module then the system can suspend normally.

And a comment on there also points at Post #7 of this thread: http://ubuntuforums.org/showthread.php?t=1444822

Similar stuff and lots of people saying it works. Hopefully it will.

1
  • Nowadays we use systemd, so you would put a script in /lib/systemd/system-sleep, see ` man systemd-sleep`
    – am70
    Oct 9, 2019 at 7:04
1

In addition to what Oli said in that post, there are known troubles if you have a built-in media card reader or if you have mounted USB (flash or rotating) storage at the time of the suspend request.

Add a script /etc/pm/sleep.d/00_fixMounted.sh and make it owned by root and executable. This script should perform umount on any mounted media-card and USB storage. On Ubuntu, they are mounted at /mnt/media/* by default.

I made considerable progress removing module "usb_storage" after un-mount.

There are other known troubles with USB connected devices like cameras and such. The above would handle any storage components of those devices, but you would need to de-activate the other parts somehow separately.

Bonne chance, ~~~ 0;-Dan

0

See Maco's answer to this question, which outlines how to blacklist (well, remove really) the module when you suspend, then reload it when you resume.

As a follow up, you can you see my specific edit to the /etc/default/acpi-support file in this answer.

No guarantees with this stuff though. You might have to experiment a bit to get it all working. In some cases, (a Sony Viao WLAN card), I can't get the hardware to resume at all after suspend, regardless of how I edit this file.

Good luck.

0

Nowadays you would put script in /lib/systemd/system-sleep/ instead of /etc/pm/sleep.d. I use this script

#!/bin/sh
case $1/$2 in
  pre/*)
    echo "Removing 'xhci' for $2..."
    modprobe -r xhci
    ;;
  post/* )
    echo "Waking up from $2 , adding 'xhci' ..."
    modprobe xhci
    ;;
esac

and then

chmod +x

your script

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .