Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: thermal: rcar-gen3-thermal: Convert bindings to json-schema

Convert Renesas R-Car Gen3 Thermal bindings documentation to
json-schema.

Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Rob Herring <robh@kernel.org>

authored by

Niklas Söderlund and committed by
Rob Herring
37d1e946 2cb80529

+99 -60
-60
Documentation/devicetree/bindings/thermal/rcar-gen3-thermal.txt
··· 1 - * DT bindings for Renesas R-Car Gen3 Thermal Sensor driver 2 - 3 - On R-Car Gen3 SoCs, the thermal sensor controllers (TSC) control the thermal 4 - sensors (THS) which are the analog circuits for measuring temperature (Tj) 5 - inside the LSI. 6 - 7 - Required properties: 8 - - compatible : "renesas,<soctype>-thermal", 9 - Examples with soctypes are: 10 - - "renesas,r8a774a1-thermal" (RZ/G2M) 11 - - "renesas,r8a774b1-thermal" (RZ/G2N) 12 - - "renesas,r8a7795-thermal" (R-Car H3) 13 - - "renesas,r8a7796-thermal" (R-Car M3-W) 14 - - "renesas,r8a77961-thermal" (R-Car M3-W+) 15 - - "renesas,r8a77965-thermal" (R-Car M3-N) 16 - - "renesas,r8a77980-thermal" (R-Car V3H) 17 - - reg : Address ranges of the thermal registers. Each sensor 18 - needs one address range. Sorting must be done in 19 - increasing order according to datasheet, i.e. 20 - TSC1, TSC2, ... 21 - - clocks : Must contain a reference to the functional clock. 22 - - #thermal-sensor-cells : must be <1>. 23 - 24 - Optional properties: 25 - 26 - - interrupts : interrupts routed to the TSC (must be 3). 27 - - power-domain : Must contain a reference to the power domain. This 28 - property is mandatory if the thermal sensor instance 29 - is part of a controllable power domain. 30 - 31 - Example: 32 - 33 - tsc: thermal@e6198000 { 34 - compatible = "renesas,r8a7795-thermal"; 35 - reg = <0 0xe6198000 0 0x100>, 36 - <0 0xe61a0000 0 0x100>, 37 - <0 0xe61a8000 0 0x100>; 38 - interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>, 39 - <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>, 40 - <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>; 41 - clocks = <&cpg CPG_MOD 522>; 42 - power-domains = <&sysc R8A7795_PD_ALWAYS_ON>; 43 - #thermal-sensor-cells = <1>; 44 - }; 45 - 46 - thermal-zones { 47 - sensor_thermal1: sensor-thermal1 { 48 - polling-delay-passive = <250>; 49 - polling-delay = <1000>; 50 - thermal-sensors = <&tsc 0>; 51 - 52 - trips { 53 - sensor1_crit: sensor1-crit { 54 - temperature = <90000>; 55 - hysteresis = <2000>; 56 - type = "critical"; 57 - }; 58 - }; 59 - }; 60 - };
+99
Documentation/devicetree/bindings/thermal/rcar-gen3-thermal.yaml
··· 1 + # SPDX-License-Identifier: GPL-2.0-only 2 + # Copyright (C) 2020 Renesas Electronics Corp. 3 + %YAML 1.2 4 + --- 5 + $id: http://devicetree.org/schemas/thermal/rcar-gen3-thermal.yaml# 6 + $schema: http://devicetree.org/meta-schemas/core.yaml# 7 + 8 + title: Renesas R-Car Gen3 Thermal Sensor 9 + 10 + description: 11 + On R-Car Gen3 SoCs, the thermal sensor controllers (TSC) control the thermal 12 + sensors (THS) which are the analog circuits for measuring temperature (Tj) 13 + inside the LSI. 14 + 15 + maintainers: 16 + - Niklas Söderlund <niklas.soderlund@ragnatech.se> 17 + 18 + properties: 19 + compatible: 20 + enum: 21 + - renesas,r8a774a1-thermal # RZ/G2M 22 + - renesas,r8a774b1-thermal # RZ/G2N 23 + - renesas,r8a7795-thermal # R-Car H3 24 + - renesas,r8a7796-thermal # R-Car M3-W 25 + - renesas,r8a77961-thermal # R-Car M3-W+ 26 + - renesas,r8a77965-thermal # R-Car M3-N 27 + - renesas,r8a77980-thermal # R-Car V3H 28 + reg: 29 + minItems: 2 30 + maxItems: 3 31 + items: 32 + - description: TSC1 registers 33 + - description: TSC2 registers 34 + - description: TSC3 registers 35 + 36 + interrupts: 37 + items: 38 + - description: TEMP1 interrupt 39 + - description: TEMP2 interrupt 40 + - description: TEMP3 interrupt 41 + 42 + clocks: 43 + maxItems: 1 44 + 45 + power-domains: 46 + maxItems: 1 47 + 48 + resets: 49 + maxItems: 1 50 + 51 + "#thermal-sensor-cells": 52 + const: 1 53 + 54 + required: 55 + - compatible 56 + - reg 57 + - interrupts 58 + - clocks 59 + - power-domains 60 + - resets 61 + - "#thermal-sensor-cells" 62 + 63 + additionalProperties: false 64 + 65 + examples: 66 + - | 67 + #include <dt-bindings/clock/r8a7795-cpg-mssr.h> 68 + #include <dt-bindings/interrupt-controller/arm-gic.h> 69 + #include <dt-bindings/power/r8a7795-sysc.h> 70 + 71 + tsc: thermal@e6198000 { 72 + compatible = "renesas,r8a7795-thermal"; 73 + reg = <0xe6198000 0x100>, 74 + <0xe61a0000 0x100>, 75 + <0xe61a8000 0x100>; 76 + interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>, 77 + <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>, 78 + <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>; 79 + clocks = <&cpg CPG_MOD 522>; 80 + power-domains = <&sysc R8A7795_PD_ALWAYS_ON>; 81 + resets = <&cpg 522>; 82 + #thermal-sensor-cells = <1>; 83 + }; 84 + 85 + thermal-zones { 86 + sensor_thermal: sensor-thermal { 87 + polling-delay-passive = <250>; 88 + polling-delay = <1000>; 89 + thermal-sensors = <&tsc 0>; 90 + 91 + trips { 92 + sensor1_crit: sensor1-crit { 93 + temperature = <90000>; 94 + hysteresis = <2000>; 95 + type = "critical"; 96 + }; 97 + }; 98 + }; 99 + };