> Ah, but when people say “power management”, what they usually mean is “suspend”. See, ancient x86 platforms (where “ancient” means “everything prior to 2015 or so”) don’t have reasonable real idle power management like Apple Silicon Macs do.
Well, I've been perfectly happy with the "ancient" power management of my computers. It took a decade or two until suspend/resume actually _worked_ most of the time, and now all of that has been swapped out wholesale by a set of states that are at least an order of magnitude more complicated.
Apparently on newer chipsets, there is no such thing as "suspend to RAM" anymore. Instead, they rely on the OS to micro-manage the sleep states of all the various component that make up the system. I can see this being effective in smartphones where one vendor (Apple, Google) owns the whole stack of hardware, firmware, and software plus a large chunk of every third-party application by tightly controlling what code can run. They can actually run functional tests on the whole stack under varying conditions and have access to every part to debug issues.
Heck, it probably works great on Apple computers for the same reasons. But on general-purpose computers made up of components from dozens of manufacturers running dog-knows-what software and drivers, I don't think it can ever work well. There is already lots of evidence that these "modern" intermediate sleep states are causing real problems not only for Linux users (poor battery life while running, high battery drain while suspended) but also Windows users whose laptops bake themselves to death inside a backpack because a toolbar widget or something woke the system up at 3 a.m. and it then decided to run Windows Update.
When I suspend my laptop, I want to know, with _certainty_, that it will stay suspended until I physically open it. From everything I've been reading, newer laptops offer no such guarantee. The only way to know that your computer won't wake up on its own is by powering it completely down, like we did in the 1990s. Not looking forward to that.
I am all for more power-efficient computers but introducing these new sleep states while throwing out the old ones completely really feels like some backwards pageantry.
> Well, I've been perfectly happy with the "ancient" power management of my computers. It took a decade or two until suspend/resume actually _worked_ most of the time, and now all of that has been swapped out wholesale by a set of states that are at least an order of magnitude more complicated.
This. I want suspend/deep sleep. I don't mind slow wake; and I definitely don't want bluetooth, wifi, etc running while it's supposed to be idle. 90% of the issues with Windows on Laptops waking and causing them to overheat in backpacks is because of this bullshit half-sleep/smart-sleep they've started adding and forcing users to live with.
At least let me, as an informed person, choose to allow my laptop to suspend still.
> I want suspend/deep sleep. I don't mind slow wake
Also, you don't need to keep the machine actually awake to wake up fast; I have laptops that are... more than a decade old now, that wake so fast from S3 that they're active by the time you get the lid open.
There’s no cost to “bluetooth wifi etc” being on and not doing anything unless you’re operating an RF chamber or have the security needs of a head of state.
It doesn’t significantly affect battery life; any time in your own life you’ve spent thinking about this would be better spent playing with your dog, or getting a dog so you can play with it.
Keeping WiFi and BT on usually means you're keeping the PCIe and USB links on (or at least waking up frequently), which means you're also preventing the processor from staying in a low-power state where all the IO is power-gated. Once the display is powered off, getting the rest of the components to be properly asleep can reduce idle power by another order of magnitude.
“On” is a UI state though; the actual power state of the hardware is up to it, and its idle power usage can be managed by things like offloading idle tasks to the wifi SoC so they don’t have to communicate with the rest of the machine.
That’s more well known for performance (where faster Ethernet interfaces do increasingly more offloading) but it works for power savings too.
Yeah, if you're offloading things to the wifi SoC, then you're giving it more power than I want to be spending when the machine is supposed to be asleep.
The power use could be something like less than 1% battery a day though - I have smart home thermostats that are “on the network” all the time but run on battery for months, and that’s a much smaller battery.
That’s a reasonable thing to think about if you’re a wifi driver engineer. It’s not reasonable if you’re a hobbyist responsible for a single install in one laptop. It’s not really advancing the state of the art here.
This is how the laptops being discussed in the article actually do work. If PCs don’t work that way complain to Broadcom or nearest motherboard OEM. They have much worse problems though, like only just getting efficiency cores.
No, but what it does do is randomly wake the laptop when it runs across an Access Point it recognizes or when a BT device randomly wants to wake it. What you're describing as the ideal is what I can already get if they would just re-enable true S3 or S4.
That is the state I want, not their glorified hybrid S1. If you want it, go for it; no one is saying remove it, just re-enable S3/S4.
I’m a Windows user, and I can confirm. My HP ProBook 445 G8 laptop doesn’t support any of the proper S1-S3 sleep states.
Luckily, I discovered that before any hardware has failed due to overheating, by reading the output of `powercfg /availablesleepstates` console command. To workaround, I have set up the OS to hibernate when the lid is closed, instead of going to sleep.
> Heck, it probably works great on Apple computers for the same reasons.
Nope, the very first (and last) time that I suspended my Macbook and stuffed it in a backpack, it was hot to the touch when I went to go take it out. I looked online and everyone was just advising each other to power down every time they wanted to take their laptop anywhere. So no, Apple can't get it right either. FFS, will OS vendors please just let me hibernate to disk like the old days?
sorry to hear your bad experience. i close the lid multiple times a day on 2 m1 macbooks and i really have to rake my brains to remember when it failed. in 7 years i had the "taking it out hot from a backpack" exactly 1x (with intel). that's a track record i am super happy with.
on the other hand i got macos black screens of death for a year as the last stage of every reboot... apple is by far not flawless. but i cant imagine using windows as a daily driver. the shit to put up with is just endless. and it makes my eyes bleed
It is there, but hibernation is a pain to implement since it doesn’t have much in common with other OS functions, so eg device driver engineers don’t enjoy implementing/maintaining it much.
It is useful in laptops as a last ditch effort to avoid losing data when the battery dies, but that’s one reason phones don’t implement it even though their batteries die much more often.
The weird thing is, not even Mac OS is doing it on that hardware: they just do proper S3 suspend. I think the advantage of this "modern standby" feature is that you can sometimes wake up and do some minor processing. But I'm not sure that linuxes actually make use of that functionality.
> But I'm not sure that linuxes actually make use of that functionality.
It's funny, the answer is both yes and no. I have a funky Skylake CPU in my current travel laptop, and one of it's cool party tricks is that Linux can drop the CPU into suspend state just by limiting the CPU to it's lowest frequency. I've seen it drop all the way down to 400mhz when leaving it alone, which gives me a chuckle.
Totally useless for the "power nap" functionality you're thinking of, but ironically useful for certain other use-cases.
The Linux kernel does all the PM stuff nowadays automatically afik. At least I didn't touch any of this settings for a long time and it just works. When not compiling anything or something that like, but surfing, editing text (in something besides IDEA), watching videos, or such "light tasks" the computer has only a few percent CPU load at max, the fan is off, it has room temperature, and runs for hours on battery.
I would also support what one of the siblings said: Explicitly pining the CPU to lower frequencies doesn't help much. For example web pages load much longer. I think a few hundred milliseconds at higher speed and then falling back into the idle mode doesn't cost much extra battery compared to up a few seconds of full CPU load at lower frequencies for a page load.
Yes, it safes battery to make the CPU slow. But than doing anything with the computer is also much slower and everything takes "forever" therefore. I'm not sure this is a net win when the battery lasts longer but you waste much more time waiting. A super slow computer feels worse in the end, imho.
It's just an interesting observation, I'm not really preaching any huge benefits here. When you tell the systemd power manager to enter max-efficiency mode it runs an interactive desktop in suspend-level frequencies. That's all I find interesting here.
Running the CPU constantly at 400MHz is likely to consume more power than bursty workloads at full speed. There are various linked clock domains, and if the CPU cores can't get into low power states then neither can other bits of hardware on the SoC.
Who says the CPU is running constantly at 400MHz? I assume for video to work at all like that it must by bypassing the CPU, and text editing would look to the machine like "all CPU cores idle... waiting... waiting... oh, the user pressed a button, let's handle that for 50ms, okay now we can idle while we wait for the slow human to press another key..."
I'm familiar with the race-to-idle theory, but even on the lowest power mode it will scale between 400-900mhz depending on the workload. If there was anything blocking the CPU or hogging cycles, it would be clocking a bit faster.
That being said, it's still not a huge power gain. I mostly do it to keep the system cool and the fan off.
This is why I power down my laptop physically and ensure startup is speedy. You simply can't trust suspending the laptop to not jack up the overall stability of the system after wakeup or drain the battery unnecessarily or whatever unforeseen disaster awaits you.
I can't stand other platforms comparatively. On Linux, I can start my laptop and be productive in the time other platforms take _to wake up from suspend_. No thanks
I remember that an older machine, a core 2 duo laptop that I had could stay in deep sleep for weeks and it’d function just fine after.
Modern laptops don’t seem to have this capability unfortunately. Both my Mac and Linux machine (even with windows) doesn’t seem to last as long these days.
In my experience, the macbook’s sleep mode isn’t very effective. But if I turn the machine entirely off and turn it back on later, it does a good job loading all my apps back the way they were. Functionally, the experience is similar to the old days of “hibernate”.
I don't know about AMD, but I'm pretty sure it's a thing with newer Intel chipsets (there was lots of hubbub about it when the Framework laptop came out, which I was following at the time).
Well, I've been perfectly happy with the "ancient" power management of my computers. It took a decade or two until suspend/resume actually _worked_ most of the time, and now all of that has been swapped out wholesale by a set of states that are at least an order of magnitude more complicated.
Apparently on newer chipsets, there is no such thing as "suspend to RAM" anymore. Instead, they rely on the OS to micro-manage the sleep states of all the various component that make up the system. I can see this being effective in smartphones where one vendor (Apple, Google) owns the whole stack of hardware, firmware, and software plus a large chunk of every third-party application by tightly controlling what code can run. They can actually run functional tests on the whole stack under varying conditions and have access to every part to debug issues.
Heck, it probably works great on Apple computers for the same reasons. But on general-purpose computers made up of components from dozens of manufacturers running dog-knows-what software and drivers, I don't think it can ever work well. There is already lots of evidence that these "modern" intermediate sleep states are causing real problems not only for Linux users (poor battery life while running, high battery drain while suspended) but also Windows users whose laptops bake themselves to death inside a backpack because a toolbar widget or something woke the system up at 3 a.m. and it then decided to run Windows Update.
When I suspend my laptop, I want to know, with _certainty_, that it will stay suspended until I physically open it. From everything I've been reading, newer laptops offer no such guarantee. The only way to know that your computer won't wake up on its own is by powering it completely down, like we did in the 1990s. Not looking forward to that.
I am all for more power-efficient computers but introducing these new sleep states while throwing out the old ones completely really feels like some backwards pageantry.