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,at91rm9200-pmc" or
10 "atmel,at91sam9g45-pmc" or
11 "atmel,at91sam9n12-pmc" or
12 "atmel,at91sam9x5-pmc" or
14 at91 PMC (Power Management Controller)
15 All at91 specific clocks (clocks defined below) must be child
18 "atmel,at91rm9200-clk-main":
21 "atmel,at91rm9200-clk-master" or
22 "atmel,at91sam9x5-clk-master":
25 "atmel,at91sam9x5-clk-peripheral" or
26 "atmel,at91rm9200-clk-peripheral":
27 at91 peripheral clocks
29 "atmel,at91rm9200-clk-pll" or
30 "atmel,at91sam9g45-clk-pll" or
31 "atmel,at91sam9g20-clk-pllb" or
32 "atmel,sama5d3-clk-pll":
35 "atmel,at91sam9x5-clk-plldiv":
38 "atmel,at91rm9200-clk-programmable" or
39 "atmel,at91sam9g45-clk-programmable" or
40 "atmel,at91sam9x5-clk-programmable":
41 at91 programmable clocks
43 "atmel,at91sam9x5-clk-smd":
44 at91 SMD (Soft Modem) clock
46 "atmel,at91rm9200-clk-system":
49 "atmel,at91rm9200-clk-usb" or
50 "atmel,at91sam9x5-clk-usb" or
51 "atmel,at91sam9n12-clk-usb":
54 "atmel,at91sam9x5-clk-utmi":
57 Required properties for PMC node:
58 - reg : defines the IO memory reserved for the PMC.
59 - #size-cells : shall be 0 (reg is used to encode clk id).
60 - #address-cells : shall be 1 (reg is used to encode clk id).
61 - interrupts : shall be set to PMC interrupt line.
62 - interrupt-controller : tell that the PMC is an interrupt controller.
63 - #interrupt-cells : must be set to 1. The first cell encodes the interrupt id,
64 and reflect the bit position in the PMC_ER/DR/SR registers.
65 You can use the dt macros defined in dt-bindings/clk/at91.h.
66 0 (AT91_PMC_MOSCS) -> main oscillator ready
67 1 (AT91_PMC_LOCKA) -> PLL A ready
68 2 (AT91_PMC_LOCKB) -> PLL B ready
69 3 (AT91_PMC_MCKRDY) -> master clock ready
70 6 (AT91_PMC_LOCKU) -> UTMI PLL clock ready
71 8 .. 15 (AT91_PMC_PCKRDY(id)) -> programmable clock ready
72 16 (AT91_PMC_MOSCSELS) -> main oscillator selected
73 17 (AT91_PMC_MOSCRCS) -> RC main oscillator stabilized
74 18 (AT91_PMC_CFDEV) -> clock failure detected
78 compatible = "atmel,sama5d3-pmc";
81 #interrupt-cells = <2>;
85 /* put at91 clocks here */
88 Required properties for main clock:
89 - interrupt-parent : must reference the PMC node.
90 - interrupts : shall be set to "<0>".
91 - #clock-cells : from common clock binding; shall be set to 0.
92 - clocks (optional if clock-frequency is provided) : shall be the slow clock
93 phandle. This clock is used to calculate the main clock rate if
94 "clock-frequency" is not provided.
95 - clock-frequency : the main oscillator frequency.Prefer the use of
96 "clock-frequency" over automatic clock rate calculation.
100 compatible = "atmel,at91rm9200-clk-main";
101 interrupt-parent = <&pmc>;
105 clock-frequency = <18432000>;
108 Required properties for master clock:
109 - interrupt-parent : must reference the PMC node.
110 - interrupts : shall be set to "<3>".
111 - #clock-cells : from common clock binding; shall be set to 0.
112 - clocks : shall be the master clock sources (see atmel datasheet) phandles.
113 e.g. "<&ck32k>, <&main>, <&plla>, <&pllb>".
114 - atmel,clk-output-range : minimum and maximum clock frequency (two u32
116 e.g. output = <0 133000000>; <=> 0 to 133MHz.
117 - atmel,clk-divisors : master clock divisors table (four u32 fields).
118 0 <=> reserved value.
119 e.g. divisors = <1 2 4 6>;
120 - atmel,master-clk-have-div3-pres : some SoC use the reserved value 7 in the
121 PRES field as CLOCK_DIV3 (e.g sam9x5).
125 compatible = "atmel,at91rm9200-clk-master";
126 interrupt-parent = <&pmc>;
129 atmel,clk-output-range = <0 133000000>;
130 atmel,clk-divisors = <1 2 4 0>;
133 Required properties for peripheral clocks:
134 - #size-cells : shall be 0 (reg is used to encode clk id).
135 - #address-cells : shall be 1 (reg is used to encode clk id).
136 - clocks : shall be the master clock phandle.
137 e.g. clocks = <&mck>;
138 - name: device tree node describing a specific system clock.
139 * #clock-cells : from common clock binding; shall be set to 0.
140 * reg: peripheral id. See Atmel's datasheets to get a full
141 list of peripheral ids.
142 * atmel,clk-output-range : minimum and maximum clock frequency
143 (two u32 fields). Only valid on at91sam9x5-clk-peripheral
148 compatible = "atmel,at91sam9x5-clk-peripheral";
150 #address-cells = <1>;
156 atmel,clk-output-range = <0 133000000>;
162 atmel,clk-output-range = <0 66000000>;
167 Required properties for pll clocks:
168 - interrupt-parent : must reference the PMC node.
169 - interrupts : shall be set to "<1>".
170 - #clock-cells : from common clock binding; shall be set to 0.
171 - clocks : shall be the main clock phandle.
175 - atmel,clk-input-range : minimum and maximum source clock frequency (two u32
177 e.g. input = <1 32000000>; <=> 1 to 32MHz.
178 - #atmel,pll-clk-output-range-cells : number of cells reserved for pll output
179 range description. Sould be set to 2, 3
181 * 1st and 2nd cells represent the frequency range (min-max).
182 * 3rd cell is optional and represents the OUT field value for the given
184 * 4th cell is optional and represents the ICPLL field (PLLICPR
186 - atmel,pll-clk-output-ranges : pll output frequency ranges + optional parameter
187 depending on #atmel,pll-output-range-cells
192 compatible = "atmel,at91sam9g45-clk-pll";
193 interrupt-parent = <&pmc>;
198 atmel,clk-input-range = <2000000 32000000>;
199 #atmel,pll-clk-output-range-cells = <4>;
200 atmel,pll-clk-output-ranges = <74500000 800000000 0 0
201 69500000 750000000 1 0
202 64500000 700000000 2 0
203 59500000 650000000 3 0
204 54500000 600000000 0 1
205 49500000 550000000 1 1
206 44500000 500000000 2 1
207 40000000 450000000 3 1>;
210 Required properties for plldiv clocks (plldiv = pll / 2):
211 - #clock-cells : from common clock binding; shall be set to 0.
212 - clocks : shall be the plla clock phandle.
214 The pll divisor is equal to 2 and cannot be changed.
218 compatible = "atmel,at91sam9x5-clk-plldiv";
223 Required properties for programmable clocks:
224 - interrupt-parent : must reference the PMC node.
225 - #size-cells : shall be 0 (reg is used to encode clk id).
226 - #address-cells : shall be 1 (reg is used to encode clk id).
227 - clocks : shall be the programmable clock source phandles.
228 e.g. clocks = <&clk32k>, <&main>, <&plla>, <&pllb>;
229 - name: device tree node describing a specific prog clock.
230 * #clock-cells : from common clock binding; shall be set to 0.
231 * reg : programmable clock id (register offset from PCKx
233 * interrupts : shall be set to "<(8 + id)>".
237 compatible = "atmel,at91sam9g45-clk-programmable";
239 #address-cells = <1>;
240 interrupt-parent = <&pmc>;
241 clocks = <&clk32k>, <&main>, <&plladiv>, <&utmi>, <&mck>;
257 Required properties for smd clock:
258 - #clock-cells : from common clock binding; shall be set to 0.
259 - clocks : shall be the smd clock source phandles.
260 e.g. clocks = <&plladiv>, <&utmi>;
264 compatible = "atmel,at91sam9x5-clk-smd";
266 clocks = <&plladiv>, <&utmi>;
269 Required properties for system clocks:
270 - #size-cells : shall be 0 (reg is used to encode clk id).
271 - #address-cells : shall be 1 (reg is used to encode clk id).
272 - name: device tree node describing a specific system clock.
273 * #clock-cells : from common clock binding; shall be set to 0.
274 * reg: system clock id (bit position in SCER/SCDR/SCSR registers).
275 See Atmel's datasheet to get a full list of system clock ids.
279 compatible = "atmel,at91rm9200-clk-system";
280 #address-cells = <1>;
303 Required properties for usb clock:
304 - #clock-cells : from common clock binding; shall be set to 0.
305 - clocks : shall be the smd clock source phandles.
306 e.g. clocks = <&pllb>;
307 - atmel,clk-divisors (only available for "atmel,at91rm9200-clk-usb"):
308 usb clock divisor table.
309 e.g. divisors = <1 2 4 0>;
313 compatible = "atmel,at91sam9x5-clk-usb";
315 clocks = <&plladiv>, <&utmi>;
319 compatible = "atmel,at91rm9200-clk-usb";
322 atmel,clk-divisors = <1 2 4 0>;
326 Required properties for utmi clock:
327 - interrupt-parent : must reference the PMC node.
328 - interrupts : shall be set to "<AT91_PMC_LOCKU IRQ_TYPE_LEVEL_HIGH>".
329 - #clock-cells : from common clock binding; shall be set to 0.
330 - clocks : shall be the main clock source phandle.
334 compatible = "atmel,at91sam9x5-clk-utmi";
335 interrupt-parent = <&pmc>;
336 interrupts = <AT91_PMC_LOCKU IRQ_TYPE_LEVEL_HIGH>;