linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] thermal: add support to slope and offset
@ 2015-05-12  3:04 Eduardo Valentin
  2015-05-12  3:04 ` [PATCH 1/2] thermal: support slope and offset coefficients Eduardo Valentin
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Eduardo Valentin @ 2015-05-12  3:04 UTC (permalink / raw)
  To: Rui Zhang, hongtao.jia, kong.kongxinwei
  Cc: Linux PM, LKML, Linux ACPI, Eduardo Valentin

Hello all,

This is a patch series to add support to slope and offset constants
of a linear extrapolation model. This type of model is very common
across different platforms, and many drivers are attempting
to have its support.

The basic idea is to have this mapping in the thermal core,
as part of thermal_zone_params. In this series, I also add
a simple support to read them from DT, i.e.:
                /* hotspot = 1 * adc + 6000 */
		coefficients =          <1      6000>;

I am copying some of the driver writers that attempted to 
use this feature, but by adding their own property. Please,
check if this change is enough to properly map your slope
and offset requirement. Remember, they will be added in your
thermal zone DT node, instead of in your sensor DT node.

BR,

Eduardo Valentin (2):
  thermal: support slope and offset coefficients
  thermal: of-thermal: add support for reading coefficients property

 Documentation/thermal/sysfs-api.txt | 16 ++++++++++++++++
 drivers/thermal/of-thermal.c        | 26 ++++++++++++++++++++++++--
 drivers/thermal/thermal_core.c      |  4 ++++
 include/linux/thermal.h             | 11 +++++++++++
 4 files changed, 55 insertions(+), 2 deletions(-)

-- 
2.3.4


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-05-12  3:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-12  3:04 [PATCH 0/2] thermal: add support to slope and offset Eduardo Valentin
2015-05-12  3:04 ` [PATCH 1/2] thermal: support slope and offset coefficients Eduardo Valentin
2015-05-12  3:25   ` Eduardo Valentin
2015-05-12  3:04 ` [PATCH 2/2] thermal: of-thermal: add support for reading coefficients property Eduardo Valentin
2015-05-12  3:27   ` [PATCH 2/2] thermal: of-thermal: add support for reading coefficients property 33 O May 11 Antoine Tenart ( 15K) [PATCH v4 1/3] iio: adc: add support for Berlin Eduardo Valentin
2015-05-12  3:24 ` [PATCH 0/2] thermal: add support to slope and offset Eduardo Valentin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).