Merge branch 'linux-linaro-lsk-v4.4-android' of git://git.linaro.org/kernel/linux...
[firefly-linux-kernel-4.4.55.git] / arch / arm64 / boot / dts / rockchip / rk3399.dtsi
1 /*
2  * Copyright (c) 2016 Fuzhou Rockchip Electronics Co., Ltd
3  *
4  * This file is dual-licensed: you can use it either under the terms
5  * of the GPL or the X11 license, at your option. Note that this dual
6  * licensing only applies to this file, and not this project as a
7  * whole.
8  *
9  *  a) This library is free software; you can redistribute it and/or
10  *     modify it under the terms of the GNU General Public License as
11  *     published by the Free Software Foundation; either version 2 of the
12  *     License, or (at your option) any later version.
13  *
14  *     This library is distributed in the hope that it will be useful,
15  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
16  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  *     GNU General Public License for more details.
18  *
19  * Or, alternatively,
20  *
21  *  b) Permission is hereby granted, free of charge, to any person
22  *     obtaining a copy of this software and associated documentation
23  *     files (the "Software"), to deal in the Software without
24  *     restriction, including without limitation the rights to use,
25  *     copy, modify, merge, publish, distribute, sublicense, and/or
26  *     sell copies of the Software, and to permit persons to whom the
27  *     Software is furnished to do so, subject to the following
28  *     conditions:
29  *
30  *     The above copyright notice and this permission notice shall be
31  *     included in all copies or substantial portions of the Software.
32  *
33  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
34  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
35  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
36  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
37  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
38  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
39  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
40  *     OTHER DEALINGS IN THE SOFTWARE.
41  */
42
43 #include <dt-bindings/clock/rk3399-cru.h>
44 #include <dt-bindings/gpio/gpio.h>
45 #include <dt-bindings/interrupt-controller/arm-gic.h>
46 #include <dt-bindings/interrupt-controller/irq.h>
47 #include <dt-bindings/pinctrl/rockchip.h>
48 #include <dt-bindings/power/rk3399-power.h>
49 #include <dt-bindings/thermal/thermal.h>
50
51 / {
52         compatible = "rockchip,rk3399";
53         interrupt-parent = <&gic>;
54         #address-cells = <2>;
55         #size-cells = <2>;
56
57         aliases {
58                 i2c0 = &i2c0;
59                 i2c1 = &i2c1;
60                 i2c2 = &i2c2;
61                 i2c3 = &i2c3;
62                 i2c4 = &i2c4;
63                 i2c5 = &i2c5;
64                 i2c6 = &i2c6;
65                 i2c7 = &i2c7;
66                 i2c8 = &i2c8;
67                 serial0 = &uart0;
68                 serial1 = &uart1;
69                 serial2 = &uart2;
70                 serial3 = &uart3;
71                 serial4 = &uart4;
72         };
73
74         psci {
75                 compatible = "arm,psci-1.0";
76                 method = "smc";
77         };
78
79         cpus {
80                 #address-cells = <2>;
81                 #size-cells = <0>;
82
83                 cpu-map {
84                         cluster0 {
85                                 core0 {
86                                         cpu = <&cpu_l0>;
87                                 };
88                                 core1 {
89                                         cpu = <&cpu_l1>;
90                                 };
91                                 core2 {
92                                         cpu = <&cpu_l2>;
93                                 };
94                                 core3 {
95                                         cpu = <&cpu_l3>;
96                                 };
97                         };
98
99                         cluster1 {
100                                 core0 {
101                                         cpu = <&cpu_b0>;
102                                 };
103                                 core1 {
104                                         cpu = <&cpu_b1>;
105                                 };
106                         };
107                 };
108
109                 cpu_l0: cpu@0 {
110                         device_type = "cpu";
111                         compatible = "arm,cortex-a53", "arm,armv8";
112                         reg = <0x0 0x0>;
113                         enable-method = "psci";
114                         #cooling-cells = <2>; /* min followed by max */
115                         clocks = <&cru ARMCLKL>;
116                         operating-points-v2 = <&cluster0_opp>;
117                 };
118
119                 cpu_l1: cpu@1 {
120                         device_type = "cpu";
121                         compatible = "arm,cortex-a53", "arm,armv8";
122                         reg = <0x0 0x1>;
123                         enable-method = "psci";
124                         clocks = <&cru ARMCLKL>;
125                         operating-points-v2 = <&cluster0_opp>;
126                 };
127
128                 cpu_l2: cpu@2 {
129                         device_type = "cpu";
130                         compatible = "arm,cortex-a53", "arm,armv8";
131                         reg = <0x0 0x2>;
132                         enable-method = "psci";
133                         clocks = <&cru ARMCLKL>;
134                         operating-points-v2 = <&cluster0_opp>;
135                 };
136
137                 cpu_l3: cpu@3 {
138                         device_type = "cpu";
139                         compatible = "arm,cortex-a53", "arm,armv8";
140                         reg = <0x0 0x3>;
141                         enable-method = "psci";
142                         clocks = <&cru ARMCLKL>;
143                         operating-points-v2 = <&cluster0_opp>;
144                 };
145
146                 cpu_b0: cpu@100 {
147                         device_type = "cpu";
148                         compatible = "arm,cortex-a72", "arm,armv8";
149                         reg = <0x0 0x100>;
150                         enable-method = "psci";
151                         #cooling-cells = <2>; /* min followed by max */
152                         clocks = <&cru ARMCLKB>;
153                         operating-points-v2 = <&cluster1_opp>;
154                 };
155
156                 cpu_b1: cpu@101 {
157                         device_type = "cpu";
158                         compatible = "arm,cortex-a72", "arm,armv8";
159                         reg = <0x0 0x101>;
160                         enable-method = "psci";
161                         clocks = <&cru ARMCLKB>;
162                         operating-points-v2 = <&cluster1_opp>;
163                 };
164         };
165
166         cluster0_opp: opp_table0 {
167                 compatible = "operating-points-v2";
168                 opp-shared;
169
170                 opp00 {
171                         opp-hz = /bits/ 64 <408000000>;
172                         opp-microvolt = <1000000>;
173                         clock-latency-ns = <40000>;
174                 };
175                 opp01 {
176                         opp-hz = /bits/ 64 <600000000>;
177                         opp-microvolt = <1000000>;
178                 };
179                 opp02 {
180                         opp-hz = /bits/ 64 <816000000>;
181                         opp-microvolt = <1000000>;
182                 };
183                 opp03 {
184                         opp-hz = /bits/ 64 <1008000000>;
185                         opp-microvolt = <1000000>;
186                 };
187         };
188
189         cluster1_opp: opp_table1 {
190                 compatible = "operating-points-v2";
191                 opp-shared;
192
193                 opp00 {
194                         opp-hz = /bits/ 64 <408000000>;
195                         opp-microvolt = <1000000>;
196                         clock-latency-ns = <40000>;
197                 };
198                 opp01 {
199                         opp-hz = /bits/ 64 <600000000>;
200                         opp-microvolt = <1000000>;
201                 };
202                 opp02 {
203                         opp-hz = /bits/ 64 <816000000>;
204                         opp-microvolt = <1000000>;
205                 };
206                 opp03 {
207                         opp-hz = /bits/ 64 <1008000000>;
208                         opp-microvolt = <1000000>;
209                 };
210                 opp04 {
211                         opp-hz = /bits/ 64 <1200000000>;
212                         opp-microvolt = <1000000>;
213                 };
214         };
215
216         timer {
217                 compatible = "arm,armv8-timer";
218                 interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_LOW>,
219                              <GIC_PPI 14 IRQ_TYPE_LEVEL_LOW>,
220                              <GIC_PPI 11 IRQ_TYPE_LEVEL_LOW>,
221                              <GIC_PPI 10 IRQ_TYPE_LEVEL_LOW>;
222         };
223
224         pmu_a53 {
225                 compatible = "arm,cortex-a53-pmu";
226                 interrupts = <GIC_PPI 7 IRQ_TYPE_LEVEL_LOW>;
227                 interrupt-affinity = <&cpu_l0>,
228                                      <&cpu_l1>,
229                                      <&cpu_l2>,
230                                      <&cpu_l3>;
231         };
232
233         pmu_a72 {
234                 compatible = "arm,cortex-a72-pmu", "arm,cortex-a57-pmu";
235                 interrupts = <GIC_PPI 7 IRQ_TYPE_LEVEL_LOW>;
236                 interrupt-affinity = <&cpu_b0>,
237                                      <&cpu_b1>;
238         };
239
240         xin24m: xin24m {
241                 compatible = "fixed-clock";
242                 #clock-cells = <0>;
243                 clock-frequency = <24000000>;
244                 clock-output-names = "xin24m";
245         };
246
247         amba {
248                 compatible = "arm,amba-bus";
249                 #address-cells = <2>;
250                 #size-cells = <2>;
251                 ranges;
252
253                 dmac_bus: dma-controller@ff6d0000 {
254                         compatible = "arm,pl330", "arm,primecell";
255                         reg = <0x0 0xff6d0000 0x0 0x4000>;
256                         interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>,
257                                      <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
258                         #dma-cells = <1>;
259                         clocks = <&cru ACLK_DMAC0_PERILP>;
260                         clock-names = "apb_pclk";
261                 };
262
263                 dmac_peri: dma-controller@ff6e0000 {
264                         compatible = "arm,pl330", "arm,primecell";
265                         reg = <0x0 0xff6e0000 0x0 0x4000>;
266                         interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>,
267                                      <GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>;
268                         #dma-cells = <1>;
269                         clocks = <&cru ACLK_DMAC1_PERILP>;
270                         clock-names = "apb_pclk";
271                 };
272         };
273
274         gmac: eth@fe300000 {
275                 compatible = "rockchip,rk3399-gmac";
276                 reg = <0x0 0xfe300000 0x0 0x10000>;
277                 rockchip,grf = <&grf>;
278                 interrupts = <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>;
279                 interrupt-names = "macirq";
280                 clocks = <&cru SCLK_MAC>, <&cru SCLK_MAC_RX>,
281                          <&cru SCLK_MAC_TX>, <&cru SCLK_MACREF>,
282                          <&cru SCLK_MACREF_OUT>, <&cru ACLK_GMAC>,
283                          <&cru PCLK_GMAC>;
284                 clock-names = "stmmaceth", "mac_clk_rx",
285                               "mac_clk_tx", "clk_mac_ref",
286                               "clk_mac_refout", "aclk_mac",
287                               "pclk_mac";
288                 resets = <&cru SRST_A_GMAC>;
289                 reset-names = "stmmaceth";
290                 status = "disabled";
291         };
292
293         emmc_phy: phy {
294                 compatible = "rockchip,rk3399-emmc-phy";
295                 reg-offset = <0xf780>;
296                 #phy-cells = <0>;
297                 rockchip,grf = <&grf>;
298                 status = "disabled";
299         };
300
301         sdio0: dwmmc@fe310000 {
302                 compatible = "rockchip,rk3399-dw-mshc", "rockchip,rk3288-dw-mshc";
303                 reg = <0x0 0xfe310000 0x0 0x4000>;
304                 interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>;
305                 clock-freq-min-max = <400000 150000000>;
306                 clocks = <&cru HCLK_SDIO>, <&cru SCLK_SDIO>,
307                          <&cru SCLK_SDIO_DRV>, <&cru SCLK_SDIO_SAMPLE>;
308                 clock-names = "biu", "ciu", "ciu-drive", "ciu-sample";
309                 fifo-depth = <0x100>;
310                 status = "disabled";
311         };
312
313         sdmmc: dwmmc@fe320000 {
314                 compatible = "rockchip,rk3399-dw-mshc", "rockchip,rk3288-dw-mshc";
315                 reg = <0x0 0xfe320000 0x0 0x4000>;
316                 interrupts = <GIC_SPI 65 IRQ_TYPE_LEVEL_HIGH>;
317                 clock-freq-min-max = <400000 150000000>;
318                 clocks = <&cru HCLK_SDMMC>, <&cru SCLK_SDMMC>,
319                          <&cru SCLK_SDMMC_DRV>, <&cru SCLK_SDMMC_SAMPLE>;
320                 clock-names = "biu", "ciu", "ciu-drive", "ciu-sample";
321                 fifo-depth = <0x100>;
322                 status = "disabled";
323         };
324
325         sdhci: sdhci@fe330000 {
326                 compatible = "arasan,sdhci-5.1";
327                 reg = <0x0 0xfe330000 0x0 0x10000>;
328                 interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
329                 clocks = <&cru SCLK_EMMC>, <&cru ACLK_EMMC>;
330                 clock-names = "clk_xin", "clk_ahb";
331                 phys = <&emmc_phy>;
332                 phy-names = "phy_arasan";
333                 status = "disabled";
334         };
335
336         usb_host0_echi: usb@fe380000 {
337                 compatible = "generic-ehci";
338                 reg = <0x0 0xfe380000 0x0 0x20000>;
339                 interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
340                 clocks = <&cru HCLK_HOST0>;
341                 clock-names = "hclk_host0";
342                 status = "disabled";
343         };
344
345         usb_host0_ohci: usb@fe3a0000 {
346                 compatible = "generic-ohci";
347                 reg = <0x0 0xfe3a0000 0x0 0x20000>;
348                 interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
349                 clocks = <&cru HCLK_HOST0>;
350                 clock-names = "hclk_host0";
351                 status = "disabled";
352         };
353
354         usb_host1_echi: usb@fe3c0000 {
355                 compatible = "generic-ehci";
356                 reg = <0x0 0xfe3c0000 0x0 0x20000>;
357                 interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>;
358                 clocks = <&cru HCLK_HOST1>;
359                 clock-names = "hclk_host1";
360                 status = "disabled";
361         };
362
363         usb_host1_ohci: usb@fe3e0000 {
364                 compatible = "generic-ohci";
365                 reg = <0x0 0xfe3e0000 0x0 0x20000>;
366                 interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
367                 clocks = <&cru HCLK_HOST1>;
368                 clock-names = "hclk_host1";
369                 status = "disabled";
370         };
371
372         usbdrd3_0: usb@fe800000 {
373                 compatible = "rockchip,dwc3";
374                 clocks = <&cru SCLK_USB3OTG0_REF>, <&cru SCLK_USB3OTG0_SUSPEND>,
375                          <&cru ACLK_USB3OTG0>, <&cru ACLK_USB3_RKSOC_AXI_PERF>,
376                          <&cru ACLK_USB3>, <&cru ACLK_USB3_NOC>,
377                          <&cru ACLK_USB3_GRF>;
378                 clock-names = "clk_usb3otg0_ref", "clk_usb3otg0_suspend",
379                               "aclk_usb3otg0", "aclk_usb3_rksoc_axi_perf",
380                               "aclk_usb3", "aclk_usb3_noc",
381                               "aclk_usb3_grf";
382                 #address-cells = <2>;
383                 #size-cells = <2>;
384                 ranges;
385                 status = "disabled";
386                 usbdrd_dwc3_0: dwc3 {
387                         compatible = "snps,dwc3";
388                         reg = <0x0 0xfe800000 0x0 0x100000>;
389                         interrupts = <GIC_SPI 105 IRQ_TYPE_LEVEL_HIGH>;
390                         dr_mode = "otg";
391                         tx-fifo-resize;
392                         status = "disabled";
393                 };
394         };
395
396         usbdrd3_1: usb@fe900000 {
397                 compatible = "rockchip,dwc3";
398                 clocks = <&cru SCLK_USB3OTG1_REF>, <&cru SCLK_USB3OTG1_SUSPEND>,
399                          <&cru ACLK_USB3OTG1>, <&cru ACLK_USB3_RKSOC_AXI_PERF>,
400                          <&cru ACLK_USB3>, <&cru ACLK_USB3_NOC>,
401                          <&cru ACLK_USB3_GRF>;
402                 clock-names = "clk_usb3otg1_ref", "clk_usb3otg1_suspend",
403                               "aclk_usb3otg1", "aclk_usb3_rksoc_axi_perf",
404                               "aclk_usb3", "aclk_usb3_noc",
405                               "aclk_usb3_grf";
406                 #address-cells = <2>;
407                 #size-cells = <2>;
408                 ranges;
409                 status = "disabled";
410                 usbdrd_dwc3_1: dwc3 {
411                         compatible = "snps,dwc3";
412                         reg = <0x0 0xfe900000 0x0 0x100000>;
413                         interrupts = <GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH>;
414                         dr_mode = "otg";
415                         tx-fifo-resize;
416                         status = "disabled";
417                 };
418         };
419
420         gic: interrupt-controller@fee00000 {
421                 compatible = "arm,gic-v3";
422                 #interrupt-cells = <3>;
423                 #address-cells = <2>;
424                 #size-cells = <2>;
425                 ranges;
426                 interrupt-controller;
427
428                 reg = <0x0 0xfee00000 0 0x10000>, /* GICD */
429                       <0x0 0xfef00000 0 0xc0000>, /* GICR */
430                       <0x0 0xfff00000 0 0x10000>, /* GICC */
431                       <0x0 0xfff10000 0 0x10000>, /* GICH */
432                       <0x0 0xfff20000 0 0x10000>; /* GICV */
433                 interrupts = <GIC_PPI 9 IRQ_TYPE_LEVEL_HIGH>;
434                 its: interrupt-controller@fee20000 {
435                         compatible = "arm,gic-v3-its";
436                         msi-controller;
437                         reg = <0x0 0xfee20000 0x0 0x20000>;
438                 };
439         };
440
441         saradc: saradc@ff100000 {
442                 compatible = "rockchip,rk3399-saradc";
443                 reg = <0x0 0xff100000 0x0 0x100>;
444                 interrupts = <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>;
445                 #io-channel-cells = <1>;
446                 clocks = <&cru SCLK_SARADC>, <&cru PCLK_SARADC>;
447                 clock-names = "saradc", "apb_pclk";
448                 status = "disabled";
449         };
450
451         i2c0: i2c@ff3c0000 {
452                 compatible = "rockchip,rk3399-i2c";
453                 reg = <0x0 0xff3c0000 0x0 0x1000>;
454                 clocks =  <&pmucru SCLK_I2C0_PMU>, <&pmucru PCLK_I2C0_PMU>;
455                 clock-names = "i2c", "pclk";
456                 interrupts = <GIC_SPI 57 IRQ_TYPE_LEVEL_HIGH>;
457                 pinctrl-names = "default";
458                 pinctrl-0 = <&i2c0_xfer>;
459                 #address-cells = <1>;
460                 #size-cells = <0>;
461                 status = "disabled";
462         };
463
464         i2c1: i2c@ff110000 {
465                 compatible = "rockchip,rk3399-i2c";
466                 reg = <0x0 0xff110000 0x0 0x1000>;
467                 clocks = <&cru SCLK_I2C1>, <&cru PCLK_I2C1>;
468                 clock-names = "i2c", "pclk";
469                 interrupts = <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>;
470                 pinctrl-names = "default";
471                 pinctrl-0 = <&i2c1_xfer>;
472                 #address-cells = <1>;
473                 #size-cells = <0>;
474                 status = "disabled";
475         };
476
477         i2c2: i2c@ff120000 {
478                 compatible = "rockchip,rk3399-i2c";
479                 reg = <0x0 0xff120000 0x0 0x1000>;
480                 clocks = <&cru SCLK_I2C2>, <&cru PCLK_I2C2>;
481                 clock-names = "i2c", "pclk";
482                 interrupts = <GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>;
483                 pinctrl-names = "default";
484                 pinctrl-0 = <&i2c2_xfer>;
485                 #address-cells = <1>;
486                 #size-cells = <0>;
487                 status = "disabled";
488         };
489
490         i2c3: i2c@ff130000 {
491                 compatible = "rockchip,rk3399-i2c";
492                 reg = <0x0 0xff130000 0x0 0x1000>;
493                 clocks = <&cru SCLK_I2C3>, <&cru PCLK_I2C3>;
494                 clock-names = "i2c", "pclk";
495                 interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
496                 pinctrl-names = "default";
497                 pinctrl-0 = <&i2c3_xfer>;
498                 #address-cells = <1>;
499                 #size-cells = <0>;
500                 status = "disabled";
501         };
502
503         i2c5: i2c@ff140000 {
504                 compatible = "rockchip,rk3399-i2c";
505                 reg = <0x0 0xff140000 0x0 0x1000>;
506                 clocks = <&cru SCLK_I2C5>, <&cru PCLK_I2C5>;
507                 clock-names = "i2c", "pclk";
508                 interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>;
509                 pinctrl-names = "default";
510                 pinctrl-0 = <&i2c5_xfer>;
511                 #address-cells = <1>;
512                 #size-cells = <0>;
513                 status = "disabled";
514         };
515
516         i2c6: i2c@ff150000 {
517                 compatible = "rockchip,rk3399-i2c";
518                 reg = <0x0 0xff150000 0x0 0x1000>;
519                 clocks = <&cru SCLK_I2C6>, <&cru PCLK_I2C6>;
520                 clock-names = "i2c", "pclk";
521                 interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
522                 pinctrl-names = "default";
523                 pinctrl-0 = <&i2c6_xfer>;
524                 #address-cells = <1>;
525                 #size-cells = <0>;
526                 status = "disabled";
527         };
528
529         i2c7: i2c@ff160000 {
530                 compatible = "rockchip,rk3399-i2c";
531                 reg = <0x0 0xff160000 0x0 0x1000>;
532                 clocks = <&cru SCLK_I2C7>, <&cru PCLK_I2C7>;
533                 clock-names = "i2c", "pclk";
534                 interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
535                 pinctrl-names = "default";
536                 pinctrl-0 = <&i2c7_xfer>;
537                 #address-cells = <1>;
538                 #size-cells = <0>;
539                 status = "disabled";
540         };
541
542         uart0: serial@ff180000 {
543                 compatible = "rockchip,rk3399-uart", "snps,dw-apb-uart";
544                 reg = <0x0 0xff180000 0x0 0x100>;
545                 clocks = <&cru SCLK_UART0>, <&cru PCLK_UART0>;
546                 clock-names = "baudclk", "apb_pclk";
547                 interrupts = <GIC_SPI 99 IRQ_TYPE_LEVEL_HIGH>;
548                 reg-shift = <2>;
549                 reg-io-width = <4>;
550                 pinctrl-names = "default";
551                 pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
552                 status = "disabled";
553         };
554
555         uart1: serial@ff190000 {
556                 compatible = "rockchip,rk3399-uart", "snps,dw-apb-uart";
557                 reg = <0x0 0xff190000 0x0 0x100>;
558                 clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>;
559                 clock-names = "baudclk", "apb_pclk";
560                 interrupts = <GIC_SPI 98 IRQ_TYPE_LEVEL_HIGH>;
561                 reg-shift = <2>;
562                 reg-io-width = <4>;
563                 pinctrl-names = "default";
564                 pinctrl-0 = <&uart1_xfer>;
565                 status = "disabled";
566         };
567
568         uart2: serial@ff1a0000 {
569                 compatible = "rockchip,rk3399-uart", "snps,dw-apb-uart";
570                 reg = <0x0 0xff1a0000 0x0 0x100>;
571                 clocks = <&cru SCLK_UART2>, <&cru PCLK_UART2>;
572                 clock-names = "baudclk", "apb_pclk";
573                 interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
574                 reg-shift = <2>;
575                 reg-io-width = <4>;
576                 pinctrl-names = "default";
577                 pinctrl-0 = <&uart2c_xfer>;
578                 status = "disabled";
579         };
580
581         uart3: serial@ff1b0000 {
582                 compatible = "rockchip,rk3399-uart", "snps,dw-apb-uart";
583                 reg = <0x0 0xff1b0000 0x0 0x100>;
584                 clocks = <&cru SCLK_UART3>, <&cru PCLK_UART3>;
585                 clock-names = "baudclk", "apb_pclk";
586                 interrupts = <GIC_SPI 101 IRQ_TYPE_LEVEL_HIGH>;
587                 reg-shift = <2>;
588                 reg-io-width = <4>;
589                 pinctrl-names = "default";
590                 pinctrl-0 = <&uart3_xfer &uart3_cts &uart3_rts>;
591                 status = "disabled";
592         };
593
594         spi0: spi@ff1c0000 {
595                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
596                 reg = <0x0 0xff1c0000 0x0 0x1000>;
597                 clocks = <&cru SCLK_SPI0>, <&cru PCLK_SPI0>;
598                 clock-names = "spiclk", "apb_pclk";
599                 interrupts = <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>;
600                 pinctrl-names = "default";
601                 pinctrl-0 = <&spi0_clk &spi0_tx &spi0_rx &spi0_cs0>;
602                 #address-cells = <1>;
603                 #size-cells = <0>;
604                 status = "disabled";
605         };
606
607         spi1: spi@ff1d0000 {
608                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
609                 reg = <0x0 0xff1d0000 0x0 0x1000>;
610                 clocks = <&cru SCLK_SPI1>, <&cru PCLK_SPI1>;
611                 clock-names = "spiclk", "apb_pclk";
612                 interrupts = <GIC_SPI 53 IRQ_TYPE_LEVEL_HIGH>;
613                 pinctrl-names = "default";
614                 pinctrl-0 = <&spi1_clk &spi1_tx &spi1_rx &spi1_cs0>;
615                 #address-cells = <1>;
616                 #size-cells = <0>;
617                 status = "disabled";
618         };
619
620         spi2: spi@ff1e0000 {
621                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
622                 reg = <0x0 0xff1e0000 0x0 0x1000>;
623                 clocks = <&cru SCLK_SPI2>, <&cru PCLK_SPI2>;
624                 clock-names = "spiclk", "apb_pclk";
625                 interrupts = <GIC_SPI 52 IRQ_TYPE_LEVEL_HIGH>;
626                 pinctrl-names = "default";
627                 pinctrl-0 = <&spi2_clk &spi2_tx &spi2_rx &spi2_cs0>;
628                 #address-cells = <1>;
629                 #size-cells = <0>;
630                 status = "disabled";
631         };
632
633         spi4: spi@ff1f0000 {
634                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
635                 reg = <0x0 0xff1f0000 0x0 0x1000>;
636                 clocks = <&cru SCLK_SPI4>, <&cru PCLK_SPI4>;
637                 clock-names = "spiclk", "apb_pclk";
638                 interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>;
639                 pinctrl-names = "default";
640                 pinctrl-0 = <&spi4_clk &spi4_tx &spi4_rx &spi4_cs0>;
641                 #address-cells = <1>;
642                 #size-cells = <0>;
643                 status = "disabled";
644         };
645
646         spi5: spi@ff200000 {
647                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
648                 reg = <0x0 0xff200000 0x0 0x1000>;
649                 clocks = <&cru SCLK_SPI5>, <&cru PCLK_SPI5>;
650                 clock-names = "spiclk", "apb_pclk";
651                 interrupts = <GIC_SPI 132 IRQ_TYPE_LEVEL_HIGH>;
652                 pinctrl-names = "default";
653                 pinctrl-0 = <&spi5_clk &spi5_tx &spi5_rx &spi5_cs0>;
654                 #address-cells = <1>;
655                 #size-cells = <0>;
656                 status = "disabled";
657         };
658
659         thermal-zones {
660                 #include "rk3368-thermal.dtsi"
661         };
662
663         tsadc: tsadc@ff260000 {
664                 compatible = "rockchip,rk3399-tsadc";
665                 reg = <0x0 0xff260000 0x0 0x100>;
666                 interrupts = <GIC_SPI 97 IRQ_TYPE_LEVEL_HIGH>;
667                 clocks = <&cru SCLK_TSADC>, <&cru PCLK_TSADC>;
668                 clock-names = "tsadc", "apb_pclk";
669                 resets = <&cru SRST_TSADC>;
670                 reset-names = "tsadc-apb";
671                 pinctrl-names = "init", "default", "sleep";
672                 pinctrl-0 = <&otp_gpio>;
673                 pinctrl-1 = <&otp_out>;
674                 pinctrl-2 = <&otp_gpio>;
675                 #thermal-sensor-cells = <1>;
676                 rockchip,hw-tshut-temp = <95000>;
677                 status = "disabled";
678         };
679
680         pmu: power-management@ff31000 {
681                 compatible = "rockchip,rk3399-pmu", "syscon", "simple-mfd";
682                 reg = <0x0 0xff310000 0x0 0x1000>;
683
684                 power: power-controller {
685                         status = "disabled";
686                         compatible = "rockchip,rk3399-power-controller";
687                         #power-domain-cells = <1>;
688                         #address-cells = <1>;
689                         #size-cells = <0>;
690
691                         pd_center {
692                                 reg = <RK3399_PD_CENTER>;
693                                 #address-cells = <1>;
694                                 #size-cells = <0>;
695
696                                 pd_vdu {
697                                         reg = <RK3399_PD_VDU>;
698                                 };
699                                 pd_vcodec {
700                                         reg = <RK3399_PD_VCODEC>;
701                                 };
702                                 pd_iep {
703                                         reg = <RK3399_PD_IEP>;
704                                 };
705                                 pd_rga {
706                                         reg = <RK3399_PD_RGA>;
707                                 };
708                         };
709                         pd_vio {
710                                 reg = <RK3399_PD_VIO>;
711                                 #address-cells = <1>;
712                                 #size-cells = <0>;
713
714                                 pd_isp0 {
715                                         reg = <RK3399_PD_ISP0>;
716                                 };
717                                 pd_isp1 {
718                                         reg = <RK3399_PD_ISP1>;
719                                 };
720                                 pd_hdcp {
721                                         reg = <RK3399_PD_HDCP>;
722                                 };
723                                 pd_vo {
724                                         reg = <RK3399_PD_VO>;
725                                         #address-cells = <1>;
726                                         #size-cells = <0>;
727
728                                         pd_vopb {
729                                                 reg = <RK3399_PD_VOPB>;
730                                         };
731                                         pd_vopl {
732                                                 reg = <RK3399_PD_VOPL>;
733                                         };
734                                 };
735                         };
736                         pd_gpu {
737                                 reg = <RK3399_PD_GPU>;
738                         };
739                 };
740         };
741
742         pmugrf: syscon@ff320000 {
743                 compatible = "rockchip,rk3399-pmugrf", "syscon";
744                 reg = <0x0 0xff320000 0x0 0x1000>;
745         };
746
747         spi3: spi@ff350000 {
748                 compatible = "rockchip,rk3399-spi", "rockchip,rk3066-spi";
749                 reg = <0x0 0xff350000 0x0 0x1000>;
750                 clocks = <&pmucru SCLK_SPI3_PMU>, <&pmucru PCLK_SPI3_PMU>;
751                 clock-names = "spiclk", "apb_pclk";
752                 interrupts = <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>;
753                 pinctrl-names = "default";
754                 pinctrl-0 = <&spi3_clk &spi3_tx &spi3_rx &spi3_cs0>;
755                 #address-cells = <1>;
756                 #size-cells = <0>;
757                 status = "disabled";
758         };
759
760         uart4: serial@ff370000 {
761                 compatible = "rockchip,rk3399-uart", "snps,dw-apb-uart";
762                 reg = <0x0 0xff370000 0x0 0x100>;
763                 clocks = <&pmucru SCLK_UART4_PMU>, <&pmucru PCLK_UART4_PMU>;
764                 clock-names = "baudclk", "apb_pclk";
765                 interrupts = <GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>;
766                 reg-shift = <2>;
767                 reg-io-width = <4>;
768                 pinctrl-names = "default";
769                 pinctrl-0 = <&uart4_xfer>;
770                 status = "disabled";
771         };
772
773         i2c4: i2c@ff3d0000 {
774                 compatible = "rockchip,rk3399-i2c";
775                 reg = <0x0 0xff3d0000 0x0 0x1000>;
776                 clocks = <&pmucru SCLK_I2C4_PMU>, <&pmucru PCLK_I2C4_PMU>;
777                 clock-names = "i2c", "pclk";
778                 interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
779                 pinctrl-names = "default";
780                 pinctrl-0 = <&i2c4_xfer>;
781                 #address-cells = <1>;
782                 #size-cells = <0>;
783                 status = "disabled";
784         };
785
786         i2c8: i2c@ff3e0000 {
787                 compatible = "rockchip,rk3399-i2c";
788                 reg = <0x0 0xff3e0000 0x0 0x1000>;
789                 clocks = <&pmucru SCLK_I2C8_PMU>, <&pmucru PCLK_I2C8_PMU>;
790                 clock-names = "i2c", "pclk";
791                 interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>;
792                 pinctrl-names = "default";
793                 pinctrl-0 = <&i2c8_xfer>;
794                 #address-cells = <1>;
795                 #size-cells = <0>;
796                 status = "disabled";
797         };
798
799         pwm0: pwm@ff420000 {
800                 compatible = "rockchip,rk3399-pwm", "rockchip,rk3288-pwm";
801                 reg = <0x0 0xff420000 0x0 0x10>;
802                 #pwm-cells = <3>;
803                 pinctrl-names = "default";
804                 pinctrl-0 = <&pwm0_pin>;
805                 clocks = <&pmucru PCLK_RKPWM_PMU>;
806                 clock-names = "pwm";
807                 status = "disabled";
808         };
809
810         pwm1: pwm@ff420010 {
811                 compatible = "rockchip,rk3399-pwm", "rockchip,rk3288-pwm";
812                 reg = <0x0 0xff420010 0x0 0x10>;
813                 #pwm-cells = <3>;
814                 pinctrl-names = "default";
815                 pinctrl-0 = <&pwm1_pin>;
816                 clocks = <&pmucru PCLK_RKPWM_PMU>;
817                 clock-names = "pwm";
818                 status = "disabled";
819         };
820
821         pwm2: pwm@ff420020 {
822                 compatible = "rockchip,rk3399-pwm", "rockchip,rk3288-pwm";
823                 reg = <0x0 0xff420020 0x0 0x10>;
824                 #pwm-cells = <3>;
825                 pinctrl-names = "default";
826                 pinctrl-0 = <&pwm2_pin>;
827                 clocks = <&pmucru PCLK_RKPWM_PMU>;
828                 clock-names = "pwm";
829                 status = "disabled";
830         };
831
832         pwm3: pwm@ff420030 {
833                 compatible = "rockchip,rk3399-pwm", "rockchip,rk3288-pwm";
834                 reg = <0x0 0xff420030 0x0 0x10>;
835                 #pwm-cells = <3>;
836                 pinctrl-names = "default";
837                 pinctrl-0 = <&pwm3a_pin>;
838                 clocks = <&pmucru PCLK_RKPWM_PMU>;
839                 clock-names = "pwm";
840                 status = "disabled";
841         };
842
843         pmucru: pmu-clock-controller@ff750000 {
844                 compatible = "rockchip,rk3399-pmucru";
845                 reg = <0x0 0xff750000 0x0 0x1000>;
846                 rockchip,grf = <&pmugrf>;
847                 #clock-cells = <1>;
848                 #reset-cells = <1>;
849                 assigned-clocks = <&pmucru PLL_PPLL>;
850                 assigned-clock-rates = <676000000>;
851         };
852
853         cru: clock-controller@ff760000 {
854                 compatible = "rockchip,rk3399-cru";
855                 reg = <0x0 0xff760000 0x0 0x1000>;
856                 rockchip,grf = <&grf>;
857                 #clock-cells = <1>;
858                 #reset-cells = <1>;
859                 assigned-clocks =
860                         <&cru ARMCLKL>, <&cru ARMCLKB>,
861                         <&cru PLL_GPLL>, <&cru PLL_CPLL>,
862                         <&cru PLL_NPLL>,
863                         <&cru ACLK_PERIHP>, <&cru HCLK_PERIHP>,
864                         <&cru PCLK_PERIHP>,
865                         <&cru ACLK_PERILP0>, <&cru HCLK_PERILP0>,
866                         <&cru PCLK_PERILP0>,
867                         <&cru HCLK_PERILP1>, <&cru PCLK_PERILP1>;
868                 assigned-clock-rates =
869                          <816000000>, <1008000000>,
870                          <594000000>,  <800000000>,
871                         <1000000000>,
872                          <150000000>,   <75000000>,
873                           <37500000>,
874                          <100000000>,  <100000000>,
875                           <50000000>,
876                          <100000000>,   <50000000>;
877         };
878
879         grf: syscon@ff770000 {
880                 compatible = "rockchip,rk3399-grf", "syscon";
881                 reg = <0x0 0xff770000 0x0 0x10000>;
882         };
883
884         wdt0: watchdog@ff840000 {
885                 compatible = "snps,dw-wdt";
886                 reg = <0x0 0xff840000 0x0 0x100>;
887                 clocks = <&cru PCLK_WDT>;
888                 interrupts = <GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>;
889                 status = "disabled";
890         };
891
892         spdif: spdif@ff870000 {
893                 compatible = "rockchip,rk3399-spdif";
894                 reg = <0x0 0xff870000 0x0 0x1000>;
895                 interrupts = <GIC_SPI 66 IRQ_TYPE_LEVEL_HIGH>;
896                 dmas = <&dmac_bus 7>;
897                 dma-names = "tx";
898                 clock-names = "hclk", "mclk";
899                 clocks = <&cru HCLK_SPDIF>, <&cru SCLK_SPDIF_8CH>;
900                 pinctrl-names = "default";
901                 pinctrl-0 = <&spdif_bus>;
902                 status = "disabled";
903         };
904
905         i2s0: i2s@ff880000 {
906                 compatible = "rockchip,rk3399-i2s", "rockchip,rk3066-i2s";
907                 reg = <0x0 0xff880000 0x0 0x1000>;
908                 interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>;
909                 #address-cells = <1>;
910                 #size-cells = <0>;
911                 dmas = <&dmac_bus 0>, <&dmac_bus 1>;
912                 dma-names = "tx", "rx";
913                 clock-names = "i2s_hclk", "i2s_clk";
914                 clocks = <&cru HCLK_I2S0_8CH>, <&cru SCLK_I2S0_8CH>;
915                 pinctrl-names = "default";
916                 pinctrl-0 = <&i2s0_8ch_bus>;
917                 status = "disabled";
918         };
919
920         i2s1: i2s@ff890000 {
921                 compatible = "rockchip,rk3399-i2s", "rockchip,rk3066-i2s";
922                 reg = <0x0 0xff890000 0x0 0x1000>;
923                 interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
924                 #address-cells = <1>;
925                 #size-cells = <0>;
926                 dmas = <&dmac_bus 2>, <&dmac_bus 3>;
927                 dma-names = "tx", "rx";
928                 clock-names = "i2s_hclk", "i2s_clk";
929                 clocks = <&cru HCLK_I2S1_8CH>, <&cru SCLK_I2S1_8CH>;
930                 pinctrl-names = "default";
931                 pinctrl-0 = <&i2s1_2ch_bus>;
932                 status = "disabled";
933         };
934
935         i2s2: i2s@ff8a0000 {
936                 compatible = "rockchip,rk3399-i2s", "rockchip,rk3066-i2s";
937                 reg = <0x0 0xff8a0000 0x0 0x1000>;
938                 interrupts = <GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>;
939                 #address-cells = <1>;
940                 #size-cells = <0>;
941                 dmas = <&dmac_bus 4>, <&dmac_bus 5>;
942                 dma-names = "tx", "rx";
943                 clock-names = "i2s_hclk", "i2s_clk";
944                 clocks = <&cru HCLK_I2S2_8CH>, <&cru SCLK_I2S2_8CH>;
945                 status = "disabled";
946         };
947
948         pinctrl: pinctrl {
949                 compatible = "rockchip,rk3399-pinctrl";
950                 rockchip,grf = <&grf>;
951                 rockchip,pmu = <&pmugrf>;
952                 #address-cells = <0x2>;
953                 #size-cells = <0x2>;
954                 ranges;
955
956                 gpio0: gpio0@ff720000 {
957                         compatible = "rockchip,gpio-bank";
958                         reg = <0x0 0xff720000 0x0 0x100>;
959                         clocks = <&pmucru PCLK_GPIO0_PMU>;
960                         interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
961
962                         gpio-controller;
963                         #gpio-cells = <0x2>;
964
965                         interrupt-controller;
966                         #interrupt-cells = <0x2>;
967                 };
968
969                 gpio1: gpio1@ff730000 {
970                         compatible = "rockchip,gpio-bank";
971                         reg = <0x0 0xff730000 0x0 0x100>;
972                         clocks = <&pmucru PCLK_GPIO1_PMU>;
973                         interrupts = <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>;
974
975                         gpio-controller;
976                         #gpio-cells = <0x2>;
977
978                         interrupt-controller;
979                         #interrupt-cells = <0x2>;
980                 };
981
982                 gpio2: gpio2@ff780000 {
983                         compatible = "rockchip,gpio-bank";
984                         reg = <0x0 0xff780000 0x0 0x100>;
985                         clocks = <&cru PCLK_GPIO2>;
986                         interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
987
988                         gpio-controller;
989                         #gpio-cells = <0x2>;
990
991                         interrupt-controller;
992                         #interrupt-cells = <0x2>;
993                 };
994
995                 gpio3: gpio3@ff788000 {
996                         compatible = "rockchip,gpio-bank";
997                         reg = <0x0 0xff788000 0x0 0x100>;
998                         clocks = <&cru PCLK_GPIO3>;
999                         interrupts = <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
1000
1001                         gpio-controller;
1002                         #gpio-cells = <0x2>;
1003
1004                         interrupt-controller;
1005                         #interrupt-cells = <0x2>;
1006                 };
1007
1008                 gpio4: gpio4@ff790000 {
1009                         compatible = "rockchip,gpio-bank";
1010                         reg = <0x0 0xff790000 0x0 0x100>;
1011                         clocks = <&cru PCLK_GPIO4>;
1012                         interrupts = <GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>;
1013
1014                         gpio-controller;
1015                         #gpio-cells = <0x2>;
1016
1017                         interrupt-controller;
1018                         #interrupt-cells = <0x2>;
1019                 };
1020
1021                 pcfg_pull_up: pcfg-pull-up {
1022                         bias-pull-up;
1023                 };
1024
1025                 pcfg_pull_down: pcfg-pull-down {
1026                         bias-pull-down;
1027                 };
1028
1029                 pcfg_pull_none: pcfg-pull-none {
1030                         bias-disable;
1031                 };
1032
1033                 pcfg_pull_none_12ma: pcfg-pull-none-12ma {
1034                         bias-disable;
1035                         drive-strength = <12>;
1036                 };
1037
1038                 pcfg_pull_up_8ma: pcfg-pull-up-8ma {
1039                         bias-pull-up;
1040                         drive-strength = <8>;
1041                 };
1042
1043                 pcfg_pull_down_4ma: pcfg-pull-down-4ma {
1044                         bias-pull-down;
1045                         drive-strength = <4>;
1046                 };
1047
1048                 pcfg_pull_up_2ma: pcfg-pull-up-2ma {
1049                         bias-pull-up;
1050                         drive-strength = <2>;
1051                 };
1052
1053                 pcfg_pull_down_12ma: pcfg-pull-down-12ma {
1054                         bias-pull-down;
1055                         drive-strength = <12>;
1056                 };
1057
1058                 emmc {
1059                         emmc_pwr: emmc-pwr {
1060                                 rockchip,pins =
1061                                         <0 5 RK_FUNC_1 &pcfg_pull_up>;
1062                         };
1063                 };
1064
1065                 gmac {
1066                         rgmii_pins: rgmii-pins {
1067                                 rockchip,pins =
1068                                         /* mac_txclk */
1069                                         <3 17 RK_FUNC_1 &pcfg_pull_none_12ma>,
1070                                         /* mac_rxclk */
1071                                         <3 14 RK_FUNC_1 &pcfg_pull_none>,
1072                                         /* mac_mdio */
1073                                         <3 13 RK_FUNC_1 &pcfg_pull_none>,
1074                                         /* mac_txen */
1075                                         <3 12 RK_FUNC_1 &pcfg_pull_none_12ma>,
1076                                         /* mac_clk */
1077                                         <3 11 RK_FUNC_1 &pcfg_pull_none>,
1078                                         /* mac_rxdv */
1079                                         <3 9 RK_FUNC_1 &pcfg_pull_none>,
1080                                         /* mac_mdc */
1081                                         <3 8 RK_FUNC_1 &pcfg_pull_none>,
1082                                         /* mac_rxd1 */
1083                                         <3 7 RK_FUNC_1 &pcfg_pull_none>,
1084                                         /* mac_rxd0 */
1085                                         <3 6 RK_FUNC_1 &pcfg_pull_none>,
1086                                         /* mac_txd1 */
1087                                         <3 5 RK_FUNC_1 &pcfg_pull_none_12ma>,
1088                                         /* mac_txd0 */
1089                                         <3 4 RK_FUNC_1 &pcfg_pull_none_12ma>,
1090                                         /* mac_rxd3 */
1091                                         <3 3 RK_FUNC_1 &pcfg_pull_none>,
1092                                         /* mac_rxd2 */
1093                                         <3 2 RK_FUNC_1 &pcfg_pull_none>,
1094                                         /* mac_txd3 */
1095                                         <3 1 RK_FUNC_1 &pcfg_pull_none_12ma>,
1096                                         /* mac_txd2 */
1097                                         <3 0 RK_FUNC_1 &pcfg_pull_none_12ma>;
1098                         };
1099
1100                         rmii_pins: rmii-pins {
1101                                 rockchip,pins =
1102                                         /* mac_mdio */
1103                                         <3 13 RK_FUNC_1 &pcfg_pull_none>,
1104                                         /* mac_txen */
1105                                         <3 12 RK_FUNC_1 &pcfg_pull_none_12ma>,
1106                                         /* mac_clk */
1107                                         <3 11 RK_FUNC_1 &pcfg_pull_none>,
1108                                         /* mac_rxer */
1109                                         <3 10 RK_FUNC_1 &pcfg_pull_none>,
1110                                         /* mac_rxdv */
1111                                         <3 9 RK_FUNC_1 &pcfg_pull_none>,
1112                                         /* mac_mdc */
1113                                         <3 8 RK_FUNC_1 &pcfg_pull_none>,
1114                                         /* mac_rxd1 */
1115                                         <3 7 RK_FUNC_1 &pcfg_pull_none>,
1116                                         /* mac_rxd0 */
1117                                         <3 6 RK_FUNC_1 &pcfg_pull_none>,
1118                                         /* mac_txd1 */
1119                                         <3 5 RK_FUNC_1 &pcfg_pull_none_12ma>,
1120                                         /* mac_txd0 */
1121                                         <3 4 RK_FUNC_1 &pcfg_pull_none_12ma>;
1122                         };
1123                 };
1124
1125                 i2c0 {
1126                         i2c0_xfer: i2c0-xfer {
1127                                 rockchip,pins =
1128                                         <1 15 RK_FUNC_2 &pcfg_pull_none>,
1129                                         <1 16 RK_FUNC_2 &pcfg_pull_none>;
1130                         };
1131                 };
1132
1133                 i2c1 {
1134                         i2c1_xfer: i2c1-xfer {
1135                                 rockchip,pins =
1136                                         <4 2 RK_FUNC_1 &pcfg_pull_none>,
1137                                         <4 1 RK_FUNC_1 &pcfg_pull_none>;
1138                         };
1139                 };
1140
1141                 i2c2 {
1142                         i2c2_xfer: i2c2-xfer {
1143                                 rockchip,pins =
1144                                         <2 1 RK_FUNC_2 &pcfg_pull_none_12ma>,
1145                                         <2 0 RK_FUNC_2 &pcfg_pull_none_12ma>;
1146                         };
1147                 };
1148
1149                 i2c3 {
1150                         i2c3_xfer: i2c3-xfer {
1151                                 rockchip,pins =
1152                                         <4 17 RK_FUNC_1 &pcfg_pull_none>,
1153                                         <4 16 RK_FUNC_1 &pcfg_pull_none>;
1154                         };
1155                 };
1156
1157                 i2c4 {
1158                         i2c4_xfer: i2c4-xfer {
1159                                 rockchip,pins =
1160                                         <1 12 RK_FUNC_1 &pcfg_pull_none>,
1161                                         <1 11 RK_FUNC_1 &pcfg_pull_none>;
1162                         };
1163                 };
1164
1165                 i2c5 {
1166                         i2c5_xfer: i2c5-xfer {
1167                                 rockchip,pins =
1168                                         <3 11 RK_FUNC_2 &pcfg_pull_none>,
1169                                         <3 10 RK_FUNC_2 &pcfg_pull_none>;
1170                         };
1171                 };
1172
1173                 i2c6 {
1174                         i2c6_xfer: i2c6-xfer {
1175                                 rockchip,pins =
1176                                         <2 10 RK_FUNC_2 &pcfg_pull_none>,
1177                                         <2 9 RK_FUNC_2 &pcfg_pull_none>;
1178                         };
1179                 };
1180
1181                 i2c7 {
1182                         i2c7_xfer: i2c7-xfer {
1183                                 rockchip,pins =
1184                                         <2 8 RK_FUNC_2 &pcfg_pull_none>,
1185                                         <2 7 RK_FUNC_2 &pcfg_pull_none>;
1186                         };
1187                 };
1188
1189                 i2c8 {
1190                         i2c8_xfer: i2c8-xfer {
1191                                 rockchip,pins =
1192                                         <1 21 RK_FUNC_1 &pcfg_pull_none>,
1193                                         <1 20 RK_FUNC_1 &pcfg_pull_none>;
1194                         };
1195                 };
1196
1197                 i2s0 {
1198                         i2s0_8ch_bus: i2s0-8ch-bus {
1199                                 rockchip,pins =
1200                                         <3 24 RK_FUNC_1 &pcfg_pull_none>,
1201                                         <3 25 RK_FUNC_1 &pcfg_pull_none>,
1202                                         <3 26 RK_FUNC_1 &pcfg_pull_none>,
1203                                         <3 27 RK_FUNC_1 &pcfg_pull_none>,
1204                                         <3 28 RK_FUNC_1 &pcfg_pull_none>,
1205                                         <3 29 RK_FUNC_1 &pcfg_pull_none>,
1206                                         <3 30 RK_FUNC_1 &pcfg_pull_none>,
1207                                         <3 31 RK_FUNC_1 &pcfg_pull_none>,
1208                                         <4 0 RK_FUNC_1 &pcfg_pull_none>;
1209                         };
1210                 };
1211
1212                 i2s1 {
1213                         i2s1_2ch_bus: i2s1-2ch-bus {
1214                                 rockchip,pins =
1215                                         <4 3 RK_FUNC_1 &pcfg_pull_none>,
1216                                         <4 4 RK_FUNC_1 &pcfg_pull_none>,
1217                                         <4 5 RK_FUNC_1 &pcfg_pull_none>,
1218                                         <4 6 RK_FUNC_1 &pcfg_pull_none>,
1219                                         <4 7 RK_FUNC_1 &pcfg_pull_none>;
1220                         };
1221                 };
1222
1223                 sdio0 {
1224                         sdio0_bus1: sdio0-bus1 {
1225                                 rockchip,pins =
1226                                         <2 20 RK_FUNC_1 &pcfg_pull_up>;
1227                         };
1228
1229                         sdio0_bus4: sdio0-bus4 {
1230                                 rockchip,pins =
1231                                         <2 20 RK_FUNC_1 &pcfg_pull_up>,
1232                                         <2 21 RK_FUNC_1 &pcfg_pull_up>,
1233                                         <2 22 RK_FUNC_1 &pcfg_pull_up>,
1234                                         <2 23 RK_FUNC_1 &pcfg_pull_up>;
1235                         };
1236
1237                         sdio0_cmd: sdio0-cmd {
1238                                 rockchip,pins =
1239                                         <2 24 RK_FUNC_1 &pcfg_pull_up>;
1240                         };
1241
1242                         sdio0_clk: sdio0-clk {
1243                                 rockchip,pins =
1244                                         <2 25 RK_FUNC_1 &pcfg_pull_none>;
1245                         };
1246
1247                         sdio0_cd: sdio0-cd {
1248                                 rockchip,pins =
1249                                         <2 26 RK_FUNC_1 &pcfg_pull_up>;
1250                         };
1251
1252                         sdio0_pwr: sdio0-pwr {
1253                                 rockchip,pins =
1254                                         <2 27 RK_FUNC_1 &pcfg_pull_up>;
1255                         };
1256
1257                         sdio0_bkpwr: sdio0-bkpwr {
1258                                 rockchip,pins =
1259                                         <2 28 RK_FUNC_1 &pcfg_pull_up>;
1260                         };
1261
1262                         sdio0_wp: sdio0-wp {
1263                                 rockchip,pins =
1264                                         <0 3 RK_FUNC_1 &pcfg_pull_up>;
1265                         };
1266
1267                         sdio0_int: sdio0-int {
1268                                 rockchip,pins =
1269                                         <0 4 RK_FUNC_1 &pcfg_pull_up>;
1270                         };
1271                 };
1272
1273                 sdmmc {
1274                         sdmmc_bus1: sdmmc-bus1 {
1275                                 rockchip,pins =
1276                                         <4 8 RK_FUNC_1 &pcfg_pull_up>;
1277                         };
1278
1279                         sdmmc_bus4: sdmmc-bus4 {
1280                                 rockchip,pins =
1281                                         <4 8 RK_FUNC_1 &pcfg_pull_up>,
1282                                         <4 9 RK_FUNC_1 &pcfg_pull_up>,
1283                                         <4 10 RK_FUNC_1 &pcfg_pull_up>,
1284                                         <4 11 RK_FUNC_1 &pcfg_pull_up>;
1285                         };
1286
1287                         sdmmc_clk: sdmmc-clk {
1288                                 rockchip,pins =
1289                                         <4 12 RK_FUNC_1 &pcfg_pull_none>;
1290                         };
1291
1292                         sdmmc_cmd: sdmmc-cmd {
1293                                 rockchip,pins =
1294                                         <4 13 RK_FUNC_1 &pcfg_pull_up>;
1295                         };
1296
1297                         sdmmc_cd: sdmcc-cd {
1298                                 rockchip,pins =
1299                                         <0 7 RK_FUNC_1 &pcfg_pull_up>;
1300                         };
1301
1302                         sdmmc_wp: sdmmc-wp {
1303                                 rockchip,pins =
1304                                         <0 8 RK_FUNC_1 &pcfg_pull_up>;
1305                         };
1306                 };
1307
1308                 spdif {
1309                         spdif_bus: spdif-bus {
1310                                 rockchip,pins =
1311                                         <4 21 RK_FUNC_1 &pcfg_pull_none>;
1312                         };
1313                 };
1314
1315                 spi0 {
1316                         spi0_clk: spi0-clk {
1317                                 rockchip,pins =
1318                                         <3 6 RK_FUNC_2 &pcfg_pull_up>;
1319                         };
1320                         spi0_cs0: spi0-cs0 {
1321                                 rockchip,pins =
1322                                         <3 7 RK_FUNC_2 &pcfg_pull_up>;
1323                         };
1324                         spi0_cs1: spi0-cs1 {
1325                                 rockchip,pins =
1326                                         <3 8 RK_FUNC_2 &pcfg_pull_up>;
1327                         };
1328                         spi0_tx: spi0-tx {
1329                                 rockchip,pins =
1330                                         <3 5 RK_FUNC_2 &pcfg_pull_up>;
1331                         };
1332                         spi0_rx: spi0-rx {
1333                                 rockchip,pins =
1334                                         <3 4 RK_FUNC_2 &pcfg_pull_up>;
1335                         };
1336                 };
1337
1338                 spi1 {
1339                         spi1_clk: spi1-clk {
1340                                 rockchip,pins =
1341                                         <1 9 RK_FUNC_2 &pcfg_pull_up>;
1342                         };
1343                         spi1_cs0: spi1-cs0 {
1344                                 rockchip,pins =
1345                                         <1 10 RK_FUNC_2 &pcfg_pull_up>;
1346                         };
1347                         spi1_rx: spi1-rx {
1348                                 rockchip,pins =
1349                                         <1 7 RK_FUNC_2 &pcfg_pull_up>;
1350                         };
1351                         spi1_tx: spi1-tx {
1352                                 rockchip,pins =
1353                                         <1 8 RK_FUNC_2 &pcfg_pull_up>;
1354                         };
1355                 };
1356
1357                 spi2 {
1358                         spi2_clk: spi2-clk {
1359                                 rockchip,pins =
1360                                         <2 11 RK_FUNC_1 &pcfg_pull_up>;
1361                         };
1362                         spi2_cs0: spi2-cs0 {
1363                                 rockchip,pins =
1364                                         <2 12 RK_FUNC_1 &pcfg_pull_up>;
1365                         };
1366                         spi2_rx: spi2-rx {
1367                                 rockchip,pins =
1368                                         <2 9 RK_FUNC_1 &pcfg_pull_up>;
1369                         };
1370                         spi2_tx: spi2-tx {
1371                                 rockchip,pins =
1372                                         <2 10 RK_FUNC_1 &pcfg_pull_up>;
1373                         };
1374                 };
1375
1376                 spi3 {
1377                         spi3_clk: spi3-clk {
1378                                 rockchip,pins =
1379                                         <1 17 RK_FUNC_1 &pcfg_pull_up>;
1380                         };
1381                         spi3_cs0: spi3-cs0 {
1382                                 rockchip,pins =
1383                                         <1 18 RK_FUNC_1 &pcfg_pull_up>;
1384                         };
1385                         spi3_rx: spi3-rx {
1386                                 rockchip,pins =
1387                                         <1 15 RK_FUNC_1 &pcfg_pull_up>;
1388                         };
1389                         spi3_tx: spi3-tx {
1390                                 rockchip,pins =
1391                                         <1 16 RK_FUNC_1 &pcfg_pull_up>;
1392                         };
1393                 };
1394
1395                 spi4 {
1396                         spi4_clk: spi4-clk {
1397                                 rockchip,pins =
1398                                         <3 2 RK_FUNC_2 &pcfg_pull_up>;
1399                         };
1400                         spi4_cs0: spi4-cs0 {
1401                                 rockchip,pins =
1402                                         <3 3 RK_FUNC_2 &pcfg_pull_up>;
1403                         };
1404                         spi4_rx: spi4-rx {
1405                                 rockchip,pins =
1406                                         <3 0 RK_FUNC_2 &pcfg_pull_up>;
1407                         };
1408                         spi4_tx: spi4-tx {
1409                                 rockchip,pins =
1410                                         <3 1 RK_FUNC_2 &pcfg_pull_up>;
1411                         };
1412                 };
1413
1414                 spi5 {
1415                         spi5_clk: spi5-clk {
1416                                 rockchip,pins =
1417                                         <2 22 RK_FUNC_2 &pcfg_pull_up>;
1418                         };
1419                         spi5_cs0: spi5-cs0 {
1420                                 rockchip,pins =
1421                                         <2 23 RK_FUNC_2 &pcfg_pull_up>;
1422                         };
1423                         spi5_rx: spi5-rx {
1424                                 rockchip,pins =
1425                                         <2 20 RK_FUNC_2 &pcfg_pull_up>;
1426                         };
1427                         spi5_tx: spi5-tx {
1428                                 rockchip,pins =
1429                                         <2 21 RK_FUNC_2 &pcfg_pull_up>;
1430                         };
1431                 };
1432
1433                 tsadc {
1434                         otp_gpio: otp-gpio {
1435                                 rockchip,pins = <1 6 RK_FUNC_GPIO &pcfg_pull_none>;
1436                         };
1437
1438                         otp_out: otp-out {
1439                                 rockchip,pins = <1 6 RK_FUNC_1 &pcfg_pull_none>;
1440                         };
1441                 };
1442
1443                 uart0 {
1444                         uart0_xfer: uart0-xfer {
1445                                 rockchip,pins =
1446                                         <2 16 RK_FUNC_1 &pcfg_pull_up>,
1447                                         <2 17 RK_FUNC_1 &pcfg_pull_none>;
1448                         };
1449
1450                         uart0_cts: uart0-cts {
1451                                 rockchip,pins =
1452                                         <2 18 RK_FUNC_1 &pcfg_pull_none>;
1453                         };
1454
1455                         uart0_rts: uart0-rts {
1456                                 rockchip,pins =
1457                                         <2 19 RK_FUNC_1 &pcfg_pull_none>;
1458                         };
1459                 };
1460
1461                 uart1 {
1462                         uart1_xfer: uart1-xfer {
1463                                 rockchip,pins =
1464                                         <3 12 RK_FUNC_2 &pcfg_pull_up>,
1465                                         <3 13 RK_FUNC_2 &pcfg_pull_none>;
1466                         };
1467                 };
1468
1469                 uart2a {
1470                         uart2a_xfer: uart2a-xfer {
1471                                 rockchip,pins =
1472                                         <4 8 RK_FUNC_2 &pcfg_pull_up>,
1473                                         <4 9 RK_FUNC_2 &pcfg_pull_none>;
1474                         };
1475                 };
1476
1477                 uart2b {
1478                         uart2b_xfer: uart2b-xfer {
1479                                 rockchip,pins =
1480                                         <4 16 RK_FUNC_2 &pcfg_pull_up>,
1481                                         <4 17 RK_FUNC_2 &pcfg_pull_none>;
1482                         };
1483                 };
1484
1485                 uart2c {
1486                         uart2c_xfer: uart2c-xfer {
1487                                 rockchip,pins =
1488                                         <4 19 RK_FUNC_1 &pcfg_pull_up>,
1489                                         <4 20 RK_FUNC_1 &pcfg_pull_none>;
1490                         };
1491                 };
1492
1493                 uart3 {
1494                         uart3_xfer: uart3-xfer {
1495                                 rockchip,pins =
1496                                         <3 14 RK_FUNC_2 &pcfg_pull_up>,
1497                                         <3 15 RK_FUNC_2 &pcfg_pull_none>;
1498                         };
1499
1500                         uart3_cts: uart3-cts {
1501                                 rockchip,pins =
1502                                         <3 18 RK_FUNC_2 &pcfg_pull_none>;
1503                         };
1504
1505                         uart3_rts: uart3-rts {
1506                                 rockchip,pins =
1507                                         <3 19 RK_FUNC_2 &pcfg_pull_none>;
1508                         };
1509                 };
1510
1511                 uart4 {
1512                         uart4_xfer: uart4-xfer {
1513                                 rockchip,pins =
1514                                         <1 7 RK_FUNC_1 &pcfg_pull_up>,
1515                                         <1 8 RK_FUNC_1 &pcfg_pull_none>;
1516                         };
1517                 };
1518
1519                 uarthdcp {
1520                         uarthdcp_xfer: uarthdcp-xfer {
1521                                 rockchip,pins =
1522                                         <4 21 RK_FUNC_2 &pcfg_pull_up>,
1523                                         <4 22 RK_FUNC_2 &pcfg_pull_none>;
1524                         };
1525                 };
1526
1527                 pwm0 {
1528                         pwm0_pin: pwm0-pin {
1529                                 rockchip,pins =
1530                                         <4 18 RK_FUNC_1 &pcfg_pull_none>;
1531                         };
1532
1533                         vop0_pwm_pin: vop0-pwm-pin {
1534                                 rockchip,pins =
1535                                         <4 18 RK_FUNC_2 &pcfg_pull_none>;
1536                         };
1537                 };
1538
1539                 pwm1 {
1540                         pwm1_pin: pwm1-pin {
1541                                 rockchip,pins =
1542                                         <4 22 RK_FUNC_1 &pcfg_pull_none>;
1543                         };
1544
1545                         vop1_pwm_pin: vop1-pwm-pin {
1546                                 rockchip,pins =
1547                                         <4 18 RK_FUNC_3 &pcfg_pull_none>;
1548                         };
1549                 };
1550
1551                 pwm2 {
1552                         pwm2_pin: pwm2-pin {
1553                                 rockchip,pins =
1554                                         <1 19 RK_FUNC_1 &pcfg_pull_none>;
1555                         };
1556                 };
1557
1558                 pwm3a {
1559                         pwm3a_pin: pwm3a-pin {
1560                                 rockchip,pins =
1561                                         <0 6 RK_FUNC_1 &pcfg_pull_none>;
1562                         };
1563                 };
1564
1565                 pwm3b {
1566                         pwm3b_pin: pwm3b-pin {
1567                                 rockchip,pins =
1568                                         <1 14 RK_FUNC_1 &pcfg_pull_none>;
1569                         };
1570                 };
1571
1572                 pmic {
1573                         pmic_int_l: pmic-int-l {
1574                                 rockchip,pins =
1575                                         <1 21 RK_FUNC_GPIO &pcfg_pull_up>;
1576                         };
1577                 };
1578         };
1579 };