lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220906083356.21067-15-farbere@amazon.com>
Date:   Tue, 6 Sep 2022 08:33:49 +0000
From:   Eliav Farber <farbere@...zon.com>
To:     <jdelvare@...e.com>, <linux@...ck-us.net>, <robh+dt@...nel.org>,
        <p.zabel@...gutronix.de>, <rtanwar@...linear.com>,
        <linux-hwmon@...r.kernel.org>, <devicetree@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>
CC:     <farbere@...zon.com>, <hhhawa@...zon.com>, <jonnyc@...zon.com>,
        <andriy.shevchenko@...el.com>
Subject: [PATCH v4 14/21] dt-bindings: hwmon: (mr75203) add "moortec,vm-pre-scaler-x2" property

Add support for mr76006 pre-scaler which provides divide-by-2 scaling of
the input voltage, so that it can be  presented to the VM for measurement
within its range (the VM input range is limited to -0.1V to 1V).

The new "moortec,vm-pre-scaler-x2" property lists the channels that use
the mr76006 pre-scaler.

The driver will use this list to multiply the voltage result by 2, to
present to the user with the actual voltage input source.

Signed-off-by: Eliav Farber <farbere@...zon.com>
---
V4 -> V3:
- Rename "moortec,vm-pre-scaler" to "moortec,vm-pre-scaler-x2".
- Added mximum number if items in description.

V3 -> V2:
- Add "moortec" prefix to property name.
- Change property format to be a single u8 array.
- Fix typo: scalar --> scaler.

 .../devicetree/bindings/hwmon/moortec,mr75203.yaml  | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
index 2aa4c3618596..de92a21d5552 100644
--- a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
+++ b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
@@ -79,6 +79,18 @@ properties:
       Minimum value of each item - 0 (which means entire VM sensor is nou used).
     $ref: /schemas/types.yaml#/definitions/uint8-array
 
+  moortec,vm-pre-scaler-x2:
+    description:
+      Defines the channels that use a mr76006 pre-scaler to divide the input
+      source by 2.
+      The pre-scaler is used for input sources that exceed the VM input range.
+      The driver uses this information to present to the user with the actual
+      value of the voltage source.
+      For channels that are not listed, no pre-scaler is assumed.
+      Maximum number of items - total number of channels in all VMs.
+      Each channel should not appear more than once.
+    $ref: /schemas/types.yaml#/definitions/uint8-array
+
 required:
   - compatible
   - reg
@@ -101,5 +113,6 @@ examples:
         clocks = <&osc0>;
         resets = <&rcu0 0x40 7>;
         moortec,vm-active-channels = /bits/ 8 <0x10 0x05>;
+        moortec,vm-pre-scaler-x2 = /bits/ 8 <5 6 20>;
         #thermal-sensor-cells = <1>;
     };
-- 
2.37.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ