Power Management on Linux, Part 2
Five Degrees of Laptop OffIn part 1 of this series we learned how to measure how much power our systems are using, both hardware and software, and some tricks for reducing power usage without degrading performance. Today we're going to dive into the world of power management on laptops: ACPI, APM, hard disk spindowns, and spinups.
Power management on laptops is all about squeezing out more battery time. It's a losing battle as laptops get more powerful and use bigger displays. For example, my old Thinkpad R32 runs for three hours on a charge, even on wireless. My shiny new dual-core T61 lasts a bit under two hours. The new machine is brighter and faster, and it has a magnesium roll cage. (Oo la la, like a race car.) Modern laptops with wide glossy screens are lucky to get ninety minutes.
Managing interruptions is a common problem for laptop users. Shutting down and starting up again takes time and eats power. And so we have a confusing array of not-really-off options:
- Off itself, which as we learned in part 1 is usually sort of off and not really off
- S1--On Linux this is usually called "standby." The CPU goes into an idle state and processor caches are flushed. All devices are still powered, the screen blanks, and any other device that is configured to enter an idle state can do so.
- S2--This is included in the ACPI specification, but it's rarely used.
- S3--Suspend to RAM. The contents of the CPU registers are flushed to RAM and the CPU shuts down. Everything should shut down except RAM, including networking.
- S4--Suspend to disk, or hibernate. The current state is written to hard disk, and there should not be any devices drawing power, except for wake-on-LAN network interfaces.
Sponsored by BlackBerry
BlackBerry® Enterprise Server Express enables businesses of any size to quickly and easily get started with the BlackBerry solution. It provides advanced BlackBerry smartphone features with no additional software or user license fees, and works with any Internet-enabled BlackBerry data plan or a BlackBerry enterprise data plan. Download now!