apm821xx: dts: append SoC compatible to DTS
[oweals/openwrt.git] / target / linux / apm821xx / dts / MX60.dts
1 /*
2  * Device Tree Source for Meraki MX60/MX60W (Buckminster)
3  *
4  * Copyright (C) 2016 Chris Blake <chrisrblake93@gmail.com>
5  *
6  * Based on Cisco Meraki DTS extracted from release wired-12-217818
7  *
8  * This file is licensed under the terms of the GNU General Public
9  * License version 2.  This program is licensed "as is" without
10  * any warranty of any kind, whether express or implied.
11  */
12
13 /dts-v1/;
14
15 #include "apm82181.dtsi"
16
17 / {
18         model = "Meraki MX60/MX60W Security Appliance";
19         compatible = "meraki,buckminster", "apm,bluestone";
20
21         aliases {
22                 serial0 = &UART1;
23                 led-boot = &status;
24                 led-failsafe = &failsafe;
25                 led-running = &status;
26                 led-upgrade = &status;
27         };
28
29         chosen {
30                 linux,stdout-path = "/plb/opb/serial@ef600400";
31         };
32
33 };
34
35 &CRYPTO {
36         status = "okay";
37 };
38
39 &PKA {
40         status = "okay";
41 };
42
43 &TRNG {
44         status = "okay";
45 };
46
47 &USBOTG0 {
48         status = "okay";
49         dr_mode = "host";
50 };
51
52 &EBC0 {
53         /* Buckminster has 1GiB of NAND */
54         ndfc@1,0 {
55                 status = "okay";
56                 nand {
57                         #address-cells = <1>;
58                         #size-cells = <1>;
59
60                         partition@0 {
61                                 label = "u-boot";
62                                 reg = <0x00000000 0x00100000>;
63                                 read-only;
64                         };
65
66                         partition@100000 {
67                                 label = "u-boot-env";
68                                 reg = <0x00100000 0x00100000>;
69                                 read-only;
70                         };
71
72                         partition@200000 {
73                                 label = "oops";
74                                 reg = <0x00200000 0x00040000>;
75                         };
76
77                         partition@240000 {
78                                 label = "ubi";
79                                 reg = <0x00240000 0x3fdc0000>;
80                         };
81
82                         all {
83                                 label = "all";
84                                 reg = <0x00000000 0x40000000>;
85                         };
86                 };
87         };
88 };
89
90 &UART1 {
91         status = "okay";
92 };
93
94 &GPIO0 {
95         status = "okay";
96 };
97
98 &IIC0 {
99         status = "okay";
100 };
101
102 &EMAC0 {
103         status = "okay";
104         phy-handle = <&phy0>;
105
106         mdio {
107                 #address-cells = <1>;
108                 #size-cells = <0>;
109                 phy0: ethernet-phy@0 {
110                         device_type = "ethernet-phy";
111                         reg = <0>;
112                         qca,ar8327-initvals = <
113                                 0x0010 0x40000000
114                                 0x0624 0x007f7f7f
115                                 0x0004 0x07a00000       /* PAD0_MODE */
116                                 0x000c 0x01000000       /* PAD6_MODE */
117                                 0x007c 0x0000007e       /* PORT0_STATUS */
118                         >;
119                 };
120         };
121 };
122
123 &POB0 {
124         gpio-leds {
125                 compatible = "gpio-leds";
126
127                 status: power-green {
128                         label = "mx60:green:power";
129                         gpios = <&GPIO0 18 GPIO_ACTIVE_LOW>;
130                 };
131
132                 failsafe: power-orange {
133                         label = "mx60:orange:power";
134                         gpios = <&GPIO0 19 GPIO_ACTIVE_LOW>;
135                 };
136
137                 wan-green {
138                         label = "mx60:green:wan";
139                         gpios = <&GPIO0 17 GPIO_ACTIVE_LOW>;
140                 };
141
142                 wan-orange {
143                         label = "mx60:orange:wan";
144                         gpios = <&GPIO0 15 GPIO_ACTIVE_LOW>;
145                 };
146
147                 lan1 {
148                         label = "mx60:green:lan1";
149                         gpios = <&GPIO0 20 GPIO_ACTIVE_LOW>;
150                 };
151
152                 lan2 {
153                         label = "mx60:green:lan2";
154                         gpios = <&GPIO0 21 GPIO_ACTIVE_LOW>;
155                 };
156
157                 lan3 {
158                         label = "mx60:green:lan3";
159                         gpios = <&GPIO0 22 GPIO_ACTIVE_LOW>;
160                 };
161
162                 lan4 {
163                         label = "mx60:green:lan4";
164                         gpios = <&GPIO0 23 GPIO_ACTIVE_LOW>;
165                 };
166         };
167
168         gpio_keys_polled {
169                 compatible = "gpio-keys-polled";
170                 #address-cells = <1>;
171                 #size-cells = <0>;
172                 poll-interval = <60>;   /* 3 * 20 = 60ms */
173                 autorepeat;
174
175                 button@1 {
176                         label = "Reset button";
177                         linux,code = <KEY_RESTART>;
178                         gpios = <&GPIO0 16 GPIO_ACTIVE_LOW>;
179                 };
180         };
181 };
182
183 &PCIE0 {
184         /* Leave this enabled as u-boot on the MX60 will disable it for us */
185         status = "okay";
186 };
187
188 &MSI {
189         status = "okay";
190 };