2 * Copyright (C) 2014 ROCKCHIP, Inc.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 #include <dt-bindings/clock/rockchip,rk3036.h>
19 compatible = "rockchip,rk-clocks";
22 ranges = <0x0 0x20000000 0x1f0>;
25 compatible = "rockchip,rk-fixed-rate-cons";
28 compatible = "rockchip,rk-fixed-clock";
29 clock-output-names = "xin24m";
30 clock-frequency = <24000000>;
35 compatible = "rockchip,rk-fixed-clock";
37 clock-output-names = "xin12m";
38 clock-frequency = <12000000>;
42 rmii_clkin: rmii_clkin {
43 compatible = "rockchip,rk-fixed-clock";
44 clock-output-names = "rmii_clkin";
45 clock-frequency = <0>;
50 compatible = "rockchip,rk-fixed-clock";
51 clock-output-names = "usb_480m";
52 clock-frequency = <480000000>;
56 i2s_clkin: i2s_clkin {
57 compatible = "rockchip,rk-fixed-clock";
58 clock-output-names = "i2s_clkin";
59 clock-frequency = <0>;
64 compatible = "rockchip,rk-fixed-clock";
65 clock-output-names = "jtag_tck";
66 clock-frequency = <0>;
71 compatible = "rockchip,rk-fixed-clock";
72 clock-output-names = "dummy";
73 clock-frequency = <0>;
77 dummy_cpll: dummy_cpll {
78 compatible = "rockchip,rk-fixed-clock";
79 clock-output-names = "dummy_cpll";
80 clock-frequency = <0>;
87 compatible = "rockchip,rk-fixed-factor-cons";
89 otgphy0_12m: otgphy0_12m {
90 compatible = "rockchip,rk-fixed-factor-clock";
91 clocks = <&clk_gates1 5>;
92 clock-output-names = "otgphy0_12m";
98 hclk_vcodec: hclk_vcodec {
99 compatible = "rockchip,rk-fixed-factor-clock";
100 clocks = <&aclk_vcodec_pre>;
101 clock-output-names = "hclk_vcodec";
110 compatible = "rockchip,rk-clock-regs";
111 #address-cells = <1>;
113 reg = <0x0000 0x01f0>;
116 /* PLL control regs */
118 compatible = "rockchip,rk-pll-cons";
119 #address-cells = <1>;
123 clk_apll: pll-clk@0000 {
124 compatible = "rockchip,rk3188-pll-clk";
126 mode-reg = <0x0040 0>;
127 status-reg = <0x0004 10>;
129 clock-output-names = "clk_apll";
130 rockchip,pll-type = <CLK_PLL_3036_APLL>;
134 clk_dpll: pll-clk@0010 {
135 compatible = "rockchip,rk3188-pll-clk";
137 mode-reg = <0x0040 4>;
138 status-reg = <0x0014 10>;
140 clock-output-names = "clk_dpll";
141 rockchip,pll-type = <CLK_PLL_3036PLUS_AUTO>;
145 clk_gpll: pll-clk@0030 {
146 compatible = "rockchip,rk3188-pll-clk";
148 mode-reg = <0x0040 12>;
149 status-reg = <0x0034 10>;
151 clock-output-names = "clk_gpll";
152 rockchip,pll-type = <CLK_PLL_3036PLUS_AUTO>;
154 #clock-init-cells = <1>;
159 /* Select control regs */
161 compatible = "rockchip,rk-sel-cons";
162 #address-cells = <1>;
166 clk_sel_con0: sel-con@0044 {
167 compatible = "rockchip,rk3188-selcon";
169 #address-cells = <1>;
172 clk_core_div: clk_core_div {
173 compatible = "rockchip,rk3188-div-con";
174 rockchip,bits = <0 5>;
175 clocks = <&clk_core>;
176 clock-output-names = "clk_core";
177 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
179 rockchip,clkops-idx = <CLKOPS_RATE_CORE>;
180 rockchip,flags = <(CLK_GET_RATE_NOCACHE |
181 CLK_SET_RATE_NO_REPARENT)>;
184 /* reg[6:5]: reserved */
186 clk_core: clk_core_mux {
187 compatible = "rockchip,rk3188-mux-con";
188 rockchip,bits = <7 1>;
189 clocks = <&clk_apll>, <&clk_gates0 6>;
190 clock-output-names = "clk_core";
192 #clock-init-cells = <1>;
195 aclk_cpu_pre_div: aclk_cpu_pre_div {
196 compatible = "rockchip,rk3188-div-con";
197 rockchip,bits = <8 5>;
198 clocks = <&aclk_cpu_pre>;
199 clock-output-names = "aclk_cpu_pre";
200 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
202 rockchip,clkops-idx =
203 <CLKOPS_RATE_MUX_DIV>;
204 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
207 /* reg[13]: reserved */
209 aclk_cpu_pre: aclk_cpu_pre_mux {
210 compatible = "rockchip,rk3188-mux-con";
211 rockchip,bits = <14 2>;
212 clocks = <&clk_apll>, <&clk_dpll>,<&clk_gpll>;
213 clock-output-names = "aclk_cpu_pre";
215 #clock-init-cells = <1>;
220 clk_sel_con1: sel-con@0048 {
221 compatible = "rockchip,rk3188-selcon";
223 #address-cells = <1>;
226 pclk_dbg_div: pclk_dbg_div {
227 compatible = "rockchip,rk3188-div-con";
228 rockchip,bits = <0 4>;
229 clocks = <&clk_core>;
230 clock-output-names = "pclk_dbg";
231 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
233 rockchip,clkops-idx = <CLKOPS_RATE_CORE_CHILD>;
236 aclk_core_pre: aclk_core_pre_div {
237 compatible = "rockchip,rk3188-div-con";
238 rockchip,bits = <4 3>;
239 clocks = <&clk_core>;
240 clock-output-names = "aclk_core_pre";
241 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
243 rockchip,clkops-idx = <CLKOPS_RATE_CORE_CHILD>;
246 /* reg[7]: reserved */
248 hclk_cpu_pre: hclk_cpu_pre_div {
249 compatible = "rockchip,rk3188-div-con";
250 rockchip,bits = <8 2>;
251 clocks = <&aclk_cpu_pre>;
252 clock-output-names = "hclk_cpu_pre";
253 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
255 #clock-init-cells = <1>;
258 /* reg[11:10]: reserved */
260 pclk_cpu_pre: pclk_cpu_pre_div {
261 compatible = "rockchip,rk3188-div-con";
262 rockchip,bits = <12 3>;
263 clocks = <&aclk_cpu_pre>;
264 clock-output-names = "pclk_cpu_pre";
265 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
267 #clock-init-cells = <1>;
270 /* reg[15]: reserved */
273 clk_sel_con2: sel-con@004c {
274 compatible = "rockchip,rk3188-selcon";
276 #address-cells = <1>;
279 /* reg[3:0]: reserved */
281 clk_timer0: clk_timer0_mux {
282 compatible = "rockchip,rk3188-mux-con";
283 rockchip,bits = <4 1>;
284 clocks = <&xin24m>, <&aclk_peri_pre>;
285 clock-output-names = "clk_timer0";
287 #clock-init-cells = <1>;
290 clk_timer1: clk_timer1_mux {
291 compatible = "rockchip,rk3188-mux-con";
292 rockchip,bits = <5 1>;
293 clocks = <&xin24m>, <&aclk_peri_pre>;
294 clock-output-names = "clk_timer1";
296 #clock-init-cells = <1>;
299 clk_timer2: clk_timer2_mux {
300 compatible = "rockchip,rk3188-mux-con";
301 rockchip,bits = <6 1>;
302 clocks = <&xin24m>, <&aclk_peri_pre>;
303 clock-output-names = "clk_timer2";
305 #clock-init-cells = <1>;
308 clk_timer3: clk_timer3_mux {
309 compatible = "rockchip,rk3188-mux-con";
310 rockchip,bits = <7 1>;
311 clocks = <&xin24m>, <&aclk_peri_pre>;
312 clock-output-names = "clk_timer3";
314 #clock-init-cells = <1>;
317 /* reg[15:8]: reserved */
320 clk_sel_con3: sel-con@0050 {
321 compatible = "rockchip,rk3188-selcon";
323 #address-cells = <1>;
326 clk_i2s_pll_div: clk_i2s_pll_div {
327 compatible = "rockchip,rk3188-div-con";
328 rockchip,bits = <0 7>;
329 clocks = <&clk_i2s_pll>;
330 clock-output-names = "clk_i2s_pll";
331 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
333 rockchip,clkops-idx =
334 <CLKOPS_RATE_MUX_DIV>;
335 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
338 /* reg[7]: reserved */
340 clk_i2s: clk_i2s_mux {
341 compatible = "rockchip,rk3188-mux-con";
342 rockchip,bits = <8 2>;
343 clocks = <&clk_i2s_pll_div>, <&i2s_frac>, <&i2s_clkin>, <&xin12m>;
344 clock-output-names = "clk_i2s";
346 rockchip,clkops-idx =
347 <CLKOPS_RATE_RK3288_I2S>;
348 rockchip,flags = <CLK_SET_RATE_PARENT>;
351 /* reg[11:10]: reserved */
353 clk_i2s_out: i2s_outclk_mux {
354 compatible = "rockchip,rk3188-mux-con";
355 rockchip,bits = <12 1>;
356 clocks = <&xin12m>, <&clk_i2s>;
357 clock-output-names = "i2s_clkout";
361 /* reg[13]: reserved */
363 clk_i2s_pll: i2s_pll_mux {
364 compatible = "rockchip,rk3188-mux-con";
365 rockchip,bits = <14 2>;
366 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>;
367 clock-output-names = "clk_i2s_pll";
369 #clock-init-cells = <1>;
374 clk_sel_con5: sel-con@0058 {
375 compatible = "rockchip,rk3188-selcon";
377 #address-cells = <1>;
380 spdif_div: spdif_div {
381 compatible = "rockchip,rk3188-div-con";
382 rockchip,bits = <0 7>;
383 clocks = <&clk_spdif_pll>;
384 clock-output-names = "clk_spdif_pll";
385 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
387 rockchip,clkops-idx =
388 <CLKOPS_RATE_MUX_DIV>;
389 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
392 /* reg[7]: reserved */
394 clk_spdif: spdif_mux {
395 compatible = "rockchip,rk3188-mux-con";
396 rockchip,bits = <8 2>;
397 clocks = <&spdif_div>, <&spdif_frac>, <&xin12m>;
398 clock-output-names = "clk_spdif";
400 rockchip,clkops-idx =
401 <CLKOPS_RATE_RK3288_I2S>;
402 rockchip,flags = <CLK_SET_RATE_PARENT>;
405 clk_spdif_pll: spdif_pll_mux {
406 compatible = "rockchip,rk3188-mux-con";
407 rockchip,bits = <10 2>;
408 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>;
409 clock-output-names = "clk_spdif_pll";
411 #clock-init-cells = <1>;
414 /* reg[15:12]: reserved */
417 clk_sel_con7: sel-con@0060 {
418 compatible = "rockchip,rk3188-selcon";
420 #address-cells = <1>;
424 compatible = "rockchip,rk3188-frac-con";
425 clocks = <&clk_i2s_pll>;
426 clock-output-names = "i2s_frac";
427 /* numerator denominator */
428 rockchip,bits = <0 32>;
429 rockchip,clkops-idx =
435 clk_sel_con9: sel-con@0068 {
436 compatible = "rockchip,rk3188-selcon";
438 #address-cells = <1>;
441 spdif_frac: spdif_frac {
442 compatible = "rockchip,rk3188-frac-con";
443 clocks = <&spdif_div>;
444 clock-output-names = "spdif_frac";
445 /* numerator denominator */
446 rockchip,bits = <0 32>;
447 rockchip,clkops-idx =
453 clk_sel_con10: sel-con@006c {
454 compatible = "rockchip,rk3188-selcon";
456 #address-cells = <1>;
459 aclk_peri_pre_div: aclk_peri_pre_div {
460 compatible = "rockchip,rk3188-div-con";
461 rockchip,bits = <0 5>;
462 clocks = <&aclk_peri_pre>;
463 clock-output-names = "aclk_peri_pre";
464 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
466 rockchip,clkops-idx =
467 <CLKOPS_RATE_MUX_DIV>;
468 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
471 /* reg[7:5]: reserved */
473 hclk_peri_pre: hclk_peri_pre_div {
474 compatible = "rockchip,rk3188-div-con";
475 rockchip,bits = <8 2>;
476 clocks = <&aclk_peri_pre>;
477 clock-output-names = "hclk_peri_pre";
478 rockchip,div-type = <CLK_DIVIDER_USER_DEFINE>;
479 rockchip,div-relations =
484 #clock-init-cells = <1>;
487 /* reg[11:10]: reserved */
489 pclk_peri_pre: pclk_peri_div {
490 compatible = "rockchip,rk3188-div-con";
491 rockchip,bits = <12 2>;
492 clocks = <&aclk_peri_pre>;
493 clock-output-names = "pclk_peri_pre";
494 rockchip,div-type = <CLK_DIVIDER_USER_DEFINE>;
495 rockchip,div-relations =
501 #clock-init-cells = <1>;
504 aclk_peri_pre: aclk_peri_pre_mux {
505 compatible = "rockchip,rk3188-mux-con";
506 rockchip,bits = <14 2>;
507 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>;
508 clock-output-names = "aclk_peri_pre";
510 #clock-init-cells = <1>;
514 clk_sel_con11: sel-con@0070 {
515 compatible = "rockchip,rk3188-selcon";
517 #address-cells = <1>;
520 clk_sdmmc0_div: clk_sdmmc0_div {
521 compatible = "rockchip,rk3188-div-con";
522 rockchip,bits = <0 6>;
523 clocks = <&clk_sdmmc0>;
524 clock-output-names = "clk_sdmmc0";
525 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
527 rockchip,clkops-idx =
528 <CLKOPS_RATE_MUX_EVENDIV>;
531 /* reg[7]: reserved */
533 clk_sdio_div: clk_sdio_div {
534 compatible = "rockchip,rk3188-div-con";
535 rockchip,bits = <8 7>;
536 clocks = <&clk_sdio>;
537 clock-output-names = "clk_sdio";
538 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
540 rockchip,clkops-idx =
541 <CLKOPS_RATE_MUX_EVENDIV>;
544 /* reg[15]: reserved */
548 clk_sel_con12: sel-con@0074 {
549 compatible = "rockchip,rk3188-selcon";
551 #address-cells = <1>;
554 clk_emmc_div: clk_emmc_div {
555 compatible = "rockchip,rk3188-div-con";
556 rockchip,bits = <0 7>;
557 clocks = <&clk_emmc>;
558 clock-output-names = "clk_emmc";
559 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
561 rockchip,clkops-idx =
562 <CLKOPS_RATE_MUX_EVENDIV>;
565 /* reg[7]: reserved */
567 clk_sdmmc0: clk_sdmmc0_mux {
568 compatible = "rockchip,rk3188-mux-con";
569 rockchip,bits = <8 2>;
570 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>, <&xin24m>;
571 clock-output-names = "clk_sdmmc0";
575 clk_sdio: clk_sdio_mux {
576 compatible = "rockchip,rk3188-mux-con";
577 rockchip,bits = <10 2>;
578 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>, <&xin24m>;
579 clock-output-names = "clk_sdio";
583 clk_emmc: clk_emmc_mux {
584 compatible = "rockchip,rk3188-mux-con";
585 rockchip,bits = <12 2>;
586 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>, <&xin24m>;
587 clock-output-names = "clk_emmc";
591 /* reg[15:14]: reserved */
594 clk_sel_con13: sel-con@0078 {
595 compatible = "rockchip,rk3188-selcon";
597 #address-cells = <1>;
600 clk_uart0_div: clk_uart0_div {
601 compatible = "rockchip,rk3188-div-con";
602 rockchip,bits = <0 7>;
603 clocks = <&clk_uart_pll>;
604 clock-output-names = "clk_uart0_div";
605 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
609 /* reg[7]: reserved */
611 clk_uart0: clk_uart0_mux {
612 compatible = "rockchip,rk3188-mux-con";
613 rockchip,bits = <8 2>;
614 clocks = <&clk_uart0_div>, <&uart0_frac>, <&xin24m>;
615 clock-output-names = "clk_uart0";
617 rockchip,clkops-idx =
618 <CLKOPS_RATE_RK3288_I2S>;
619 rockchip,flags = <CLK_SET_RATE_PARENT>;
622 clk_uart_pll: clk_uart_pll_mux {
623 compatible = "rockchip,rk3188-mux-con";
624 rockchip,bits = <10 2>;
625 clocks = <&clk_apll>,<&clk_dpll>, <&clk_gpll>, <&usb_480m>;
626 clock-output-names = "clk_uart_pll";
628 #clock-init-cells = <1>;
631 /* reg[15:12]: reserved */
635 clk_sel_con14: sel-con@007c {
636 compatible = "rockchip,rk3188-selcon";
638 #address-cells = <1>;
641 clk_uart1_div: clk_uart1_div {
642 compatible = "rockchip,rk3188-div-con";
643 rockchip,bits = <0 7>;
644 clocks = <&clk_uart_pll>;
645 clock-output-names = "clk_uart1_div";
646 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
650 /* reg[7]: reserved */
652 clk_uart1: clk_uart1_mux {
653 compatible = "rockchip,rk3188-mux-con";
654 rockchip,bits = <8 2>;
655 clocks = <&clk_uart1_div>, <&uart1_frac>, <&xin24m>;
656 clock-output-names = "clk_uart1";
658 rockchip,clkops-idx =
659 <CLKOPS_RATE_RK3288_I2S>;
660 rockchip,flags = <CLK_SET_RATE_PARENT>;
663 /* reg[15:10]: reserved */
666 clk_sel_con15: sel-con@0080 {
667 compatible = "rockchip,rk3188-selcon";
669 #address-cells = <1>;
672 clk_uart2_div: clk_uart2_div {
673 compatible = "rockchip,rk3188-div-con";
674 rockchip,bits = <0 7>;
675 clocks = <&clk_uart_pll>;
676 clock-output-names = "clk_uart2_div";
677 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
681 /* reg[7]: reserved */
683 clk_uart2: clk_uart2_mux {
684 compatible = "rockchip,rk3188-mux-con";
685 rockchip,bits = <8 2>;
686 clocks = <&clk_uart2_div>, <&uart2_frac>, <&xin24m>;
687 clock-output-names = "clk_uart2";
689 rockchip,clkops-idx =
690 <CLKOPS_RATE_RK3288_I2S>;
691 rockchip,flags = <CLK_SET_RATE_PARENT>;
694 /* reg[15:10]: reserved */
697 clk_sel_con16: sel-con@0084 {
698 compatible = "rockchip,rk3188-selcon";
700 #address-cells = <1>;
703 clk_sfc: clk_sfc_mux {
704 compatible = "rockchip,rk3188-mux-con";
705 rockchip,bits = <0 2>;
706 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>, <&xin24m>;
707 clock-output-names = "clk_sfc";
711 clk_sfc_div: clk_sfc_div {
712 compatible = "rockchip,rk3188-div-con";
713 rockchip,bits = <2 5>;
715 clock-output-names = "clk_sfc";
716 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
718 rockchip,clkops-idx =
719 <CLKOPS_RATE_MUX_DIV>;
722 /* reg[7]: reserved */
724 clk_nandc: clk_nandc_mux {
725 compatible = "rockchip,rk3188-mux-con";
726 rockchip,bits = <8 2>;
727 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
728 clock-output-names = "clk_nandc";
732 clk_nandc_div: clk_nandc_div {
733 compatible = "rockchip,rk3188-div-con";
734 rockchip,bits = <10 5>;
735 clocks = <&clk_nandc>;
736 clock-output-names = "clk_nandc";
737 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
739 rockchip,clkops-idx =
740 <CLKOPS_RATE_MUX_DIV>;
743 /* reg[31:15]: reserved */
746 clk_sel_con17: sel-con@0088 {
747 compatible = "rockchip,rk3188-selcon";
749 #address-cells = <1>;
752 uart0_frac: uart0_frac {
753 compatible = "rockchip,rk3188-frac-con";
754 clocks = <&clk_uart0_div>;
755 clock-output-names = "uart0_frac";
756 /* numerator denominator */
757 rockchip,bits = <0 32>;
758 rockchip,clkops-idx =
764 clk_sel_con18: sel-con@008c {
765 compatible = "rockchip,rk3188-selcon";
767 #address-cells = <1>;
770 uart1_frac: uart1_frac {
771 compatible = "rockchip,rk3188-frac-con";
772 clocks = <&clk_uart1_div>;
773 clock-output-names = "uart1_frac";
774 /* numerator denominator */
775 rockchip,bits = <0 32>;
776 rockchip,clkops-idx =
782 clk_sel_con19: sel-con@0090 {
783 compatible = "rockchip,rk3188-selcon";
785 #address-cells = <1>;
788 uart2_frac: uart2_frac {
789 compatible = "rockchip,rk3188-frac-con";
790 clocks = <&clk_uart2_div>;
791 clock-output-names = "uart2_frac";
792 /* numerator denominator */
793 rockchip,bits = <0 32>;
794 rockchip,clkops-idx =
801 clk_sel_con20: sel-con@0094 {
802 compatible = "rockchip,rk3188-selcon";
804 #address-cells = <1>;
807 clk_hevc_core: clk_hevc_core_mux {
808 compatible = "rockchip,rk3188-mux-con";
809 rockchip,bits = <0 2>;
810 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
811 clock-output-names = "clk_hevc_core";
813 #clock-init-cells = <1>;
816 clk_hevc_core_div: clk_hevc_core_div {
817 compatible = "rockchip,rk3188-div-con";
818 rockchip,bits = <2 5>;
819 clocks = <&clk_hevc_core>;
820 clock-output-names = "clk_hevc_core";
821 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
823 rockchip,clkops-idx =
824 <CLKOPS_RATE_MUX_DIV>;
825 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
828 /* reg[31:7]: reserved */
832 clk_sel_con21: sel-con@0098 {
833 compatible = "rockchip,rk3188-selcon";
835 #address-cells = <1>;
838 clk_mac_pll: clk_mac_pll_mux {
839 compatible = "rockchip,rk3188-mux-con";
840 rockchip,bits = <0 2>;
841 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
842 clock-output-names = "clk_mac_pll";
844 #clock-init-cells = <1>;
847 /* reg[2]: reserved */
849 clk_mac_ref: clk_mac_ref_mux {
850 compatible = "rockchip,rk3188-mux-con";
851 rockchip,bits = <3 1>;
852 clocks = <&clk_mac_pll_div>, <&rmii_clkin>;
853 clock-output-names = "clk_mac_ref";
855 rockchip,clkops-idx =
856 <CLKOPS_RATE_MAC_REF>;
857 rockchip,flags = <CLK_SET_RATE_PARENT>;
858 #clock-init-cells = <1>;
861 clk_mac_pll_div: clk_mac_pll_div {
862 compatible = "rockchip,rk3188-div-con";
863 rockchip,bits = <4 5>;
864 clocks = <&clk_mac_pll>;
865 clock-output-names = "clk_mac_pll";
866 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
868 rockchip,clkops-idx =
869 <CLKOPS_RATE_MUX_DIV>;
872 clk_mac_ref_div: clk_mac_ref_div {
873 compatible = "rockchip,rk3188-div-con";
874 rockchip,bits = <9 5>;
875 clocks = <&clk_mac_ref>;
876 clock-output-names = "clk_mac";
877 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
879 #clock-init-cells = <1>;
882 /* reg[15:14]: reserved */
885 clk_sel_con25: sel-con@00a8 {
886 compatible = "rockchip,rk3188-selcon";
888 #address-cells = <1>;
891 clk_spi0_div: clk_spi0_div {
892 compatible = "rockchip,rk3188-div-con";
893 rockchip,bits = <0 7>;
894 clocks = <&clk_spi0>;
895 clock-output-names = "clk_spi0";
896 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
898 rockchip,clkops-idx =
899 <CLKOPS_RATE_MUX_DIV>;
902 /* reg[7]: reserved */
904 clk_spi0: clk_spi0_mux {
905 compatible = "rockchip,rk3188-mux-con";
906 rockchip,bits = <8 2>;
907 clocks = <&clk_apll>, <&clk_dpll>,<&clk_gpll>;
908 clock-output-names = "clk_spi0";
912 /* reg[15:10]: reserved */
916 clk_sel_con26: sel-con@00ac {
917 compatible = "rockchip,rk3188-selcon";
919 #address-cells = <1>;
923 compatible = "rockchip,rk3188-div-con";
924 rockchip,bits = <0 2>;
926 clock-output-names = "clk_ddr";
927 rockchip,div-type = <CLK_DIVIDER_USER_DEFINE>;
928 rockchip,div-relations =
933 rockchip,flags = <(CLK_GET_RATE_NOCACHE |
934 CLK_SET_RATE_NO_REPARENT)>;
935 rockchip,clkops-idx = <CLKOPS_RATE_DDR>;
938 /* reg[7:1]: reserved */
940 clk_ddr: ddr_clk_pll_mux {
941 compatible = "rockchip,rk3188-mux-con";
942 rockchip,bits = <8 1>;
943 clocks = <&clk_dpll>, <&dummy>;
944 clock-output-names = "clk_ddr";
948 /* reg[15:9]: reserved */
951 clk_sel_con28: sel-con@00b4 {
952 compatible = "rockchip,rk3188-selcon";
954 #address-cells = <1>;
957 dclk_lcdc1: dclk_lcdc1_mux {
958 compatible = "rockchip,rk3188-mux-con";
959 rockchip,bits = <0 2>;
960 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
961 clock-output-names = "dclk_lcdc1";
963 #clock-init-cells = <1>;
966 /* reg[7:2]: reserved */
968 dclk_lcdc1_div: dclk_lcdc1_div {
969 compatible = "rockchip,rk3188-div-con";
970 rockchip,bits = <8 8>;
971 clocks = <&dclk_lcdc1>;
972 clock-output-names = "dclk_lcdc1";
973 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
975 rockchip,clkops-idx =
976 <CLKOPS_RATE_MUX_DIV>;
977 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
981 clk_sel_con30: sel-con@00bc {
982 compatible = "rockchip,rk3188-selcon";
984 #address-cells = <1>;
987 clk_testout_div: clk_testout_div {
988 compatible = "rockchip,rk3188-div-con";
989 rockchip,bits = <0 5>;
991 clock-output-names = "clk_testout";
992 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
994 #clock-init-cells = <1>;
997 /* reg[7:5]: reserved */
999 hclk_vio_pre_div: hclk_vio_pre_div {
1000 compatible = "rockchip,rk3188-div-con";
1001 rockchip,bits = <8 5>;
1002 clocks = <&hclk_vio_pre>;
1003 clock-output-names = "hclk_vio_pre";
1004 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
1006 rockchip,clkops-idx =
1007 <CLKOPS_RATE_MUX_DIV>;
1008 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
1011 /* reg[13]: reserved */
1013 hclk_vio_pre: hclk_vio_pre_mux {
1014 compatible = "rockchip,rk3188-mux-con";
1015 rockchip,bits = <14 2>;
1016 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
1017 clock-output-names = "hclk_vio_pre";
1019 #clock-init-cells = <1>;
1024 clk_sel_con31: sel-con@00c0 {
1025 compatible = "rockchip,rk3188-selcon";
1027 #address-cells = <1>;
1030 clk_hdmi: clk_hdmi_mux {
1031 compatible = "rockchip,rk3188-mux-con";
1032 rockchip,bits = <0 1>;
1033 clocks = <&dclk_lcdc1_div>, <&dummy>;
1034 clock-output-names = "clk_hdmi";
1038 /* reg[7:1]: reserved */
1040 aclk_vio_pre_div: aclk_vio_pre_div {
1041 compatible = "rockchip,rk3188-div-con";
1042 rockchip,bits = <8 5>;
1043 clocks = <&aclk_vio_pre>;
1044 clock-output-names = "aclk_vio_pre";
1045 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
1047 rockchip,clkops-idx =
1048 <CLKOPS_RATE_MUX_DIV>;
1049 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
1052 /* reg[13]: reserved */
1054 aclk_vio_pre: aclk_vio_pre_mux {
1055 compatible = "rockchip,rk3188-mux-con";
1056 rockchip,bits = <14 2>;
1057 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
1058 clock-output-names = "aclk_vio_pre";
1060 #clock-init-cells = <1>;
1065 clk_sel_con32: sel-con@00c4 {
1066 compatible = "rockchip,rk3188-selcon";
1068 #address-cells = <1>;
1071 /* reg[7:0]: reserved */
1073 aclk_vcodec_pre_div: aclk_vcodec_pre_div {
1074 compatible = "rockchip,rk3188-div-con";
1075 rockchip,bits = <8 5>;
1076 clocks = <&aclk_vcodec_pre>;
1077 clock-output-names = "aclk_vcodec_pre";
1078 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
1080 rockchip,clkops-idx =
1081 <CLKOPS_RATE_MUX_DIV>;
1082 rockchip,flags = <CLK_SET_RATE_NO_REPARENT>;
1085 /* reg[13]: reserved */
1087 aclk_vcodec_pre: aclk_vcodec_pre_mux {
1088 compatible = "rockchip,rk3188-mux-con";
1089 rockchip,bits = <14 2>;
1090 clocks = <&clk_apll>, <&clk_dpll>, <&clk_gpll>;
1091 clock-output-names = "aclk_vcodec_pre";
1093 #clock-init-cells = <1>;
1097 clk_sel_con34: sel-con@00cc {
1098 compatible = "rockchip,rk3188-selcon";
1100 #address-cells = <1>;
1103 clk_gpu_pre_div: clk_gpu_pre_div {
1104 compatible = "rockchip,rk3188-div-con";
1105 rockchip,bits = <0 5>;
1106 clocks = <&clk_gpu_pre>;
1107 clock-output-names = "clk_gpu_pre";
1108 rockchip,div-type = <CLK_DIVIDER_PLUS_ONE>;
1110 rockchip,clkops-idx =
1111 <CLKOPS_RATE_MUX_DIV>;
1112 rockchip,flags = <CLK_SET_RATE_PARENT_IN_ORDER>;
1115 /* reg[7:5]: reserved */
1117 clk_gpu_pre: clk_gpu_pre_mux {
1118 compatible = "rockchip,rk3188-mux-con";
1119 rockchip,bits = <8 2>;
1120 clocks = <&dummy>, <&dummy>, <&clk_gpll>;
1121 clock-output-names = "clk_gpu_pre";
1123 #clock-init-cells = <1>;
1126 /* reg[15:10]: reserved */
1133 /* Gate control regs */
1135 compatible = "rockchip,rk-gate-cons";
1136 #address-cells = <1>;
1140 clk_gates0: gate-clk@00d0{
1141 compatible = "rockchip,rk3188-gate-clk";
1144 <&clk_core>, <&clk_gpll>,
1145 <&clk_dpll>, <&aclk_cpu_pre>,
1147 <&aclk_cpu_pre>, <&aclk_cpu_pre>,
1148 <&clk_gpll>, <&clk_core>,
1150 <&clk_gpll>, <&clk_i2s_pll>,
1151 <&i2s_frac>, <&hclk_vio_pre>,
1153 <&dummy>, <&clk_i2s_out>,
1154 <&clk_i2s>, <&dummy>;
1156 clock-output-names =
1157 "pclk_dbg", "reserved", /* do not use bit1 = "cpu_gpll" */
1158 "reserved", "aclk_cpu_pre",
1160 "hclk_cpu_pre", "pclk_cpu_pre",
1161 "reserved", "aclk_core_pre",
1163 "reserved", "clk_i2s_pll",
1164 "i2s_frac", "hclk_vio_pre",
1166 "clk_cryto", "clk_i2s_out",
1167 "clk_i2s", "clk_testout";
1168 rockchip,suspend-clkgating-setting=<0x0 0x0>;
1173 clk_gates1: gate-clk@00d4{
1174 compatible = "rockchip,rk3188-gate-clk";
1177 <&clk_timer0>, <&clk_timer1>,
1178 <&dummy>, <&jtag_tck>,
1180 <&aclk_vio_pre>, <&xin12m>,
1183 <&clk_uart0_div>, <&uart0_frac>,
1184 <&clk_uart1_div>, <&uart1_frac>,
1186 <&clk_uart2_div>, <&uart2_frac>,
1189 clock-output-names =
1190 "clk_timer0", "clk_timer1",
1191 "reserved", "clk_jatg",
1193 "aclk_vio_pre", "clk_otgphy0",
1194 "clk_otgphy1", "reserved",
1196 "clk_uart0_div", "uart0_frac",
1197 "clk_uart1_div", "uart1_frac",
1199 "clk_uart2_div", "uart2_frac",
1200 "reserved", "reserved";
1202 rockchip,suspend-clkgating-setting=<0x0 0x0>;
1206 clk_gates2: gate-clk@00d8 {
1207 compatible = "rockchip,rk3188-gate-clk";
1210 <&aclk_peri_pre>, <&aclk_peri_pre>,
1211 <&aclk_peri_pre>, <&aclk_peri_pre>,
1213 <&clk_timer2>, <&clk_timer3>,
1214 <&clk_mac_ref>, <&dummy>,
1216 <&dummy>, <&clk_spi0>,
1217 <&clk_spdif_pll>, <&clk_sdmmc0>,
1219 <&spdif_frac>, <&clk_sdio>,
1220 <&clk_emmc>, <&dummy>;
1222 clock-output-names =
1223 "aclk_peri", "aclk_peri_pre",
1224 "hclk_peri_pre", "pclk_peri_pre",
1226 "clk_timer2", "clk_timer3",
1227 "clk_mac", "reserved",
1229 "reserved", "clk_spi0",
1230 "clk_spdif_pll", "clk_sdmmc0",
1232 "spdif_frac", "clk_sdio",
1233 "clk_emmc", "reserved";
1234 rockchip,suspend-clkgating-setting=<0x0 0x0>;
1239 clk_gates3: gate-clk@00dc {
1240 compatible = "rockchip,rk3188-gate-clk";
1244 <&dclk_lcdc1>, <&dummy>,
1249 <&pclk_cpu_pre>, <&dummy>,
1250 <&dummy>, <&aclk_vcodec_pre>,
1252 <&aclk_vcodec_pre>, <&clk_gpu_pre>,
1253 <&hclk_peri_pre>, <&dummy>;
1255 clock-output-names =
1256 "reserved", "reserved",
1257 "dclk_lcdc1", "reserved",
1259 "reserved", "reserved",
1260 "reserved", "reserved",
1262 "g_pclk_hdmi", "reserved",
1263 "reserved", "aclk_vcodec_pre",
1265 "hclk_vcodec", "clk_gpu_pre",
1266 "g_hclk_sfc", "reserved";
1267 rockchip,suspend-clkgating-setting=<0x0000 0x0000>;
1272 clk_gates4: gate-clk@00e0{
1273 compatible = "rockchip,rk3188-gate-clk";
1276 <&hclk_peri_pre>, <&pclk_peri_pre>,
1277 <&aclk_peri_pre>, <&aclk_peri_pre>,
1283 <&aclk_cpu_pre>, <&dummy>,
1285 <&aclk_cpu_pre>, <&dummy>,
1288 clock-output-names =
1289 "g_hp_axi_matrix", "g_pp_axi_matrix",
1290 "g_aclk_cpu_peri", "g_ap_axi_matrix",
1292 "reserved", "reserved",
1293 "reserved", "reserved",
1295 "reserved", "reserved",
1296 "g_aclk_strc_sys", "reserved",
1298 /* Not use these ddr gates */
1299 "g_aclk_intmem", "reserved",
1300 "reserved", "reserved";
1302 rockchip,suspend-clkgating-setting = <0x0000 0x0000>;
1306 clk_gates5: gate-clk@00e4 {
1307 compatible = "rockchip,rk3188-gate-clk";
1310 <&dummy>, <&aclk_peri_pre>,
1311 <&pclk_peri_pre>, <&dummy>,
1313 <&pclk_cpu_pre>, <&dummy>,
1314 <&hclk_cpu_pre>, <&pclk_cpu_pre>,
1316 <&dummy>, <&hclk_peri_pre>,
1317 <&hclk_peri_pre>, <&hclk_peri_pre>,
1319 <&dummy>, <&hclk_peri_pre>,
1320 <&pclk_cpu_pre>, <&dummy>;
1322 clock-output-names =
1323 "reserved", "g_aclk_dmac2",
1324 "g_pclk_efuse", "reserved",
1326 "g_pclk_grf", "reserved",
1327 "g_hclk_rom", "g_pclk_ddrupctl",
1329 "reserved", "g_hclk_nandc",
1330 "g_hclk_sdmmc0", "g_hclk_sdio",
1332 "reserved", "g_hclk_otg0",
1333 "g_pclk_acodec", "reserved";
1335 rockchip,suspend-clkgating-setting = <0x0000 0x0000>;
1340 clk_gates6: gate-clk@00e8 {
1341 compatible = "rockchip,rk3188-gate-clk";
1353 <&hclk_vio_pre>, <&aclk_vio_pre>,
1356 clock-output-names =
1357 "reserved", "reserved",
1358 "reserved", "reserved",
1360 "reserved", "reserved",
1361 "reserved", "reserved",
1363 "reserved", "reserved",
1364 "reserved", "reserved",
1366 "g_hclk_vio_bus", "g_aclk_vio",
1367 "reserved", "reserved";
1369 rockchip,suspend-clkgating-setting = <0x0000 0x0000>;
1374 clk_gates7: gate-clk@00ec {
1375 compatible = "rockchip,rk3188-gate-clk";
1378 <&hclk_peri_pre>, <&dummy>,
1379 <&hclk_peri_pre>, <&hclk_peri_pre>,
1382 <&dummy>, <&pclk_peri_pre>,
1385 <&pclk_peri_pre>, <&dummy>,
1387 <&pclk_peri_pre>, <&dummy>,
1388 <&dummy>, <&pclk_peri_pre>;
1390 clock-output-names =
1391 "g_hclk_emmc", "reserved",
1392 "g_hclk_i2s", "g_hclk_otg1",
1394 "reserved", "reserved",
1395 "reserved", "g_pclk_timer0",
1397 "reserved", "reserved",
1398 "g_pclk_pwm", "reserved",
1400 "g_pclk_spi", "reserved",
1401 "reserved", "g_pclk_wdt";
1403 rockchip,suspend-clkgating-setting = <0x0000 0x0000>;
1408 clk_gates8: gate-clk@00f0 {
1409 compatible = "rockchip,rk3188-gate-clk";
1412 <&pclk_peri_pre>, <&pclk_peri_pre>,
1413 <&pclk_peri_pre>, <&dummy>,
1415 <&pclk_peri_pre>, <&pclk_peri_pre>,
1416 <&pclk_peri_pre>, <&dummy>,
1418 <&dummy>, <&pclk_peri_pre>,
1419 <&pclk_peri_pre>, <&pclk_peri_pre>,
1424 clock-output-names =
1425 "g_pclk_uart0", "g_pclk_uart1",
1426 "g_pclk_uart2", "reserved",
1428 "g_pclk_i2c0", "g_pclk_i2c1",
1429 "g_pclk_i2c2", "reserved",
1431 "reserved", "g_pclk_gpio0",
1432 "g_pclk_gpio1", "g_pclk_gpio2",
1434 "reserved", "reserved",
1435 "reserved", "reserved";
1437 rockchip,suspend-clkgating-setting=<0x0000 0x0000>;
1441 clk_gates9: gate-clk@00f4 {
1442 compatible = "rockchip,rk3188-gate-clk";
1448 <&dummy>, <&hclk_vio_pre>,
1449 <&aclk_vio_pre>, <&dummy>,
1454 <&dummy>, <&hclk_peri_pre>,
1455 <&hclk_peri_pre>, <&aclk_peri_pre>;
1457 clock-output-names =
1458 "reserved", "reserved",
1459 "reserved", "reserved",
1461 "reserved", "g_hclk_lcdc",
1462 "g_aclk_lcdc", "reserved",
1464 "reserved", "reserved",
1465 "reserved", "reserved",
1467 "reserved", "g_hclk_usb_peri",
1468 "g_hclk_pe_arbi", "g_aclk_peri_niu";
1470 rockchip,suspend-clkgating-setting=<0x0 0x0>;
1475 clk_gates10: gate-clk@00f8 {
1476 compatible = "rockchip,rk3188-gate-clk";
1479 <&xin24m>, <&xin24m>,
1480 <&xin24m>, <&dummy>,
1482 <&clk_nandc>, <&clk_sfc>,
1483 <&clk_hevc_core>, <&dummy>,
1485 <&clk_dpll>, <&dummy>,
1491 clock-output-names =
1492 "g_clk_pvtm_core", "g_clk_pvtm_gpu",
1493 "g_pvtm_video", "reserved",
1495 "clk_nandc", "clk_sfc",
1496 "clk_hevc_core", "reserved",
1498 "reserved", "reserved",
1499 "reserved", "reserved",
1501 "reserved", "reserved",
1502 "reserved", "reserved";
1504 rockchip,suspend-clkgating-setting = <0x0 0x0>; /* pwm logic vol */