endeavour / DellXps7390-2in1-Manjaro-Linux-Fixes

Kernel patches and tweaks to get the Dell XPS 7390 2-in-1 with 10th Gen Intel CPUs functioning on Manjaro Linux
23 stars 3 forks source link

Use actual S3 for suspend #5

Closed inducer closed 4 years ago

inducer commented 5 years ago

On this Arch wiki page about what seems to be a somewhat similar machine, I learned that

 $ echo deep|sudo tee /sys/power/mem_sleep

will motivate the machine to go to actual S3. On my 7390 2-in-1, that does seem to work. Only the power button will wake the machine up from that, unlike in s2idle, where just looking at the machine wrong would do that. Unfortunately, the internal display doesn't recover after S3. But an externally attached monitor continues working great.

endeavour commented 4 years ago

Until there is a fix for the display I'm going to leave this open... it's not really something I can recommend for a laptop.

arkadius commented 4 years ago

As a walkaround you can use s2idle with suspend-then-hibernate option for lid close: https://askubuntu.com/a/1075861 I know that it isn't perfect but it works well.

endeavour commented 4 years ago

As a walkaround you can use s2idle with suspend-then-hibernate option for lid close: https://askubuntu.com/a/1075861 I know that it isn't perfect but it works well.

FYI if you have encrypted your disk then you need to change the grub config as explained here: https://forums.linuxmint.com/viewtopic.php?t=287015

inducer commented 4 years ago

Thanks! With 32 GiB of RAM, I had not budgeted for a swap partition. But I managed to get through a slightly harrowing procedure of resizing my encrypted root partition and can confirm that this is not at all a bad solution.

arkadius commented 4 years ago

FYI you don't need to extract extra partition for swap to make hibernate work. You can use swapfile, and add resume_offset parameter to /etc/default/grub and also to /etc/initramfs-tools/conf.d/resume if your root partition is encrypted. Sorry for late sharing @inducer ;-)

inducer commented 4 years ago

Heh. I had seen something about resume_offset before I made the change, but I convinced myself that "that can't possibly work with an encrypted root." Turns out I was wrong. And, thankfully, growing the partitions was much less scary than shrinking them. Thanks again!

endeavour commented 4 years ago

FYI I managed to fix the screen corruption when resuming from S3 sleep by going into the BIOS and disabling the following setting: POST Behaviour -> "Sign of Life" -> "Early Dell Logo Display"

Tested with bios 1.1.3 and linux kernel 5.5.2-1.

arkadius commented 4 years ago

Wow, it works! Thank you for sharing!