Baytrail suspend, S3 vs. S0i3

      Kommentare deaktiviert für Baytrail suspend, S3 vs. S0i3

For some time now I am working on the Thinkpad Tablet 10 with Linux. By now it works pretty nicely – apart from still happening freezes 🙁 One major annoyance though is the very bad power saving during standby aka suspend.

What I found this far is that Linux relies on the ACPI BIOS support for the different power saving states. Concerning standby or suspend states there are the usual S3 and S4 states which are the common suspend-to-ram and suspend-to-disk (aka hibernate) states. The ACPI BIOS implementation needs to support S3 in order for Linux to use it. There seem to be Baytrail implementations with BIOS support for S3 but the Thinkpad Tablet 10 does not.

In Linux if you look at the possible suspend states you will see this (on the TPT10):

# cat /sys/power/state 
freeze disk

ACPI S3 would be called “mem” and is obviously missing, i.e. not supported. (Update: starting from 4.11.x “mem” will show up but it will use “freeze” and not mem). The freeze state is the so called “suspend-to-idle” which means all devices drivers are called to suspend their devices and the CPU and peripheral clocks are stopped. This mode does work by now on Baytrail, i.e. the device can be “frozen” and “thawed” again.

Baytrail CPUs offer different suspend schemes, e.g. S0I3. These modes are designed especially for embedded and mobile devices and are supposed to support modes like a connected standby, i.e. a device stays connected to a network (e.g. WiFi) and can wakeup on network events. S0I3 will also put the DDR DRAM into so called self refresh mode, i.e. the least power consuming state without loosing its content.

Linux is supposed to enter S0i3 on platforms supporting it when entering the S0i3 state. But pretty obviously the TPT10 never enters S0i3 when frozen:

# cat /sys/kernel/debug/pmc_atom/sleep_state 
S0IR Residency: 0us
S0I1 Residency: 0us
S0I2 Residency: 0us
S0I3 Residency: 0us
S0 Residency: 14320163200us

It always remains at 0us for any of the S0Ix states. This is pretty annoying since this prevents the system from low power usage during suspend. I am pretty sure that this is the reason why my battery is flat after just ~3 days of standby. Comparable devices keep up at least for two weeks or more.

I guess that Win10 supports this mode and can achieve much better standby times 🙁 I also read somewhere that BIOS support is also needed for S0Ix modes but I have no idea how to verify if the TPT10 BIOS does support them. I also have not yet found any way to debug this, i.e. to find why exactly S0I3 is never entered. A quite extensive research on the net just gives various pointers towards the i915 GPU driver, weird.

So if anyone can give me a hint, please contact me 🙂