b595c581fe9468d37882d827f1319d06be0c9ebe
[openwrt/staging/jow.git] / target / linux / ramips / dts / mt7620a_glinet_gl-mt750.dts
1 #include "mt7620a.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "glinet,gl-mt750", "ralink,mt7620a-soc";
8 model = "GL-MT750";
9
10 aliases {
11 label-mac-device = &wmac;
12 };
13
14 chosen {
15 bootargs = "console=ttyS0,115200";
16 };
17
18 leds {
19 compatible = "gpio-leds";
20
21 wan {
22 label = "gl-mt750:wan";
23 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
24 };
25
26 lan {
27 label = "gl-mt750:lan";
28 gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
29 };
30
31 wlan {
32 label = "gl-mt750:wlan";
33 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
34 };
35 };
36
37 keys {
38 compatible = "gpio-keys";
39
40 reset {
41 label = "reset";
42 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
43 linux,code = <KEY_RESTART>;
44 };
45
46 BTN_0 {
47 label = "BTN_0";
48 gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
49 linux,code = <BTN_0>;
50 };
51
52 BTN_1 {
53 label = "BTN_1";
54 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
55 linux,code = <BTN_1>;
56 };
57 };
58 };
59
60 &gpio2 {
61 status = "okay";
62 };
63
64 &gpio3 {
65 status = "okay";
66 };
67
68 &spi0 {
69 status = "okay";
70
71 flash@0 {
72 compatible = "jedec,spi-nor";
73 reg = <0>;
74 spi-max-frequency = <10000000>;
75
76 partitions {
77 compatible = "fixed-partitions";
78 #address-cells = <1>;
79 #size-cells = <1>;
80
81 partition@0 {
82 label = "u-boot";
83 reg = <0x0 0x30000>;
84 };
85
86 partition@30000 {
87 label = "u-boot-env";
88 reg = <0x30000 0x10000>;
89 read-only;
90 };
91
92 factory: partition@40000 {
93 label = "factory";
94 reg = <0x40000 0x10000>;
95 read-only;
96
97 nvmem-layout {
98 compatible = "fixed-layout";
99 #address-cells = <1>;
100 #size-cells = <1>;
101
102 eeprom_factory_0: eeprom@0 {
103 reg = <0x0 0x200>;
104 };
105
106 eeprom_factory_8000: eeprom@8000 {
107 reg = <0x8000 0x200>;
108 };
109
110 macaddr_factory_4000: macaddr@4000 {
111 reg = <0x4000 0x6>;
112 };
113 };
114 };
115
116 partition@50000 {
117 compatible = "denx,uimage";
118 label = "firmware";
119 reg = <0x50000 0xf80000>;
120 };
121
122 partition@ff0000 {
123 label = "art";
124 reg = <0xff0000 0x10000>;
125 };
126 };
127 };
128 };
129
130 &sdhci {
131 status = "okay";
132 };
133
134 &ehci {
135 status = "okay";
136 };
137
138 &ohci {
139 status = "okay";
140 };
141
142 &ethernet {
143 nvmem-cells = <&macaddr_factory_4000>;
144 nvmem-cell-names = "mac-address";
145
146 mediatek,portmap = "wllll";
147 };
148
149 &wmac {
150 nvmem-cells = <&eeprom_factory_0>;
151 nvmem-cell-names = "eeprom";
152 };
153
154 &pcie {
155 status = "okay";
156 };
157
158 &pcie0 {
159 mt76@0,0 {
160 reg = <0x0000 0 0 0 0>;
161 nvmem-cells = <&eeprom_factory_8000>;
162 nvmem-cell-names = "eeprom";
163 };
164 };
165
166 &state_default {
167 gpio {
168 groups = "wled","ephy","uartf";
169 function = "gpio";
170 };
171 };