4 ms·
This is a good example of a problem that's easy to talk about but difficult to fix: "tell CPU to sleep!" versus this whole lengthy article. Wondering now if
by detrites 3y ago
This is a good example of a problem that's easy to talk about but difficult to fix:
"tell CPU to sleep!" versus this whole lengthy article.
Wondering now if the issues with Linux laptop sleep are related or have similarity.
- lloeki 3y agoLinux should generally have no problem with CPU&al sleep, the problem is often devices around, waking up in weird orders or states, or not waking up at all, or not going to sleep. > The furi_hal_os_sleep() function performs tick suppression inside the OS domain. Reminds me that many eons ago I witnessed the introduction of CONFIG_NO_HZ in Linux, is it the default now? Combined with timer coalescing this makes for big energy savings. https://en.m.wikipedia.org/wiki/Tickless_kernel https://en.m.wikipedia.org/wiki/Tickless_kernel https://en.m.wikipedia.org/wiki/Timer_coalescing https://en.m.wikipedia.org/wiki/Timer_coalescing
- csdvrx 3y agoDo you use timer coalescing? Can you provide more detail? I'd be happy to return the favor with my use of NO_HZ and NO_HZ_FULL!
- lloeki 3y agoOn macOS, ever since Mavericks. Back then the update gave me +1~2hrs of battery life with my usage pattern. https://arstechnica.com/gadgets/2013/06/how-os-x-mavericks-works-its-power-saving-magic/ https://arstechnica.com/gadgets/2013/06/how-os-x-mavericks-w...
- azubinski 3y agoIt's a very basic task in any kind of professional embedded development.
- bradfa 3y agoIt's a very common task in embedded development to need to reduce sleep or idle power consumption but in my experience it's never basic nor easy to do it right. Lots of times engineering teams just punt the issue and the customer gets less than great battery life or some other poor compromise is made. Generally the hardest part is simply making sure that the device can wake up correctly and quickly enough under all situations. Also, tracking down unexpected power draws gets into a nice crossover between electrical and firmware design teams which can either be great or extremely frustrating for either side of that interaction.
- manv1 3y agoWaking up from sleep is an endemic problem across devices. Just google "waking up from sleep" and you'll see all kinds of stuff for both Windows and MacOS. I'm not sure Linux has deep sleep. I know it's been a problem on MacOS forever, like back in the 68k days. Some peripherals never come back from sleep and you have to power cycle them to get them to "wake up." And sometimes MacOS doesn't come back either.