mirror of https://lore.kernel.org/linux-amlogic/
 help / color / mirror / Atom feed
From: carlo@caione.org (Carlo Caione)
To: linus-amlogic@lists.infradead.org
Subject: [PATCH v3 1/2] Documentation: bindings: Introduce scpi,sensors-scale
Date: Thu,  9 Mar 2017 11:17:58 +0100	[thread overview]
Message-ID: <20170309101759.18081-2-carlo@caione.org> (raw)
In-Reply-To: <20170309101759.18081-1-carlo@caione.org>

From: Carlo Caione <carlo@endlessm.com>

Document the new property `scpi,sensors-scale` used by the hwmon-scpi
driver to convert the sensor readings to the correct / expected scale.

Signed-off-by: Carlo Caione <carlo@endlessm.com>
---
 Documentation/devicetree/bindings/arm/arm,scpi.txt | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/arm,scpi.txt b/Documentation/devicetree/bindings/arm/arm,scpi.txt
index 4018319..35c621c 100644
--- a/Documentation/devicetree/bindings/arm/arm,scpi.txt
+++ b/Documentation/devicetree/bindings/arm/arm,scpi.txt
@@ -84,6 +84,24 @@ Required properties:
 			 as used by the firmware. Refer to  platform details
 			 for your implementation for the IDs to use.
 
+Optional properties:
+- scpi,sensors-scale: array of 5 elements defining the unit scale used by the
+                      SCP for the 5 different sensor classes (temperature,
+                      voltage, current, power, energy) such that 1 == unit,
+                      1000 == milli, 1000000 == micro, ...
+
+                      Example:
+                         scpi,sensors-scale = <1 1000 1000 1000000 1000000>
+                      In this case the values reported by SCP are:
+                      -> temperature in degree Celsius
+                      -> voltage in millivolts
+                      -> current in milliamperes
+                      -> power in microwatts
+                      -> energy in microjoules
+
+                      The default value is:
+                         scpi,sensors-scale = <1000 1000 1000 1000000 1000000>
+
 Power domain bindings for the power domains based on SCPI Message Protocol
 ------------------------------------------------------------
 
-- 
2.9.3

  reply	other threads:[~2017-03-09 10:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-09 10:17 [PATCH v3 0/2] scpi-sensors: Fix SCP sensor readings scale Carlo Caione
2017-03-09 10:17 ` Carlo Caione [this message]
2017-03-15 18:20   ` [PATCH v3 1/2] Documentation: bindings: Introduce scpi,sensors-scale Sudeep Holla
2017-03-15 19:30     ` Guenter Roeck
2017-03-15 20:36     ` Rob Herring
2017-03-15 20:56     ` [PATCH v3 1/2] Documentation: bindings: Introduce scpi, sensors-scale Martin Blumenstingl
2017-03-15 22:40       ` [PATCH v3 1/2] Documentation: bindings: Introduce scpi,sensors-scale Guenter Roeck
2017-03-09 10:17 ` [PATCH v3 2/2] hwmon: (scpi) Fix the scale of SCP sensor readings Carlo Caione

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170309101759.18081-2-carlo@caione.org \
    --to=carlo@caione.org \
    --cc=linus-amlogic@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®