Valid XHTML 1.0!
Valid CSS! Logo

Last update: 2006-01-07

Documentation: The file /sys/power/state || /proc/acpi/sleep

Warning: /proc/acpi is being replaced by interfaces in /sys and new software should not look in /proc.

To conserve energy while remaining quickly available, ACPI-compatible PCs may enter system sleep states. The ACPI specification defines 5 of these states, known as S-states. Unlike the processor sleep states described later, no work is done by the system under S-states. Each state introduces greater power savings but requires commensurately more time to awaken and begin performing work. These are patterned on system states from the APM standard, a predecessor of ACPI.
After the explanation of the usage for each kernel version, a more general explanation about the single sleep states is attached.

Usage 2.6

Users of 2.6 are advised to use the new file in sysfs: /sys/power/state. This file is independent of the power management mechanism actually used, e.g. ACPI for x86 machines or PMU for powerpc machines.

Operation Command Sample Output
Read cat state standby mem disk
Write echo -n "x" > state
with x being replaced by the sleep state as seen when reading.

Usage 2.4

Users of 2.4 are advised to use the old file in procfs: /proc/acpi/sleep.

Operation Command Sample Output
Read cat sleep S0 S1 S3 S4 S5
Write echo x > sleep
with x being replaced by the sleep state number.

Sleep States

S1 - "Stopgrant"

Power to cpu is maintained, but no instructions are executed. The CPU halts itself and may shut down many of its internal components. In Microsoft Windows, the "Standby" command is associated with this state by default.


While defined in the spec, this state is not currently in use. It resembles S3 with the qualification that some devices are permitted to remain on.

S3 - "Suspend to RAM"

All power to the cpu is shut off, and the contents of its registers are flushed to RAM, which remains on. In Microsoft Windows, the "Standby" command can be associated with this state if enabled in the BIOS. Because it requires a high degree of coordination between the cpu, chipset, devices, OS, BIOS, and OS device drivers, this system state is the most prone to errors and instability.
Pavel Machek has created a small document with some hints how to solve problems with S3. You can find it in the kernel sources at Documentation/power/tricks.txt.
S3 is currently _not_ supported by the 2.4.x kernel series in Linux.

S4 - "Suspend to Disk"

CPU power shut off as in S3, but RAM is written to disk and shut off as well. In Microsoft Windows, the "Hibernate" command is associated with this state. A variation called S4BIOS is most prevalent, where the system image is stored and loaded by the BIOS instead of the OS. Because the contents of RAM are written out to disk, system context is maintained. For example, unsaved files would not be lost following an S4 transition.
S4 is currently _not_ supported by the 2.4.x kernel series in Linux, but you might have good luck with SWSUSP. Some machines offer S4_BIOS whose support is considered to be experimental within Linux/ACPI.

S5 - "Soft Off"

System is shut down, however some power may be supplied to certain devices to generate a wake event, for example to support automatic startup from a LAN or USB device. In Microsoft Windows, the "Shut down" command is associated with this state. Mechanical power can usually be removed or restored with no ill effects.

Processor "C" power states

Processor "C" power states are also defined. These are typically implemented in laptop platforms only. Here the cpu consumes less power while still doing work, and the tradeoff comes between power and performance, rather than power and latency. Please consult the ACPI specification for more information on C states, or see here.