]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
dt-bindings: hwmon: amc6821: add fan and PWM output
authorFrancesco Dolcini <francesco.dolcini@toradex.com>
Wed, 2 Apr 2025 10:21:45 +0000 (12:21 +0200)
committerGuenter Roeck <linux@roeck-us.net>
Wed, 23 Apr 2025 14:18:26 +0000 (07:18 -0700)
Add properties to describe the fan and the PWM controller output.

Link: https://www.ti.com/lit/gpn/amc6821
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://lore.kernel.org/r/20250402102146.65406-2-francesco@dolcini.it
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Documentation/devicetree/bindings/hwmon/ti,amc6821.yaml

index 5d33f1a23d0325abe906dfb1d30cfac3c3ec9805..9ca7356760a74b1ab5e6c5a4966ba30f050a1eed 100644 (file)
@@ -28,6 +28,17 @@ properties:
   i2c-mux:
     type: object
 
+  fan:
+    $ref: fan-common.yaml#
+    unevaluatedProperties: false
+
+  "#pwm-cells":
+    const: 2
+    description: |
+      Number of cells in a PWM specifier.
+      - cell 0: PWM period in nanoseconds
+      - cell 1: PWM polarity: 0 or PWM_POLARITY_INVERTED
+
 required:
   - compatible
   - reg
@@ -50,9 +61,14 @@ examples:
         #address-cells = <1>;
         #size-cells = <0>;
 
-        fan@18 {
+        fan_controller: fan@18 {
             compatible = "ti,amc6821";
             reg = <0x18>;
+            #pwm-cells = <2>;
+
+            fan {
+                pwms = <&fan_controller 40000 0>;
+            };
         };
     };