]> git.baikalelectronics.ru Git - kernel.git/commit
thermal: support slope and offset coefficients
authorEduardo Valentin <edubezval@gmail.com>
Tue, 12 May 2015 02:34:23 +0000 (19:34 -0700)
committerEduardo Valentin <edubezval@gmail.com>
Tue, 12 May 2015 02:46:52 +0000 (19:46 -0700)
commita535b50a4aff37ec48e968e29aaa3b90378d7597
treec3cab3c900e0841e9beeba9756800c175748b8be
parent8a73b93ac9e9d3ef07545536ddcbec69c8a3c8f8
thermal: support slope and offset coefficients

It is common to have a linear extrapolation from
the current sensor readings and the actual temperature
value. This is specially the case when the sensor
is in use to extrapolate hotspots.

This patch adds slope and offset constants for
single sensor linear extrapolation equation. Because
the same sensor can be use in different locations,
from board to board, these constants are added
as part of thermal_zone_params.

The constants are available through sysfs.

It is up to the device driver to determine
the usage of these values.

Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
Documentation/thermal/sysfs-api.txt
drivers/thermal/thermal_core.c
include/linux/thermal.h