Linux/ACPI
Valid XHTML 1.0!
Valid CSS!
SourceForge.net Logo

Last update: 2006-01-07

Documentation: The /proc/acpi/thermal_zone Subdirectory

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

Note: This documentation is incomplete and lacks information specific to GNU/Linux.

ACPI allows OSPM to be proactive in its system cooling policies. With OSPM control of the operating environment, cooling decisions can be made based on the application load on the CPU and the thermal heuristics of the system. Graceful shutdown of the OS at critical heat levels becomes possible as well. ACPI describes the thermal objects available to OSPM to control platform temperature. ACPI expects all temperatures to be given in tenths of degrees Kelvin. The ACPI thermal design is based around regions called thermal zones. Generally, the entire PC is one large thermal zone, but an OEM can partition the system into several thermal zones if necessary.
You can find the complete text in the ACPI specification on page 277 ff.
Within the directory each thermal zone has its own subdirectory, usually there is only one of these, often called THRM or THR1 by your OEM (builder of your BIOS). Each of these subdirectories contain the following files:

cooling_mode

A robust OSPM implementation provides the means for the end user to convey a preference (or a level of preference) for either performance or energy conservation to OSPM. Allowing the end user to choose this preference is most critical to mobile system users where maximizing system run-time on a battery charge often has higher priority over realizing maximum system performance. For example, if a user is taking notes on her PC in a quiet environment, such as a library or a corporate meeting, she may want the system to emphasize passive cooling so that the system operates quietly, even at the cost of system performance. A user preference towards performance corresponds to the Active cooling mode while a user's preference towards energy conservation or quiet corresponds to the Passive cooling mode. ACPI defines an interface to convey the cooling mode to the platform. Active cooling can be performed with minimal OSPM thermal policy intervention. For example, the platform indicates through thermal zone parameters that crossing a thermal trip point requires a fan to be turned on. Passive cooling requires OSPM thermal policy to manipulate device interfaces that reduce performance to reduce thermal zone temperature.
Either cooling mode will be activated only when the thermal condition requires it. When the thermal zone is at an optimal temperature level where it does not warrant any cooling, both modes result in a system operating at its maximum potential with all fans turned off.
Usually, it should read something like cooling mode: active.

polling_frequency

This relates to the optional object called Thermal Zone Polling (_TZP) and evaluates to a recommended polling frequency (in tenths of seconds) for this thermal zone. A value of zero indicates that OSPM does not need to poll the temperature of this thermal zone in order to detect temperature changes (the hardware is capable of generating asynchronous notifications). Notice that the absence of _TZP informs OSPM to implement polling using an OS-provided default frequency.
The use of polling is allowed but strongly discouraged by this specification. OEMs should design systems that asynchronously notify OSPM whenever a meaningful change in the zone's temperature occurs, relieving the OS of the overhead associated with polling.
Usually, it should read something like <polling disabled>, though you can activate it somehow.

state

Usually, it should read something like state: ok.

temperature

The corresponding control method Temperature (_TMP) returns the thermal zone's current operating temperature in Kelvin. Within GNU/Linux, this file gives you the temperature in Celsius.

Operation Command Sample Output
Read cat temperature temperature: 49 C

trip_points

There are three cooling policies that OSPM uses to control the thermal state of the hardware. The policies are active, passive and critical:

  • Active Cooling. OSPM takes a direct action such as turning on a fan. Active cooling devices typically consume power and produce some amount of noise when enabled (_ON), but are able to cool a thermal zone without limiting system performance. The _ACx objects declare the temperature thresholds OSPM uses to decide when to start or stop different active cooling devices.
  • Passive Cooling. OSPM reduces the power consumption of devices to reduce the temperature of a thermal zone, such as slowing (throttling) the processor clock. Passive cooling devices typically produce no user-noticeable noise. The _PSV control method specifies the temperature threshold where OSPM will start or stop passive cooling.
  • Critical Trip Points. These are threshold temperatures at which OSPM performs an orderly, but critical, shutdown of the system. The _HOT object declares the critical temperature at which OSPM may choose to transition the system into the S4 sleeping state, if supported, The _CRT object declares the critical temperature at which OSPM must perform a critical shutdown. When a thermal zone appears, OSPM runs control methods in the thermal zone to retrieve the temperature thresholds (trip points) at which it executes a cooling policy. When OSPM receives a temperature change notification it will run the _TMP control method, which returns the current temperature of the thermal zone. OSPM checks the current temperature against the temperature thresholds. If _TMP is greater than or equal to _ACx then OSPM will turn on the associated active cooling device(s). If _TMP is greater than or equal to _PSV then OSPM will perform passive cooling. If _TMP is greater than or equal to _HOT then OSPM may choose to transition the system into the S4 sleeping state, if supported. Finally, if _TMP is greater than or equal to _CRT then OSPM will shut the system down. OSPM must also evaluate _TMP when any thermal zone appears in the namespace (for example, during system initialization) and must initiate a cooling policy as warranted independent of receipt of a temperature change notification. This allows OSPM to cool systems containing a thermal zone whose temperature has already exceeded temperature thresholds at initialization time.
    An optimally designed system that uses several thresholds can notify OSPM of thermal increase or decrease by raising an SCI every several degrees. This enables OSPM to anticipate thermal trends and incorporate heuristics to better manage the system's temperature.
    The OS can also request that the platform change the priority of active cooling (performance) versus passive cooling (energy conservation/silence) by invoking the _SCP (Set Cooling Policy) method.
    Note: there _should_ be a hardware shutdown if the values defined by OSPM (read: user) would lead to overheating. Experience shows, that it works on most machines.
Operation Command Sample Output
Read cat trip_points critical (S5): 110 C
passive: 105 C: tc1=2 tc2=10 tsp=100 devices=0xdf72e380
active[0]: 48 C: devices=0xc157fec0