diff mbox series

[v2,03/13] dt-bindings: thermal: tegra: Add nvidia,thermal-zones property

Message ID 20231012175836.3408077-4-thierry.reding@gmail.com (mailing list archive)
State New, archived
Delegated to: Daniel Lezcano
Headers show
Series thermal: tegra: Do not register cooling device | expand

Commit Message

Thierry Reding Oct. 12, 2023, 5:58 p.m. UTC
From: Thierry Reding <treding@nvidia.com>

The throttle configurations need to be associated with one or more
thermal zones before they can be enabled, so introduce a new property,
called nvidia,thermal-zones, that contains a list of phandles to the
thermal zones for which a throttle configuration is applicable.

Signed-off-by: Thierry Reding <treding@nvidia.com>
---
Changes in v2:
- new patch to hook up throttling with thermal zones

 .../bindings/thermal/nvidia,tegra124-soctherm.yaml           | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Daniel Lezcano Oct. 13, 2023, 3:59 p.m. UTC | #1
On 12/10/2023 19:58, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
> 
> The throttle configurations need to be associated with one or more
> thermal zones before they can be enabled, so introduce a new property,
> called nvidia,thermal-zones, that contains a list of phandles to the
> thermal zones for which a throttle configuration is applicable.
> 
> Signed-off-by: Thierry Reding <treding@nvidia.com>
> ---
> Changes in v2:
> - new patch to hook up throttling with thermal zones
> 
>   .../bindings/thermal/nvidia,tegra124-soctherm.yaml           | 5 +++++
>   1 file changed, 5 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml b/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
> index 0eb6277082fe..359344f60a6e 100644
> --- a/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
> +++ b/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
> @@ -161,6 +161,11 @@ properties:
>                 throttling is engaged after the OC event is deasserted.
>               default: 0
>   
> +          nvidia,thermal-zones:
> +            $ref: /schemas/types.yaml#/definitions/phandle
> +            description: A list of phandles to the thermal zones that this
> +              throttle configuration applies to.
> +

 From a DT perspective, I believe it is more correct to point to the 
devices the hardware throttling mechanism applies to instead of the 
thermal zones which is kind of software component

>     # optional
>     nvidia,thermtrips:
>       $ref: /schemas/types.yaml#/definitions/uint32-matrix
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml b/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
index 0eb6277082fe..359344f60a6e 100644
--- a/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
+++ b/Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml
@@ -161,6 +161,11 @@  properties:
               throttling is engaged after the OC event is deasserted.
             default: 0
 
+          nvidia,thermal-zones:
+            $ref: /schemas/types.yaml#/definitions/phandle
+            description: A list of phandles to the thermal zones that this
+              throttle configuration applies to.
+
   # optional
   nvidia,thermtrips:
     $ref: /schemas/types.yaml#/definitions/uint32-matrix