1 Device Tree Clock bindings for arch-at91
3 This binding uses the common clock binding[1].
5 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
8 - compatible : shall be one of the following:
9 "atmel,at91sam9x5-sckc" or
11 at91 SCKC (Slow Clock Controller)
12 This node contains the slow clock definitions.
14 "atmel,at91sam9x5-clk-slow-osc":
17 "atmel,at91sam9x5-clk-slow-rc-osc":
18 at91 internal slow RC oscillator
20 "atmel,at91rm9200-pmc" or
21 "atmel,at91sam9g45-pmc" or
22 "atmel,at91sam9n12-pmc" or
23 "atmel,at91sam9x5-pmc" or
25 at91 PMC (Power Management Controller)
26 All at91 specific clocks (clocks defined below) must be child
29 "atmel,at91sam9x5-clk-slow" (under sckc node)
31 "atmel,at91sam9260-clk-slow" (under pmc node):
34 "atmel,at91rm9200-clk-main-osc"
35 "atmel,at91sam9x5-clk-main-rc-osc"
38 "atmel,at91sam9x5-clk-main"
39 "atmel,at91rm9200-clk-main":
42 "atmel,at91rm9200-clk-master" or
43 "atmel,at91sam9x5-clk-master":
46 "atmel,at91sam9x5-clk-peripheral" or
47 "atmel,at91rm9200-clk-peripheral":
48 at91 peripheral clocks
50 "atmel,at91rm9200-clk-pll" or
51 "atmel,at91sam9g45-clk-pll" or
52 "atmel,at91sam9g20-clk-pllb" or
53 "atmel,sama5d3-clk-pll":
56 "atmel,at91sam9x5-clk-plldiv":
59 "atmel,at91rm9200-clk-programmable" or
60 "atmel,at91sam9g45-clk-programmable" or
61 "atmel,at91sam9x5-clk-programmable":
62 at91 programmable clocks
64 "atmel,at91sam9x5-clk-smd":
65 at91 SMD (Soft Modem) clock
67 "atmel,at91rm9200-clk-system":
70 "atmel,at91rm9200-clk-usb" or
71 "atmel,at91sam9x5-clk-usb" or
72 "atmel,at91sam9n12-clk-usb":
75 "atmel,at91sam9x5-clk-utmi":
78 "atmel,sama5d4-clk-h32mx":
81 "atmel,sama5d2-clk-generated":
84 "atmel,sama5d2-clk-audio-pll-frac":
85 at91 audio fractional pll
87 "atmel,sama5d2-clk-audio-pll-pad":
88 at91 audio pll CLK_AUDIO output pin
90 "atmel,sama5d2-clk-audio-pll-pmc"
91 at91 audio pll output on AUDIOPLLCLK that feeds the PMC
92 and can be used by peripheral clock or generic clock
94 Required properties for SCKC node:
95 - reg : defines the IO memory reserved for the SCKC.
96 - #size-cells : shall be 0 (reg is used to encode clk id).
97 - #address-cells : shall be 1 (reg is used to encode clk id).
101 sckc: sckc@fffffe50 {
102 compatible = "atmel,sama5d3-pmc";
103 reg = <0xfffffe50 0x4>
105 #address-cells = <1>;
107 /* put at91 slow clocks here */
111 Required properties for internal slow RC oscillator:
112 - #clock-cells : from common clock binding; shall be set to 0.
113 - clock-frequency : define the internal RC oscillator frequency.
116 - clock-accuracy : define the internal RC oscillator accuracy.
119 slow_rc_osc: slow_rc_osc {
120 compatible = "atmel,at91sam9x5-clk-slow-rc-osc";
121 clock-frequency = <32768>;
122 clock-accuracy = <50000000>;
125 Required properties for slow oscillator:
126 - #clock-cells : from common clock binding; shall be set to 0.
127 - clocks : shall encode the main osc source clk sources (see atmel datasheet).
130 - atmel,osc-bypass : boolean property. Set this when a clock signal is directly
135 compatible = "atmel,at91rm9200-clk-slow-osc";
137 clocks = <&slow_xtal>;
140 Required properties for slow clock:
141 - #clock-cells : from common clock binding; shall be set to 0.
142 - clocks : shall encode the slow clk sources (see atmel datasheet).
146 compatible = "atmel,at91sam9x5-clk-slow";
148 clocks = <&slow_rc_osc &slow_osc>;
151 Required properties for PMC node:
152 - reg : defines the IO memory reserved for the PMC.
153 - #size-cells : shall be 0 (reg is used to encode clk id).
154 - #address-cells : shall be 1 (reg is used to encode clk id).
155 - interrupts : shall be set to PMC interrupt line.
156 - interrupt-controller : tell that the PMC is an interrupt controller.
157 - #interrupt-cells : must be set to 1. The first cell encodes the interrupt id,
158 and reflect the bit position in the PMC_ER/DR/SR registers.
159 You can use the dt macros defined in dt-bindings/clock/at91.h.
160 0 (AT91_PMC_MOSCS) -> main oscillator ready
161 1 (AT91_PMC_LOCKA) -> PLL A ready
162 2 (AT91_PMC_LOCKB) -> PLL B ready
163 3 (AT91_PMC_MCKRDY) -> master clock ready
164 6 (AT91_PMC_LOCKU) -> UTMI PLL clock ready
165 8 .. 15 (AT91_PMC_PCKRDY(id)) -> programmable clock ready
166 16 (AT91_PMC_MOSCSELS) -> main oscillator selected
167 17 (AT91_PMC_MOSCRCS) -> RC main oscillator stabilized
168 18 (AT91_PMC_CFDEV) -> clock failure detected
172 compatible = "atmel,sama5d3-pmc";
173 interrupts = <1 4 7>;
174 interrupt-controller;
175 #interrupt-cells = <2>;
177 #address-cells = <1>;
179 /* put at91 clocks here */
182 Required properties for main clock internal RC oscillator:
183 - interrupt-parent : must reference the PMC node.
184 - interrupts : shall be set to "<0>".
185 - clock-frequency : define the internal RC oscillator frequency.
188 - clock-accuracy : define the internal RC oscillator accuracy.
191 main_rc_osc: main_rc_osc {
192 compatible = "atmel,at91sam9x5-clk-main-rc-osc";
193 interrupt-parent = <&pmc>;
195 clock-frequency = <12000000>;
196 clock-accuracy = <50000000>;
199 Required properties for main clock oscillator:
200 - interrupt-parent : must reference the PMC node.
201 - interrupts : shall be set to "<0>".
202 - #clock-cells : from common clock binding; shall be set to 0.
203 - clocks : shall encode the main osc source clk sources (see atmel datasheet).
206 - atmel,osc-bypass : boolean property. Specified if a clock signal is provided
209 clock signal is directly provided on XIN pin.
213 compatible = "atmel,at91rm9200-clk-main-osc";
214 interrupt-parent = <&pmc>;
217 clocks = <&main_xtal>;
220 Required properties for main clock:
221 - interrupt-parent : must reference the PMC node.
222 - interrupts : shall be set to "<0>".
223 - #clock-cells : from common clock binding; shall be set to 0.
224 - clocks : shall encode the main clk sources (see atmel datasheet).
228 compatible = "atmel,at91sam9x5-clk-main";
229 interrupt-parent = <&pmc>;
232 clocks = <&main_rc_osc &main_osc>;
235 Required properties for master clock:
236 - interrupt-parent : must reference the PMC node.
237 - interrupts : shall be set to "<3>".
238 - #clock-cells : from common clock binding; shall be set to 0.
239 - clocks : shall be the master clock sources (see atmel datasheet) phandles.
240 e.g. "<&ck32k>, <&main>, <&plla>, <&pllb>".
241 - atmel,clk-output-range : minimum and maximum clock frequency (two u32
243 e.g. output = <0 133000000>; <=> 0 to 133MHz.
244 - atmel,clk-divisors : master clock divisors table (four u32 fields).
245 0 <=> reserved value.
246 e.g. divisors = <1 2 4 6>;
247 - atmel,master-clk-have-div3-pres : some SoC use the reserved value 7 in the
248 PRES field as CLOCK_DIV3 (e.g sam9x5).
252 compatible = "atmel,at91rm9200-clk-master";
253 interrupt-parent = <&pmc>;
256 atmel,clk-output-range = <0 133000000>;
257 atmel,clk-divisors = <1 2 4 0>;
260 Required properties for peripheral clocks:
261 - #size-cells : shall be 0 (reg is used to encode clk id).
262 - #address-cells : shall be 1 (reg is used to encode clk id).
263 - clocks : shall be the master clock phandle.
264 e.g. clocks = <&mck>;
265 - name: device tree node describing a specific peripheral clock.
266 * #clock-cells : from common clock binding; shall be set to 0.
267 * reg: peripheral id. See Atmel's datasheets to get a full
268 list of peripheral ids.
269 * atmel,clk-output-range : minimum and maximum clock frequency
270 (two u32 fields). Only valid on at91sam9x5-clk-peripheral
275 compatible = "atmel,at91sam9x5-clk-peripheral";
277 #address-cells = <1>;
283 atmel,clk-output-range = <0 133000000>;
289 atmel,clk-output-range = <0 66000000>;
294 Required properties for pll clocks:
295 - interrupt-parent : must reference the PMC node.
296 - interrupts : shall be set to "<1>".
297 - #clock-cells : from common clock binding; shall be set to 0.
298 - clocks : shall be the main clock phandle.
302 - atmel,clk-input-range : minimum and maximum source clock frequency (two u32
304 e.g. input = <1 32000000>; <=> 1 to 32MHz.
305 - #atmel,pll-clk-output-range-cells : number of cells reserved for pll output
306 range description. Sould be set to 2, 3
308 * 1st and 2nd cells represent the frequency range (min-max).
309 * 3rd cell is optional and represents the OUT field value for the given
311 * 4th cell is optional and represents the ICPLL field (PLLICPR
313 - atmel,pll-clk-output-ranges : pll output frequency ranges + optional parameter
314 depending on #atmel,pll-output-range-cells
319 compatible = "atmel,at91sam9g45-clk-pll";
320 interrupt-parent = <&pmc>;
325 atmel,clk-input-range = <2000000 32000000>;
326 #atmel,pll-clk-output-range-cells = <4>;
327 atmel,pll-clk-output-ranges = <74500000 800000000 0 0
328 69500000 750000000 1 0
329 64500000 700000000 2 0
330 59500000 650000000 3 0
331 54500000 600000000 0 1
332 49500000 550000000 1 1
333 44500000 500000000 2 1
334 40000000 450000000 3 1>;
337 Required properties for plldiv clocks (plldiv = pll / 2):
338 - #clock-cells : from common clock binding; shall be set to 0.
339 - clocks : shall be the plla clock phandle.
341 The pll divisor is equal to 2 and cannot be changed.
345 compatible = "atmel,at91sam9x5-clk-plldiv";
350 Required properties for programmable clocks:
351 - interrupt-parent : must reference the PMC node.
352 - #size-cells : shall be 0 (reg is used to encode clk id).
353 - #address-cells : shall be 1 (reg is used to encode clk id).
354 - clocks : shall be the programmable clock source phandles.
355 e.g. clocks = <&clk32k>, <&main>, <&plla>, <&pllb>;
356 - name: device tree node describing a specific prog clock.
357 * #clock-cells : from common clock binding; shall be set to 0.
358 * reg : programmable clock id (register offset from PCKx
360 * interrupts : shall be set to "<(8 + id)>".
364 compatible = "atmel,at91sam9g45-clk-programmable";
366 #address-cells = <1>;
367 interrupt-parent = <&pmc>;
368 clocks = <&clk32k>, <&main>, <&plladiv>, <&utmi>, <&mck>;
384 Required properties for smd clock:
385 - #clock-cells : from common clock binding; shall be set to 0.
386 - clocks : shall be the smd clock source phandles.
387 e.g. clocks = <&plladiv>, <&utmi>;
391 compatible = "atmel,at91sam9x5-clk-smd";
393 clocks = <&plladiv>, <&utmi>;
396 Required properties for system clocks:
397 - #size-cells : shall be 0 (reg is used to encode clk id).
398 - #address-cells : shall be 1 (reg is used to encode clk id).
399 - name: device tree node describing a specific system clock.
400 * #clock-cells : from common clock binding; shall be set to 0.
401 * reg: system clock id (bit position in SCER/SCDR/SCSR registers).
402 See Atmel's datasheet to get a full list of system clock ids.
406 compatible = "atmel,at91rm9200-clk-system";
407 #address-cells = <1>;
430 Required properties for usb clock:
431 - #clock-cells : from common clock binding; shall be set to 0.
432 - clocks : shall be the smd clock source phandles.
433 e.g. clocks = <&pllb>;
434 - atmel,clk-divisors (only available for "atmel,at91rm9200-clk-usb"):
435 usb clock divisor table.
436 e.g. divisors = <1 2 4 0>;
440 compatible = "atmel,at91sam9x5-clk-usb";
442 clocks = <&plladiv>, <&utmi>;
446 compatible = "atmel,at91rm9200-clk-usb";
449 atmel,clk-divisors = <1 2 4 0>;
453 Required properties for utmi clock:
454 - interrupt-parent : must reference the PMC node.
455 - interrupts : shall be set to "<AT91_PMC_LOCKU IRQ_TYPE_LEVEL_HIGH>".
456 - #clock-cells : from common clock binding; shall be set to 0.
457 - clocks : shall be the main clock source phandle.
461 compatible = "atmel,at91sam9x5-clk-utmi";
462 interrupt-parent = <&pmc>;
463 interrupts = <AT91_PMC_LOCKU IRQ_TYPE_LEVEL_HIGH>;
468 Required properties for 32 bits bus Matrix clock (h32mx clock):
469 - #clock-cells : from common clock binding; shall be set to 0.
470 - clocks : shall be the master clock source phandle.
475 compatible = "atmel,sama5d4-clk-h32mx";
479 Required properties for generated clocks:
480 - #size-cells : shall be 0 (reg is used to encode clk id).
481 - #address-cells : shall be 1 (reg is used to encode clk id).
482 - clocks : shall be the generated clock source phandles.
483 e.g. clocks = <&clk32k>, <&main>, <&plladiv>, <&utmi>, <&mck>, <&audio_pll_pmc>;
484 - name: device tree node describing a specific generated clock.
485 * #clock-cells : from common clock binding; shall be set to 0.
486 * reg: peripheral id. See Atmel's datasheets to get a full
487 list of peripheral ids.
488 * atmel,clk-output-range : minimum and maximum clock frequency
493 compatible = "atmel,sama5d2-clk-generated";
494 #address-cells = <1>;
496 clocks = <&clk32k>, <&main>, <&plladiv>, <&utmi>, <&mck>, <&audio_pll_pmc>;
498 tcb0_gclk: tcb0_gclk {
501 atmel,clk-output-range = <0 83000000>;
507 atmel,clk-output-range = <0 83000000>;