Views:
8,269β
Votes: 4β
Tag :
suspend
Link:
π See Original Answer on Ask Ubuntu β§ π
URL:
https://askubuntu.com/q/1050596
Title:
How to debug suspend?
ID:
/2018/06/29/How-to-debug-suspend_
Created:
June 29, 2018
Edited: June 12, 2020
Upload:
September 15, 2024
Layout: post
TOC:
false
Navigation: false
Copy to clipboard: false
The symptoms:
- Pressing suspend brings my computer to a state where it has a blinking cursor, the fans are running, it seems that the HD has turned off (I think), and I canβt do anything to bring it back from this state (short of a hard reboot).
- Possibly related: My fans stay on even after a shutdown, and even then, I have to press the power button for five seconds before I can start it up again.
- I donβt know what logs to look at to debug the problem, and I imagine theyβd get nuked on reboot anyway.
My go to site for many Linux problems is Arch Linux. Here is what is posted about suspend/resume problems similar to yours:
Instantaneous wakeups from suspend
For some Intel Haswell systems with the LynxPoint and LynxPoint-LP chipset, instantaneous wakeups after suspend are reported. They are linked to erroneous BIOS ACPI implementations and how the xhci_hcd
module interprets it during boot. As a work-around reported affected systems are added to a blacklist (named XHCI_SPURIOUS_WAKEUP
) by the kernel case-by-case.[2]
Instantaneous resume may happen, for example, if a USB device is plugged during suspend and ACPI wakeup triggers are enabled. A viable work-around for such a system, if it is not on the blacklist yet, is to disable the wakeup triggers. An example to disable wakeup through USB is described as follows.[3]
To view the current configuration:
$ cat /proc/acpi/wakeup
Device S-state Status Sysfs node
...
EHC1 S3 *enabled pci:0000:00:1d.0
EHC2 S3 *enabled pci:0000:00:1a.0
XHC S3 *enabled pci:0000:00:14.0
β¦
The relevant devices are EHC1
, EHC2
and XHC
(for USB 3.0). To toggle their state you have to echo the device name to the file as root.
# echo EHC1 > /proc/acpi/wakeup
# echo EHC2 > /proc/acpi/wakeup
# echo XHC > /proc/acpi/wakeup
This should result in suspension working again. However, this settings are only temporary and would have to be set at every reboot. To automate this take a look at systemd#Writing unit files. See BBS thread for a possible solution and more information.
The entire Arch Linux article above on Suspend/Resume is a great reference for many areas:
1 Low level interfaces
1.1 kernel (swsusp)
1.2 uswsusp
2 High level interfaces
2.1 systemd
3 Hibernation
3.1 About swap partition/file size
3.2 Required kernel parameters
3.2.1 Hibernation into swap file
3.3 Configure the initramfs
4 Troubleshooting
4.1 ACPI_OS_NAME
4.2 VAIO Users
4.3 Suspend/hibernate doesn't work, or not consistently
4.4 Wake-on-LAN
4.5 Instantaneous wakeups from suspend