6

So from what I can tell, there's hundreds upon hundreds of "can't suspend" questions on here already, but I've been digging through them and none of the proposed solutions work, so here I am.

I've got an HP Envy x360 that's been running Ubuntu 18.04 fine for a year now. Last week, it started having an issue where the device won't suspend correctly anymore. Specifically, when I suspend the device and then try to wake it up again, all it shows is a black screen (no cursor or anything), and nothing I do affects the display at all, short of killing the power and restarting the device. Suspending via any of the following methods has the same result

  • Using the "Suspend" option in the main menu
  • Closing the laptop lid
  • Simply waiting half an hour for the device to suspend of its own accord

The device is actually not suspending correctly; it's not simply a video issue, as CTRL+ALT+F1, et al have no effect, and I cannot ssh into the device after the botched wake-up either. The power LED for the device remains on even when the device allegedly is suspended.

/sys/power/mem_sleep contents:

[s2idle]

Relevant entries from /var/log/kern.log:

Mar 27 15:51:33 silvenvius kernel: [ 1580.034024] wlo1: deauthenticating from 08:02:8e:d1:5f:90 by local choice (Reason: 3=DEAUTH_LEAVING)
Mar 27 15:51:33 silvenvius kernel: [ 1580.178236] PM: suspend entry (s2idle)

(Yes, that's it. The next entries are from the reboot after I force kill it)

I should also note that in the course of fixing this problem, I formatted my disk and reinstalled Ubuntu from a USB, to no avail. So I'm currently running a fresh Ubuntu which exhibits this problem, on a device that didn't used to have the problem.

What I've tried that doesn't work:

However, if I boot from an Ubuntu 18.04.4 LiveUSB, suspend works. ??

I'm slightly running out of options here, and my nuclear option of "reinstall from scratch" has already failed, so any further advice on how to debug and ideally fix this would be greatly appreciated.

K7AAY
  • 17,202
Silvio Mayolo
  • 203
  • 2
  • 12
  • 1
    I'm also experiencing this issue. I have opened a kernel bug here : https://bugzilla.kernel.org/show_bug.cgi?id=207181 Did you make any progress in getting it working ? – jman6495 Apr 10 '20 at 01:06
  • I have same issue. And even on 20.04. Any idea? – lapor Apr 25 '20 at 19:15
  • 1
    Sadly, I have not. I ended up switching off Ubuntu because of this issue; Fedora has worked great for me. It's not the ideal solution to switch OS because of something like this, but I suppose it works. – Silvio Mayolo Apr 27 '20 at 13:28
  • Too bad. I managed to install Fedora 32 beta on (this week should be final release), but suspend still does't work. Did you manually changed anything? Thanks – lapor Apr 28 '20 at 09:11
  • Not a thing, I'm afraid. I'm just running a standard Fedora 31, and it worked out of the box. I'm sorry to hear the same didn't work out for you. – Silvio Mayolo Apr 29 '20 at 13:22
  • What CPU do you have? What is the exact model? I think this can be solved by upgrading the BIOS. – Konrad Gajewski Apr 29 '22 at 15:10
  • @KonradGajewski less /proc/cpuinfo shows Intel(R) Core(TM) i7-8565U CPU @ 1.80GHz. – Silvio Mayolo Apr 29 '22 at 16:56

1 Answers1

4

I am suffering the same problems, while I have not yet solved them yet, I have narrowed down the problem. I hope this explanation, and the technical keywords provided therein, will help more people identify what is going on.

TL;DR: On some 'modern' hardware, the BIOS no longer reports the classic "S3/suspend-to-ram" power state, in favour of a new Microsoft-only feature "modern suspend" (also known as "S0ix" or "s2idle").
Additionally: there are resume-problems within the AMDGPU graphics driver


For the first problem (missing S3-support), the only proper fix for this is that the laptop manufacturer releases an updated BIOS, that allows one to switch suspend modes between "modern Windows 10" and "classic S3". (The way Microsoft specified the modern suspend is mutually exclusive with classic deep sleep, BIOS can't advertise both at the same time)

The physical symptoms of this problem are that, upon entering suspend, your power-LED never starts blinking, it just stays on.

There are workarounds possible, by providing updated BIOS-tables during boot. However, this is a non-trivial process, that could permanently damage hardware if done wrong. (I am currently debating returning the laptop vs. trying this)


The second problem is that in some/many cases AMDGPU hangs on resume. If your Laptop enters suspend succesfully (blinking power-LED), but the screen doesn't come back on after waking the machine, you are having this problem. In this situation, you should still be able to SSH into the machine. If you can SSH into the machine, the dmesg log will be flooded with dozens of errors similar to

[  746.326429] [drm:amdgpu_job_run [amdgpu]] *ERROR* Error scheduling IBs (-22)
[  746.326444] amdgpu 0000:04:00.0: couldn't schedule ib on ring <sdma0> 

You can identify if missing S3-support is the problem with the following commands, which query the kernel which suspend-modes it identified during boot:

dmesg | grep -i acpi | grep supports
[    0.417055] ACPI: (supports S0)

As you can see, on my Envy x360, "S3"/suspend-to-ram is missing. (So is S4/suspend-to-disk)

cat /sys/power/mem_sleep
[s2idle]

What we are hoping for is that the "deep" entry is also present. The [] indicate which state is default.

More information here, including workarounds that involve force-overriding your ACPI-tables at boot.

  • I think S3 can be added by upgrading the BIOS. – Konrad Gajewski Apr 30 '22 at 17:00
  • @KonradGajewski: No it can´t, None of the available bioses (current most-recent for my laptop is F22) have this option, nor mention it in their release notes. HP would have to create a new BIOS with this feature included, but they don´t. – Jules Kerssemakers May 02 '22 at 12:17