[PATCH v2 3/3] dt-bindings: hwmon: max31790: Add maxim,pwmout-pin-as-tach-input property

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The max31790 supports six pins, which are dedicated PWM outputs. Any of the
six PWM outputs can also be configured to serve as tachometer inputs,
allowing for up to 12 tachometer fans to be monitored.

Add a new vendor-specific property, 'maxim,pwmout-pin-as-tach-input',
to allow PWMOUT to become a TACH input.

An array of six integers responds to six PWM channels for configuring
the PWM to TACH mode. When set to 0, the associated PWMOUT produces
a PWM waveform for control of fan speed. When set to 1, PWMOUT becomes
a TACH input.

Signed-off-by: Chanh Nguyen <chanh@xxxxxxxxxxxxxxxxxxxxxx>
---
Changes in v2:
 - Update the vendor property name to "maxim,pwmout-pin-as-tach-input"   [Rob]
 - Update commit message                                                 [Krzysztof]
---
 .../devicetree/bindings/hwmon/maxim,max31790.yaml     | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml b/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
index a561e5a3e9e4..2d4f50bc7c41 100644
--- a/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
+++ b/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
@@ -30,6 +30,16 @@ properties:
   resets:
     maxItems: 1
 
+  maxim,pwmout-pin-as-tach-input:
+    description: |
+      An array of six integers responds to six PWM channels for
+      configuring the pwm to tach mode.
+      When set to 0, the associated PWMOUT produces a PWM waveform for
+      control of fan speed. When set to 1, PWMOUT becomes a TACH input
+    $ref: /schemas/types.yaml#/definitions/uint8-array
+    maxItems: 6
+    minItems: 6
+
 required:
   - compatible
   - reg
@@ -48,5 +58,6 @@ examples:
       fan-controller@20 {
         compatible = "maxim,max31790";
         reg = <0x20>;
+        maxim,pwmout-pin-as-tach-input = /bits/ 8 <0 0 0 0 1 1>;
       };
     };
-- 
2.17.1





[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux