diff mbox series

[v2,07/16] hwmon: (mr75203) add VM active channels property for Moortec PVT controller

Message ID 20220817054321.6519-8-farbere@amazon.com (mailing list archive)
State Changes Requested
Headers show
Series Variety of fixes and new features for mr75203 driver | expand

Commit Message

Farber, Eliav Aug. 17, 2022, 5:43 a.m. UTC
Add optional "vm-active-channels" property to define the number of
active channels per VM.

Signed-off-by: Eliav Farber <farbere@amazon.com>
---
 .../devicetree/bindings/hwmon/moortec,mr75203.yaml       | 9 +++++++++
 1 file changed, 9 insertions(+)

Comments

Guenter Roeck Aug. 18, 2022, 8:07 p.m. UTC | #1
On Wed, Aug 17, 2022 at 05:43:12AM +0000, Eliav Farber wrote:
> Add optional "vm-active-channels" property to define the number of
> active channels per VM.
> 
> Signed-off-by: Eliav Farber <farbere@amazon.com>
> ---
>  .../devicetree/bindings/hwmon/moortec,mr75203.yaml       | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
> index da9c3cdcb6f0..6111b5069b3c 100644
> --- a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
> +++ b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
> @@ -49,6 +49,13 @@ properties:
>        reset-control-skip bool property defines if obtaining a
>        reference to a reset controller should be skipped.
>  
> +  vm-active-channels:
> +    description:
> +      vm-active-channels defines the number of channels per VM
> +      that are actually used and are connected to some source.
> +      A value of 0 means that the entire VM sensor is nou used.

not ?

> +    $ref: /schemas/types.yaml#definitions/uint8-array
> +
>  required:
>    - compatible
>    - reg
> @@ -60,6 +67,7 @@ required:
>  additionalProperties:
>    - intel,vm-map
>    - reset-control-skip
> +  - vm-active-channels
>  
>  examples:
>    - |
> @@ -73,5 +81,6 @@ examples:
>          intel,vm-map = [03 01 04 ff ff];
>          clocks = <&osc0>;
>          resets = <&rcu0 0x40 7>;
> +        vm-active-channels = [08 10 02];

Is that how properties are defined nowadays ? I am left with
no clues how this is supposed to be interpreted by a driver.
What does "08 10 02" mean ? How does that refer to "the number of
active channels per VM" ?

Also, I am not a devicetree expert, but I am quite sure that all
those chip specific properties would need a vendor prefix.

Guenter

>          #thermal-sensor-cells = <1>;
>      };
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
index da9c3cdcb6f0..6111b5069b3c 100644
--- a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
+++ b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
@@ -49,6 +49,13 @@  properties:
       reset-control-skip bool property defines if obtaining a
       reference to a reset controller should be skipped.
 
+  vm-active-channels:
+    description:
+      vm-active-channels defines the number of channels per VM
+      that are actually used and are connected to some source.
+      A value of 0 means that the entire VM sensor is nou used.
+    $ref: /schemas/types.yaml#definitions/uint8-array
+
 required:
   - compatible
   - reg
@@ -60,6 +67,7 @@  required:
 additionalProperties:
   - intel,vm-map
   - reset-control-skip
+  - vm-active-channels
 
 examples:
   - |
@@ -73,5 +81,6 @@  examples:
         intel,vm-map = [03 01 04 ff ff];
         clocks = <&osc0>;
         resets = <&rcu0 0x40 7>;
+        vm-active-channels = [08 10 02];
         #thermal-sensor-cells = <1>;
     };