ACPI / fan: Display fan performance state information
Subsystems (2)
PATCH 1/1 ACPI / fan: Display fan performance state information
When _FPS object indicates support of variable speed fan, thermal cooling devices for fan shows max performance state count using attribute "max_state" greater than or equal to 1.
But the thermal cooling device doesn't display properties of each performance state. This is not enough for smart fan control user space software, which also considers speed, power and noise level.
This change presents fan performance states attributes under acpi device for the fan. This will be under:/sys/bus/acpi/devices/devices/INT3404:00
or/sys/bus/platform/devices/PNP0C0B:00.
For more information refer to:Documentation/acpi/fan_performance_states.txt
Signed-off-by Srinivas Pandruvada <[email protected]>
Tested-by Sumeet Pawnikar <[email protected]>
--- Documentation/acpi/fan_performance_states.txt | 39 ++++++ drivers/acpi/fan.c | 111 ++++++++++++++++-- 2 files changed, 141 insertions(+), 9 deletions(-) create mode 100644 Documentation/acpi/fan_performance_states.txt
Documentation/acpi/fan_performance_states.txt new file +39 -0
@@ -0,0 +1,39 @@ +When the optional object _FPS is present for ACPI devices PNP0C0B or INT3404, +additional attributes are displayed under acpi device object. These attributes +display information about each performance state. + +For example +$ ls /sys/bus/acpi/devices/INT3404\:00 +description fan_perf_state_11 fan_perf_state_5 fan_perf_state_9 physical_node uevent +fan_perf_state_0 fan_perf_state_2 fan_perf_state_6 hid power uid +fan_perf_state_1 fan_perf_state_3 fan_perf_state_7 modalias status wakeup +fan_perf_state_10 fan_perf_state_4 fan_perf_state_8 path subsystem + +Each fan_perf_state_* contains the information about the fields for each state as +defined by the ACPI specification. + +For example +$ grep . /sys/bus/acpi/devices/INT3404\:00/fan_perf_state_1/* +/sys/bus/acpi/devices/INT3404:00/fan_perf_state_1/control_percent:25 +/sys/bus/acpi/devices/INT3404:00/fan_perf_state_1/noise_level_mdb:12500 +/sys/bus/acpi/devices/INT3404:00/fan_perf_state_1/power_mw:1250 +/sys/bus/acpi/devices/INT3404:00/fan_perf_state_1/speed_rpm:3200 +/sys/bus/acpi/devices/INT3404:00/fan_perf_state_1/trip_point_index:invalid + +Fields +control_percent: Indicates the value to be used to set the fan speed to a +specific level using the _FSL object. The value here is from 0-100 percent. + +noise_level_mdb: Indicates the audible noise emitted by the fan. By the +specification the value represents the noise in 10ths of decibels. Here +it is multiplied with 100 to present in milli-db, to avoid loss of +precision. When not populated, "not-defined" is displayed. + +speed_rpm: Indicates the speed of the fan in revolutions per minute. + +power_mw: Indicates the power consumption in milliwatts. When not populated, +"not-defined" is displayed. + +trip_point_index: The active cooling trip point number that corresponds to this +performance state. The range is from 0-9. For any other values, "invalid" is +be displayed.
drivers/acpi/fan.c +102 -9
171 lines not on this page · raw message
Signature · 1 line
2.17.2