All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema
@ 2021-04-15 11:16 Rafał Miłecki
  2021-04-20 20:08 ` Rob Herring
  2021-04-20 21:01 ` [PATCH V2] " Rafał Miłecki
  0 siblings, 2 replies; 5+ messages in thread
From: Rafał Miłecki @ 2021-04-15 11:16 UTC (permalink / raw)
  To: Zhang Rui, Daniel Lezcano, Amit Kucheria, Rob Herring
  Cc: linux-pm, devicetree, bcm-kernel-feedback-list, Rafał Miłecki

From: Rafał Miłecki <rafal@milecki.pl>

This helps validating DTS files.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
 .../bindings/thermal/brcm,ns-thermal.txt      | 37 ------------
 .../bindings/thermal/brcm,ns-thermal.yaml     | 59 +++++++++++++++++++
 2 files changed, 59 insertions(+), 37 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
 create mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml

diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
deleted file mode 100644
index 68e047170039..000000000000
--- a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-* Broadcom Northstar Thermal
-
-This binding describes thermal sensor that is part of Northstar's DMU (Device
-Management Unit).
-
-Required properties:
-- compatible : Must be "brcm,ns-thermal"
-- reg : iomem address range of PVTMON registers
-- #thermal-sensor-cells : Should be <0>
-
-Example:
-
-thermal: thermal@1800c2c0 {
-	compatible = "brcm,ns-thermal";
-	reg = <0x1800c2c0 0x10>;
-	#thermal-sensor-cells = <0>;
-};
-
-thermal-zones {
-	cpu_thermal: cpu-thermal {
-		polling-delay-passive = <0>;
-		polling-delay = <1000>;
-		coefficients = <(-556) 418000>;
-		thermal-sensors = <&thermal>;
-
-		trips {
-			cpu-crit {
-				temperature	= <125000>;
-				hysteresis	= <0>;
-				type		= "critical";
-			};
-		};
-
-		cooling-maps {
-		};
-	};
-};
diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
new file mode 100644
index 000000000000..50143e2f6bcb
--- /dev/null
+++ b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
@@ -0,0 +1,59 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/thermal/brcm,ns-thermal.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Broadcom Northstar Thermal
+
+maintainers:
+  - Rafał Miłecki <rafal@milecki.pl>
+
+description:
+  Thermal sensor that is part of Northstar's DMU (Device Management Unit).
+
+allOf:
+  - $ref: thermal-sensor.yaml#
+
+properties:
+  compatible:
+    const: brcm,ns-thermal
+
+  reg:
+    description: PVTMON registers range
+
+  "#thermal-sensor-cells":
+    const: 0
+
+unevaluatedProperties: false
+
+required:
+  - reg
+
+examples:
+  - |
+    thermal: thermal@1800c2c0 {
+        compatible = "brcm,ns-thermal";
+        reg = <0x1800c2c0 0x10>;
+        #thermal-sensor-cells = <0>;
+    };
+
+    thermal-zones {
+        cpu-thermal {
+            polling-delay-passive = <0>;
+            polling-delay = <1000>;
+            coefficients = <(-556) 418000>;
+            thermal-sensors = <&thermal>;
+
+            trips {
+                cpu-crit {
+                    temperature = <125000>;
+                    hysteresis = <0>;
+                    type = "critical";
+                };
+            };
+
+            cooling-maps {
+            };
+        };
+    };
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema
  2021-04-15 11:16 [PATCH] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema Rafał Miłecki
@ 2021-04-20 20:08 ` Rob Herring
  2021-04-20 21:01 ` [PATCH V2] " Rafał Miłecki
  1 sibling, 0 replies; 5+ messages in thread
From: Rob Herring @ 2021-04-20 20:08 UTC (permalink / raw)
  To: Rafał Miłecki
  Cc: Zhang Rui, Daniel Lezcano, Amit Kucheria, linux-pm, devicetree,
	bcm-kernel-feedback-list, Rafał Miłecki

On Thu, Apr 15, 2021 at 01:16:55PM +0200, Rafał Miłecki wrote:
> From: Rafał Miłecki <rafal@milecki.pl>
> 
> This helps validating DTS files.
> 
> Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
> ---
>  .../bindings/thermal/brcm,ns-thermal.txt      | 37 ------------
>  .../bindings/thermal/brcm,ns-thermal.yaml     | 59 +++++++++++++++++++
>  2 files changed, 59 insertions(+), 37 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
>  create mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
> 
> diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
> deleted file mode 100644
> index 68e047170039..000000000000
> --- a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
> +++ /dev/null
> @@ -1,37 +0,0 @@
> -* Broadcom Northstar Thermal
> -
> -This binding describes thermal sensor that is part of Northstar's DMU (Device
> -Management Unit).
> -
> -Required properties:
> -- compatible : Must be "brcm,ns-thermal"
> -- reg : iomem address range of PVTMON registers
> -- #thermal-sensor-cells : Should be <0>
> -
> -Example:
> -
> -thermal: thermal@1800c2c0 {
> -	compatible = "brcm,ns-thermal";
> -	reg = <0x1800c2c0 0x10>;
> -	#thermal-sensor-cells = <0>;
> -};
> -
> -thermal-zones {
> -	cpu_thermal: cpu-thermal {
> -		polling-delay-passive = <0>;
> -		polling-delay = <1000>;
> -		coefficients = <(-556) 418000>;
> -		thermal-sensors = <&thermal>;
> -
> -		trips {
> -			cpu-crit {
> -				temperature	= <125000>;
> -				hysteresis	= <0>;
> -				type		= "critical";
> -			};
> -		};
> -
> -		cooling-maps {
> -		};
> -	};
> -};
> diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
> new file mode 100644
> index 000000000000..50143e2f6bcb
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
> @@ -0,0 +1,59 @@
> +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/thermal/brcm,ns-thermal.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Broadcom Northstar Thermal
> +
> +maintainers:
> +  - Rafał Miłecki <rafal@milecki.pl>
> +
> +description:
> +  Thermal sensor that is part of Northstar's DMU (Device Management Unit).
> +
> +allOf:
> +  - $ref: thermal-sensor.yaml#
> +
> +properties:
> +  compatible:
> +    const: brcm,ns-thermal
> +
> +  reg:
> +    description: PVTMON registers range

How many?

> +
> +  "#thermal-sensor-cells":
> +    const: 0
> +
> +unevaluatedProperties: false
> +
> +required:
> +  - reg
> +
> +examples:
> +  - |
> +    thermal: thermal@1800c2c0 {
> +        compatible = "brcm,ns-thermal";
> +        reg = <0x1800c2c0 0x10>;
> +        #thermal-sensor-cells = <0>;
> +    };
> +
> +    thermal-zones {
> +        cpu-thermal {
> +            polling-delay-passive = <0>;
> +            polling-delay = <1000>;
> +            coefficients = <(-556) 418000>;
> +            thermal-sensors = <&thermal>;
> +
> +            trips {
> +                cpu-crit {
> +                    temperature = <125000>;
> +                    hysteresis = <0>;
> +                    type = "critical";
> +                };
> +            };
> +
> +            cooling-maps {
> +            };
> +        };
> +    };
> -- 
> 2.26.2
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH V2] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema
  2021-04-15 11:16 [PATCH] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema Rafał Miłecki
  2021-04-20 20:08 ` Rob Herring
@ 2021-04-20 21:01 ` Rafał Miłecki
  2021-04-21 17:12   ` Rob Herring
  2021-04-27 19:44   ` [thermal: thermal/next] dt-bindings: thermal: brcm,ns-thermal: Convert " thermal-bot for Rafał Miłecki
  1 sibling, 2 replies; 5+ messages in thread
From: Rafał Miłecki @ 2021-04-20 21:01 UTC (permalink / raw)
  To: Zhang Rui, Daniel Lezcano, Amit Kucheria, Rob Herring
  Cc: linux-pm, devicetree, bcm-kernel-feedback-list, Rafał Miłecki

From: Rafał Miłecki <rafal@milecki.pl>

This helps validating DTS files.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
V2: Add maxItems to the reg property
---
 .../bindings/thermal/brcm,ns-thermal.txt      | 37 ------------
 .../bindings/thermal/brcm,ns-thermal.yaml     | 60 +++++++++++++++++++
 2 files changed, 60 insertions(+), 37 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
 create mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml

diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
deleted file mode 100644
index 68e047170039..000000000000
--- a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-* Broadcom Northstar Thermal
-
-This binding describes thermal sensor that is part of Northstar's DMU (Device
-Management Unit).
-
-Required properties:
-- compatible : Must be "brcm,ns-thermal"
-- reg : iomem address range of PVTMON registers
-- #thermal-sensor-cells : Should be <0>
-
-Example:
-
-thermal: thermal@1800c2c0 {
-	compatible = "brcm,ns-thermal";
-	reg = <0x1800c2c0 0x10>;
-	#thermal-sensor-cells = <0>;
-};
-
-thermal-zones {
-	cpu_thermal: cpu-thermal {
-		polling-delay-passive = <0>;
-		polling-delay = <1000>;
-		coefficients = <(-556) 418000>;
-		thermal-sensors = <&thermal>;
-
-		trips {
-			cpu-crit {
-				temperature	= <125000>;
-				hysteresis	= <0>;
-				type		= "critical";
-			};
-		};
-
-		cooling-maps {
-		};
-	};
-};
diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
new file mode 100644
index 000000000000..fdeb333e010d
--- /dev/null
+++ b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
@@ -0,0 +1,60 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/thermal/brcm,ns-thermal.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Broadcom Northstar Thermal
+
+maintainers:
+  - Rafał Miłecki <rafal@milecki.pl>
+
+description:
+  Thermal sensor that is part of Northstar's DMU (Device Management Unit).
+
+allOf:
+  - $ref: thermal-sensor.yaml#
+
+properties:
+  compatible:
+    const: brcm,ns-thermal
+
+  reg:
+    description: PVTMON registers range
+    maxItems: 1
+
+  "#thermal-sensor-cells":
+    const: 0
+
+unevaluatedProperties: false
+
+required:
+  - reg
+
+examples:
+  - |
+    thermal: thermal@1800c2c0 {
+        compatible = "brcm,ns-thermal";
+        reg = <0x1800c2c0 0x10>;
+        #thermal-sensor-cells = <0>;
+    };
+
+    thermal-zones {
+        cpu-thermal {
+            polling-delay-passive = <0>;
+            polling-delay = <1000>;
+            coefficients = <(-556) 418000>;
+            thermal-sensors = <&thermal>;
+
+            trips {
+                cpu-crit {
+                    temperature = <125000>;
+                    hysteresis = <0>;
+                    type = "critical";
+                };
+            };
+
+            cooling-maps {
+            };
+        };
+    };
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH V2] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema
  2021-04-20 21:01 ` [PATCH V2] " Rafał Miłecki
@ 2021-04-21 17:12   ` Rob Herring
  2021-04-27 19:44   ` [thermal: thermal/next] dt-bindings: thermal: brcm,ns-thermal: Convert " thermal-bot for Rafał Miłecki
  1 sibling, 0 replies; 5+ messages in thread
From: Rob Herring @ 2021-04-21 17:12 UTC (permalink / raw)
  To: Rafał Miłecki
  Cc: devicetree, linux-pm, Rafał Miłecki, Daniel Lezcano,
	bcm-kernel-feedback-list, Amit Kucheria, Rob Herring, Zhang Rui

On Tue, 20 Apr 2021 23:01:04 +0200, Rafał Miłecki wrote:
> From: Rafał Miłecki <rafal@milecki.pl>
> 
> This helps validating DTS files.
> 
> Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
> ---
> V2: Add maxItems to the reg property
> ---
>  .../bindings/thermal/brcm,ns-thermal.txt      | 37 ------------
>  .../bindings/thermal/brcm,ns-thermal.yaml     | 60 +++++++++++++++++++
>  2 files changed, 60 insertions(+), 37 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
>  create mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
> 

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [thermal: thermal/next] dt-bindings: thermal: brcm,ns-thermal: Convert to the json-schema
  2021-04-20 21:01 ` [PATCH V2] " Rafał Miłecki
  2021-04-21 17:12   ` Rob Herring
@ 2021-04-27 19:44   ` thermal-bot for Rafał Miłecki
  1 sibling, 0 replies; 5+ messages in thread
From: thermal-bot for Rafał Miłecki @ 2021-04-27 19:44 UTC (permalink / raw)
  To: linux-pm; +Cc: rafal, Rob Herring, Daniel Lezcano, rui.zhang, amitk

The following commit has been merged into the thermal/next branch of thermal:

Commit-ID:     08e9fdfbb2248e93bbfaeb9cde284776085466cd
Gitweb:        https://git.kernel.org/pub/scm/linux/kernel/git/thermal/linux.git//08e9fdfbb2248e93bbfaeb9cde284776085466cd
Author:        Rafał Miłecki <rafal@milecki.pl>
AuthorDate:    Tue, 20 Apr 2021 23:01:04 +02:00
Committer:     Daniel Lezcano <daniel.lezcano@linaro.org>
CommitterDate: Wed, 21 Apr 2021 20:42:48 +02:00

dt-bindings: thermal: brcm,ns-thermal: Convert to the json-schema

This helps validating DTS files.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20210420210104.10555-1-zajec5@gmail.com
---
 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt  | 37 +----
 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml | 60 +++++++-
 2 files changed, 60 insertions(+), 37 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
 create mode 100644 Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml

diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
deleted file mode 100644
index 68e0471..0000000
--- a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-* Broadcom Northstar Thermal
-
-This binding describes thermal sensor that is part of Northstar's DMU (Device
-Management Unit).
-
-Required properties:
-- compatible : Must be "brcm,ns-thermal"
-- reg : iomem address range of PVTMON registers
-- #thermal-sensor-cells : Should be <0>
-
-Example:
-
-thermal: thermal@1800c2c0 {
-	compatible = "brcm,ns-thermal";
-	reg = <0x1800c2c0 0x10>;
-	#thermal-sensor-cells = <0>;
-};
-
-thermal-zones {
-	cpu_thermal: cpu-thermal {
-		polling-delay-passive = <0>;
-		polling-delay = <1000>;
-		coefficients = <(-556) 418000>;
-		thermal-sensors = <&thermal>;
-
-		trips {
-			cpu-crit {
-				temperature	= <125000>;
-				hysteresis	= <0>;
-				type		= "critical";
-			};
-		};
-
-		cooling-maps {
-		};
-	};
-};
diff --git a/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
new file mode 100644
index 0000000..fdeb333
--- /dev/null
+++ b/Documentation/devicetree/bindings/thermal/brcm,ns-thermal.yaml
@@ -0,0 +1,60 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/thermal/brcm,ns-thermal.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Broadcom Northstar Thermal
+
+maintainers:
+  - Rafał Miłecki <rafal@milecki.pl>
+
+description:
+  Thermal sensor that is part of Northstar's DMU (Device Management Unit).
+
+allOf:
+  - $ref: thermal-sensor.yaml#
+
+properties:
+  compatible:
+    const: brcm,ns-thermal
+
+  reg:
+    description: PVTMON registers range
+    maxItems: 1
+
+  "#thermal-sensor-cells":
+    const: 0
+
+unevaluatedProperties: false
+
+required:
+  - reg
+
+examples:
+  - |
+    thermal: thermal@1800c2c0 {
+        compatible = "brcm,ns-thermal";
+        reg = <0x1800c2c0 0x10>;
+        #thermal-sensor-cells = <0>;
+    };
+
+    thermal-zones {
+        cpu-thermal {
+            polling-delay-passive = <0>;
+            polling-delay = <1000>;
+            coefficients = <(-556) 418000>;
+            thermal-sensors = <&thermal>;
+
+            trips {
+                cpu-crit {
+                    temperature = <125000>;
+                    hysteresis = <0>;
+                    type = "critical";
+                };
+            };
+
+            cooling-maps {
+            };
+        };
+    };

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-04-27 19:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-15 11:16 [PATCH] dt-bindings: thermal: brcm,ns-thermal: convert to the json-schema Rafał Miłecki
2021-04-20 20:08 ` Rob Herring
2021-04-20 21:01 ` [PATCH V2] " Rafał Miłecki
2021-04-21 17:12   ` Rob Herring
2021-04-27 19:44   ` [thermal: thermal/next] dt-bindings: thermal: brcm,ns-thermal: Convert " thermal-bot for Rafał Miłecki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.