Bug 198703

Summary: [X86_64] STR: system wakes up immediately after suspend on ThinkPad X220
Product: Drivers Reporter: Peter Weber (peter.weber)
Component: BluetoothAssignee: acpi_config-hotplug
Status: RESOLVED MOVED    
Severity: normal CC: pmenzel+bugzilla.kernel.org
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 4.15 Subsystem:
Regression: Yes Bisected commit-id:
Attachments: journalclt -b
lspci
lsusb
lscpu
installed packages from cmd pacman -Q
journalctl -b from old kernel 4.14 with working suspend (some days ago)
dmesg
acpidump -o
cat /proc/interrupts before suspend
cat /proc/interrupts after resume

Description Peter Weber 2018-02-06 19:40:22 UTC
Created attachment 274027 [details]
journalclt -b

Hello!
Since Kernel 4.15 Suspend-To-RAM (S3) is broken. If I suspend via "systemctl suspend" or Fn+Suspend the laptop immediatley resumes.

Steps to reproduce:
1.) Boot
2.) Login on TTY or GNOME/Wayland
3.) $ systemctl suspend

What happens:
Laptop resumes immediatley.

What should happend:
Laptop should stay in suspend.

Thank you
Comment 1 Peter Weber 2018-02-06 19:41:02 UTC
Created attachment 274029 [details]
lspci
Comment 2 Peter Weber 2018-02-06 19:41:15 UTC
Created attachment 274031 [details]
lsusb
Comment 3 Peter Weber 2018-02-06 19:41:34 UTC
Created attachment 274033 [details]
lscpu
Comment 4 Peter Weber 2018-02-06 19:42:06 UTC
Created attachment 274035 [details]
installed packages from cmd pacman -Q

Archlinux
Comment 5 Peter Weber 2018-02-06 19:49:41 UTC
Created attachment 274037 [details]
journalctl -b from old kernel 4.14 with working suspend (some days ago)
Comment 6 Peter Weber 2018-02-06 19:49:56 UTC
Created attachment 274039 [details]
dmesg
Comment 7 Peter Weber 2018-02-06 20:01:59 UTC
I'have a workaround "powertop --auto-tune" allows to suspend:

1.) Boot
2.) Login as root
3.) # powertop --auto-tune
4.) logout
5.) Login as any user
6.) $ systemctl suspend # laptops stays in suspend

Probably the helps, maybe some hardware is set in wrong state without "powertop --auto-tune"?
Comment 8 Peter Weber 2018-02-07 13:05:47 UTC
An other ThinkPad T420 is not affected, the differences are:

X220           |    T420
USB 3.0        |    -
Intel SSD      |    Samsung SSD
UEFI (1.43)    |    BIOS (1.46)
Bluetooth 4.0* |    Bluetooth 3.0


* Chip from newer ThinkPad, they are compatible
Comment 9 Peter Weber 2018-02-07 21:20:43 UTC
Argggh :(
It not so reliable to reproduce than I thought. If your machine is not immediatley resuming from suspend, suspend and resume the laptop around five or ten times in a row (you can do that quickly). Seem to depend on some internal state of something.
Comment 10 Peter Weber 2018-02-08 10:48:21 UTC
Okay. There is one signifcant difference between the X220 und the T420, the first one has the package intel-ucode installed and it is loaded during bootup. Furthermore, an microcode-update from 2013 is applied, while the BIOS/UEFI is from 2016 and should (likely?) include any existing microcode-updates.

I have done this:
# pacman -Rns intel-ucode
# grub-mkconfig -o /boot/grub/grub.cfg
# reboot

I've done more than 20 successful suspends to S3 since yesterday evening, none failed. I keep an eye on this, if it resolves the issue I will close the bug.
Comment 11 Peter Weber 2018-02-10 18:34:47 UTC
It's not gone, I was just very lucky.
Comment 12 Peter Weber 2018-02-10 18:35:08 UTC
Created attachment 274093 [details]
acpidump -o
Comment 13 Peter Weber 2018-02-10 18:35:42 UTC
Created attachment 274095 [details]
cat /proc/interrupts before suspend
Comment 14 Peter Weber 2018-02-10 18:36:16 UTC
Created attachment 274097 [details]
cat /proc/interrupts after resume
Comment 15 Peter Weber 2018-02-11 12:29:09 UTC
Related to bluetooth, will move.