So while I get the "I just want sleep to work, dangit" attitude (it really should just work, to be honest) the fact is that it barely does work. Seriously, it took this long to realize that VRAM contents may not fit into RAM entirely, so powering down the drives that hold the swap should probably be postponed to the last moment.
It's pretty unbelievable when you think about it. The majority of mainstream progress on application state management has taken place in mobile operating systems and essentially amounts to the expectation that you won't lose data if and when your process is unexpectedly forced to terminate without user interaction. Forget actually picking up exactly where you left off.
And as long as I'm complaining. All of my sshfs mounts tend to break if I sleep-wake as well. Remounting them generally doesn't fix programs that were using them (for obvious reasons) - I usually have to manually close and reopen all of that.
Just change your fucking habits and move on. I think Linus Tech tips complained about a unrelated but equally frustrating issue with S0 awhile back. I fucking hate S0 it makes me feel like tech companies are trying to force people to have always on computers by removing S3 support entirely from modern hardware.
Power control is the kind of stuff that benefits from very tight integration, and PCs just don’t have that.
Firmware is seen by most vendors as a pure cost to minimize, so you get a fragmented market full of subcontractors delivering the bare minimum that is considered “working”. Manufacturers also know most people aren’t going to use a big part of the functions they’re supposed to provide to OSes, and no one is really checking them, so it’s very common for devices to have only partial support for things they supposedly do.
What's strange is that it never used to be a problem. There are five Windows laptops floating around our house at various times (mixture of work and personal) and suspend works properly on none of them. Oddly, it works on my personal laptop with Debian Stable almost every time, failing maybe 1/25 times. Other distros are about the same as Windows.
I don't get why S3 sleep had to die for this, but it did.
If you want your device to be off, power it off.
On Linux, you can run a systemd unit file that will trigger `rfkill` on sleep and a different `rfkill` invocation on wake and you effectively dodge all that crap because the laptop isn't connected to WiFi and thus will sit around realizing its spinning its wheels and wil shut down further down the s0 chain.
> I don't get why S3 sleep had to die for this, but it did.
Worse yet, the dirty little secret is that many laptops that offer both S0 and S3 will actually drain more energy in S3 than in S0 because the S3 mode has had poor QA.
(Any link to the video/docs for turning it off?)
For me, I have an M2 and no issues. Was worried about v1 issues (same for VisionPro—will wait until v2)
I'd rate my OpenBSD X1 as not terrible too. Not as smooth as MacBook but adequate.
My work mac (M1 Pro) occasionally locks up and reboots when waking from sleep too, at about the same frequency.
Always wondered why this was such a difficult problem to solve, seemingly irrespective of operating system. (Linux has never been acceptable or reliable in this respect, IME, regardless of distro and hardware configuration.)
Or Macintosh. My $DAYJOB Macbook sleeps properly about about 2 out of 10 times, at best. Most of the time it fails to sleep and by the next morning when I open it up, the battery is dead. :-(
For comparison, my System76 laptop running PopOS! sleeps perfectly, every time with no issues. shrug
You use a 20+ year old[1] PowerPC laptop for your dayjob?
Talk about hardware longevity!
[1]: Powerbooks were last made in 2006 I think?
Important to remember that work laptops typically install all sorts of crap spyware and fleet management software that causes the system to misbehave. That’s not as much on Apple although not protecting their brand against such software is on them.
Good thing it's all fixed now, eh! /s
Now its like an elderly nursing home patient who wakes up several times and raids the kitchen to eat all the time.
The fall of a once great OS is sad to see. I guess AI matters more to Microsoft than their Core OS nowadays.
I would have expected it with a cheap clone, but this was a fully integrated computer made by the same people who designed and manufactured the processor itself!
I can't remember if it ever fixed it - maybe after a year or two there were finally newer EFI and graphics drivers that fixed the issue, but maybe it never did? In the end I ended up getting a newer machine to replace it anyway and it became my home server so just runs Proxmox now and doesn't need to ever sleep...
There was, eventually, a Windows program which hacked the device to take it out of sleep. But I had no Windows OS on it. Before I got around to installing enough Windows, the NUC died for other reasons :-(
It also plagues Windows on custom PC builds, even when there are vendor drivers. Not every component plays nicely with suspend states, ASPM, C-sates, load line calibration, etc. And while often the capability exists natively to address issues (in BIOS, Linux, etc), how many people know how to start looking?
The computer locking up when said devices are removed and not properly going to sleep then is a different (much worse) issue
powercfg /lastwake
in a command window as admin.So it's not really a problem unless you really wanna do deeper sleeps.
the way I parsed this was; so it's not really a problem unless you want to use your computer the way you want to use it.
I get things are complicated, and hardware support is a mixed bag. But it doesn't have to be this way.
Chasing "real sleep" gives me nothing but pain. Also Android devices "sleep" fully awake so it's really "what people are doing".
Microsoft also went that route with the Surface line, it just never sleeps.
It seems like it's basically hardware whack-a-mole at this point. The only reason Apple does it reasonably well is they control more of the stack and they support less hardware. The only reason Windows does it better than Linux is they have more eyes on it.
I've interacted with him countless times on the kernel mailing list and bug tracker, he's literally paid by AMD to work on Linux support for AMD's consumer desktop hardware.
I have been buying System76 for about twenty years now, and this is has not been an issue for me either.
A lot of workarounds that are suggested for various issues are also not really viable. Some of the workarounds involve turning off different power-saving modes; however, the point of enabling sleep is often to increase the amount of usable time between charges, and turning off these power-saving modes can often dramatically shorten battery life.
But getting sleep to work (even S0ix!) is not impossible.
I have a bunch of handheld AMD 7840U and AMD 8840U devices that I have installed Arch Linux on: GPD Win Max 2, GPD Win Mini, GPD Win 4, Minisforum V3, OneXPlayer X1 Ryzen. These devices were not designed with Linux support in mind. I would be very surprised if the companies that made them ever tested them with Linux. Yet with just a small amount of work (generally fiddling with `/proc/acpi/wakeup` and `/sys/devices/*/*/*/power/wakeup` to disable sources of spurious wakeups,) I have gotten essentially flawless S0ix support (… on all but the newest OneXPlayer X1 Ryzen.)
(In general, out-of-the-box stock Linux kernel support on these devices is fantastic. Touchscreens work, pen input works, wifi and Bluetooth work well. The only gap I've seen is fingerprint reader support.)
I suspect that given how small these manufacturers are (and how small their production batches must be,) there's much less extreme-customization and tight-integration of components. This is visibly evident in the form-factors of these devices, which many millimeters thicker than they might otherwise be. (Of course, these devices are primarily advertised to a gaming audience who are eager to avoid the thermal-throttling that happens with ultra-thin devices like Surface Pro…) I partially suspect that the lack of extreme-customization, the lack of tight-integration, and the smaller production batches means that the manufacturers make much more conservative choices in components. Maybe this explains the exceptional Linux support?
Thanks
It's been solid on every business Thinkpad for a long long time for me and consistently seems people on Windows with the same models have more sleep problems.