APM uses a layered approach to manage devices. APM-aware applications (which include device drivers) talk to an OS-specific APM driver. This driver communicates to the APM-aware BIOS, which controls the hardware. There is the ability to opt out of APM control on a device-by-device basis, which can be used if a driver wants to communicate directly with a hardware device.
Communication occurs both ways; power management events are sent from the BIOS to the APM driver, and the APM driver sends information and requests to the BIOS via function calls. In this way the APM driver is an intermediary between the BIOS and the operating system.
Power management happens in two ways; through the above-mentioned function calls from the APM driver to the BIOS requesting power state changes, and automatically based on device activity.
In APM 1.0 and APM 1.1, power management is almost fully controlled by the BIOS. In APM 1.2, the operating system can control PM time (e.g. suspend timeout).
In 1997, Phoenix Technologies released "APM 2.0" which is a kernel device driver compatible with an APM 1.2 BIOS.3
There are 12 power events (such as standby, suspend and resume requests, and low battery notifications), plus OEM-defined events, that can be sent from the APM BIOS to the operating system. The APM driver regularly polls for event change notifications.
Power Management Events:4
There are 21 APM function calls defined that the APM driver can use to query power management statuses, or request power state transitions.5 Example function calls include letting the BIOS know about current CPU usage (the BIOS may respond to such a call by placing the CPU in a low-power state, or returning it to its full-power state), retrieving the current power state of a device, or requesting a power state change.
The APM specification defines system power states and device power states.
APM defines five power states for the computer system:
APM also defines power states that APM-aware hardware can implement. There is no requirement that an APM-aware device implement all states.
The four states are:
The CPU core (defined in APM as the CPU clock, cache, system bus and system timers) is treated specially in APM, as it is the last device to be powered down, and the first device to be powered back up. The CPU core is always controlled through the APM BIOS (there is no option to control it through a driver). Drivers can use APM function calls to notify the BIOS about CPU usage, but it is up to the BIOS to act on this information; a driver cannot directly tell the CPU to go into a power saving state.
The ATA specification and SATA specification defines APM provisions for hard drives, which specifies a trade-off between spin-down frequency and always-on performance. Unlike the BIOS-side APM, the ATA APM and SATA APM has never been deprecated.7
Aggressive spin-down frequencies may reduce drive lifespan by unnecessarily accumulating load cycles; most modern drives are specified to sustain 300,000 cycles and usually last at least 600,000. On the other hand, not spinning down the drive will cause extra power draw and heat generation; high temperatures also reduce the lifespan of hard drives.8
"Advanced Power Management (APM) BIOS Interface Specification Revision 1.2 February 1996 Intel/Microsoft". Archived from the original on 6 February 2012. Retrieved 27 December 2006. 090429 https://web.archive.org/web/20120206030045/http://download.microsoft.com/download/1/6/1/161ba512-40e2-4cc9-843a-923143f3456c/APMV12.rtf ↩
Intel Corporation, "NewsBit: Microsoft, Intel Develop Power Standard", Microcomputer Solutions, March/April 1992, page 1 ↩
"APM 2.0: BIOS independent power management under Windows NT 4.0 or 3.51". Phoenix Technologies. Archived from the original on 2005-11-09. https://web.archive.org/web/20051109023014/http://www.award.com:80/resources/apm-portables-ds.zip ↩
"linux - What do different values of hard drive's Advanced Power Management feature (hdparm -B) affect, except spin-down?". Super User. The ATA Spec turns up this tidbit: Subcommand code 05h allows the host to enable Advanced Power Management. To enable Advanced Power Management, the host writes the Sector Count register with the desired advanced power management level and then executes a SET FEATURES command with subcommand code 05h. https://superuser.com/a/558622 ↩
bwDraco. "linux - How much "Load_cycle_count" can my hard drive hypotethically sustain?". Super User. https://superuser.com/a/847431/ ↩