0001 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/thermal/samsung,exynos-thermal.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006
0007 title: Samsung Exynos SoC Thermal Management Unit (TMU)
0008
0009 maintainers:
0010 - Krzysztof Kozlowski <krzk@kernel.org>
0011
0012 description: |
0013 For multi-instance tmu each instance should have an alias correctly numbered
0014 in "aliases" node.
0015
0016 properties:
0017 compatible:
0018 enum:
0019 - samsung,exynos3250-tmu
0020 - samsung,exynos4412-tmu
0021 - samsung,exynos4210-tmu
0022 - samsung,exynos5250-tmu
0023 - samsung,exynos5260-tmu
0024 # For TMU channel 0, 1 on Exynos5420:
0025 - samsung,exynos5420-tmu
0026 # For TMU channels 2, 3 and 4 of Exynos5420:
0027 - samsung,exynos5420-tmu-ext-triminfo
0028 - samsung,exynos5433-tmu
0029 - samsung,exynos7-tmu
0030
0031 clocks:
0032 minItems: 1
0033 maxItems: 3
0034
0035 clock-names:
0036 minItems: 1
0037 maxItems: 3
0038
0039 interrupts:
0040 description: |
0041 The Exynos TMU supports generating interrupts when reaching given
0042 temperature thresholds. Number of supported thermal trip points depends
0043 on the SoC (only first trip points defined in DT will be configured)::
0044 - most of SoC: 4
0045 - samsung,exynos5433-tmu: 8
0046 - samsung,exynos7-tmu: 8
0047 maxItems: 1
0048
0049 reg:
0050 items:
0051 - description: TMU instance registers.
0052 - description: |
0053 Shared TMU registers.
0054
0055 Note:: On Exynos5420, the TRIMINFO register is misplaced for TMU
0056 channels 2, 3 and 4 Use "samsung,exynos5420-tmu-ext-triminfo" in
0057 cases, there is a misplaced register, also provide clock to access
0058 that base.
0059 TRIMINFO at 0x1006c000 contains data for TMU channel 3
0060 TRIMINFO at 0x100a0000 contains data for TMU channel 4
0061 TRIMINFO at 0x10068000 contains data for TMU channel 2
0062 minItems: 1
0063
0064 '#thermal-sensor-cells': true
0065
0066 vtmu-supply:
0067 description: The regulator node supplying voltage to TMU.
0068
0069 required:
0070 - compatible
0071 - clocks
0072 - clock-names
0073 - interrupts
0074 - reg
0075
0076 allOf:
0077 - $ref: /schemas/thermal/thermal-sensor.yaml
0078 - if:
0079 properties:
0080 compatible:
0081 contains:
0082 const: samsung,exynos5420-tmu-ext-triminfo
0083 then:
0084 properties:
0085 clocks:
0086 items:
0087 - description:
0088 Operational clock for TMU channel.
0089 - description:
0090 Optional clock to access the shared registers (e.g. TRIMINFO) of TMU
0091 channel.
0092 clock-names:
0093 items:
0094 - const: tmu_apbif
0095 - const: tmu_triminfo_apbif
0096 reg:
0097 minItems: 2
0098 maxItems: 2
0099 - if:
0100 properties:
0101 compatible:
0102 contains:
0103 enum:
0104 - samsung,exynos5433-tmu
0105 - samsung,exynos7-tmu
0106 then:
0107 properties:
0108 clocks:
0109 items:
0110 - description:
0111 Operational clock for TMU channel.
0112 - description:
0113 Optional special clock for functional operation of TMU channel.
0114 clock-names:
0115 items:
0116 - const: tmu_apbif
0117 - const: tmu_sclk
0118 reg:
0119 minItems: 1
0120 maxItems: 1
0121
0122 - if:
0123 properties:
0124 compatible:
0125 contains:
0126 enum:
0127 - samsung,exynos3250-tmu
0128 - samsung,exynos4412-tmu
0129 - samsung,exynos4210-tmu
0130 - samsung,exynos5250-tmu
0131 - samsung,exynos5260-tmu
0132 - samsung,exynos5420-tmu
0133 then:
0134 properties:
0135 clocks:
0136 minItems: 1
0137 maxItems: 1
0138 reg:
0139 minItems: 1
0140 maxItems: 1
0141
0142 additionalProperties: false
0143
0144 examples:
0145 - |
0146 #include <dt-bindings/clock/exynos4.h>
0147
0148 tmu@100c0000 {
0149 compatible = "samsung,exynos4412-tmu";
0150 reg = <0x100C0000 0x100>;
0151 interrupt-parent = <&combiner>;
0152 interrupts = <2 4>;
0153 #thermal-sensor-cells = <0>;
0154 clocks = <&clock CLK_TMU_APBIF>;
0155 clock-names = "tmu_apbif";
0156 vtmu-supply = <&ldo10_reg>;
0157 };
0158
0159 - |
0160 #include <dt-bindings/interrupt-controller/arm-gic.h>
0161
0162 tmu@10068000 {
0163 compatible = "samsung,exynos5420-tmu-ext-triminfo";
0164 reg = <0x10068000 0x100>, <0x1006c000 0x4>;
0165 interrupts = <GIC_SPI 184 IRQ_TYPE_LEVEL_HIGH>;
0166 #thermal-sensor-cells = <0>;
0167 clocks = <&clock 318>, <&clock 318>; /* CLK_TMU */
0168 clock-names = "tmu_apbif", "tmu_triminfo_apbif";
0169 vtmu-supply = <&ldo7_reg>;
0170 };
0171
0172 - |
0173 #include <dt-bindings/interrupt-controller/arm-gic.h>
0174
0175 tmu@10060000 {
0176 compatible = "samsung,exynos5433-tmu";
0177 reg = <0x10060000 0x200>;
0178 interrupts = <GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>;
0179 #thermal-sensor-cells = <0>;
0180 clocks = <&cmu_peris 3>, /* CLK_PCLK_TMU0_APBIF */
0181 <&cmu_peris 35>; /* CLK_SCLK_TMU0 */
0182 clock-names = "tmu_apbif", "tmu_sclk";
0183 vtmu-supply = <&ldo3_reg>;
0184 };