summaryrefslogtreecommitdiffstats
path: root/dts/Bindings/clock/qcom,gcc.yaml
blob: e73a56fb60cac1dd8bdddc3461506ebd7af2618d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
# SPDX-License-Identifier: GPL-2.0-only
%YAML 1.2
---
$id: http://devicetree.org/schemas/bindings/clock/qcom,gcc.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Qualcomm Global Clock & Reset Controller Binding

maintainers:
  - Stephen Boyd <sboyd@kernel.org>
  - Taniya Das <tdas@codeaurora.org>

description: |
  Qualcomm global clock control module which supports the clocks, resets and
  power domains.

properties:
  compatible :
    enum:
       - qcom,gcc-apq8064
       - qcom,gcc-apq8084
       - qcom,gcc-ipq8064
       - qcom,gcc-ipq4019
       - qcom,gcc-ipq8074
       - qcom,gcc-msm8660
       - qcom,gcc-msm8916
       - qcom,gcc-msm8960
       - qcom,gcc-msm8974
       - qcom,gcc-msm8974pro
       - qcom,gcc-msm8974pro-ac
       - qcom,gcc-msm8994
       - qcom,gcc-msm8996
       - qcom,gcc-msm8998
       - qcom,gcc-mdm9615
       - qcom,gcc-qcs404
       - qcom,gcc-sc7180
       - qcom,gcc-sdm630
       - qcom,gcc-sdm660
       - qcom,gcc-sdm845
       - qcom,gcc-sm8150

  clocks:
    minItems: 1
    maxItems: 3
    items:
      - description: Board XO source
      - description: Board active XO source
      - description: Sleep clock source

  clock-names:
    minItems: 1
    maxItems: 3
    items:
      - const: bi_tcxo
      - const: bi_tcxo_ao
      - const: sleep_clk

  '#clock-cells':
    const: 1

  '#reset-cells':
    const: 1

  '#power-domain-cells':
    const: 1

  reg:
    maxItems: 1

  nvmem-cells:
    minItems: 1
    maxItems: 2
    description:
      Qualcomm TSENS (thermal sensor device) on some devices can
      be part of GCC and hence the TSENS properties can also be part
      of the GCC/clock-controller node.
      For more details on the TSENS properties please refer
      Documentation/devicetree/bindings/thermal/qcom-tsens.txt

  nvmem-cell-names:
    minItems: 1
    maxItems: 2
    description:
      Names for each nvmem-cells specified.
    items:
      - const: calib
      - const: calib_backup

  'thermal-sensor-cells':
    const: 1

  protected-clocks:
    description:
       Protected clock specifier list as per common clock binding

required:
  - compatible
  - reg
  - '#clock-cells'
  - '#reset-cells'
  - '#power-domain-cells'

if:
  properties:
    compatible:
      contains:
        const: qcom,gcc-apq8064

then:
  required:
    - nvmem-cells
    - nvmem-cell-names
    - '#thermal-sensor-cells'

else:
  if:
    properties:
      compatible:
        contains:
          enum:
            - qcom,gcc-sm8150
            - qcom,gcc-sc7180
  then:
    required:
       - clocks
       - clock-names


examples:
  # Example for GCC for MSM8960:
  - |
    clock-controller@900000 {
      compatible = "qcom,gcc-msm8960";
      reg = <0x900000 0x4000>;
      #clock-cells = <1>;
      #reset-cells = <1>;
      #power-domain-cells = <1>;
    };


  # Example of GCC with TSENS properties:
  - |
    clock-controller@900000 {
      compatible = "qcom,gcc-apq8064";
      reg = <0x00900000 0x4000>;
      nvmem-cells = <&tsens_calib>, <&tsens_backup>;
      nvmem-cell-names = "calib", "calib_backup";
      #clock-cells = <1>;
      #reset-cells = <1>;
      #power-domain-cells = <1>;
      #thermal-sensor-cells = <1>;
    };

  # Example of GCC with protected-clocks properties:
  - |
    clock-controller@100000 {
      compatible = "qcom,gcc-sdm845";
      reg = <0x100000 0x1f0000>;
      protected-clocks = <187>, <188>, <189>, <190>, <191>;
      #clock-cells = <1>;
      #reset-cells = <1>;
      #power-domain-cells = <1>;
    };

  # Example of GCC with clock node properties for SM8150:
  - |
    clock-controller@100000 {
      compatible = "qcom,gcc-sm8150";
      reg = <0x00100000 0x1f0000>;
      clocks = <&rpmhcc 0>, <&rpmhcc 1>, <&sleep_clk>;
      clock-names = "bi_tcxo", "bi_tcxo_ao", "sleep_clk";
      #clock-cells = <1>;
      #reset-cells = <1>;
      #power-domain-cells = <1>;
     };

  # Example of GCC with clock nodes properties for SC7180:
  - |
    clock-controller@100000 {
      compatible = "qcom,gcc-sc7180";
      reg = <0x100000 0x1f0000>;
      clocks = <&rpmhcc 0>, <&rpmhcc 1>;
      clock-names = "bi_tcxo", "bi_tcxo_ao";
      #clock-cells = <1>;
      #reset-cells = <1>;
      #power-domain-cells = <1>;
    };
...