Merge branch 'v1.4' into v1.5
[librecmc/librecmc.git] / target / linux / ramips / dts / WHR-600D.dts
1 /dts-v1/;
2
3 #include "mt7620a.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8         compatible = "ralink,mt7620a-soc";
9         model = "Buffalo WHR-600D";
10
11         gpio-leds {
12                 compatible = "gpio-leds";
13
14                 power {
15                         label = "whr-600d:red:power";
16                         gpios = <&gpio0 7 1>;
17                 };
18
19                 wifi {
20                         label = "whr-600d:green:wifi";
21                         gpios = <&gpio0 8 1>;
22                 };
23
24                 power2 {
25                         label = "whr-600d:green:power";
26                         gpios = <&gpio0 9 1>;
27                 };
28
29                 wifi2 {
30                         label = "whr-600d:orange:wifi";
31                         gpios = <&gpio0 10 1>;
32                 };
33
34                 internet {
35                         label = "whr-600d:green:internet";
36                         gpios = <&gpio2 17 1>;
37                 };
38
39                 router {
40                         label = "whr-600d:green:router";
41                         gpios = <&gpio2 18 1>;
42                 };
43
44                 router2 {
45                         label = "whr-600d:orange:router";
46                         gpios = <&gpio2 19 1>;
47                 };
48         };
49
50         gpio-keys-polled {
51                 compatible = "gpio-keys-polled";
52                 #address-cells = <1>;
53                 #size-cells = <0>;
54                 poll-interval = <20>;
55
56                 reset {
57                         label = "reset";
58                         gpios = <&gpio2 12 1>;
59                         linux,code = <KEY_RESTART>;
60                 };
61
62                 aoss {
63                         label = "aoss";
64                         gpios = <&gpio2 13 1>;
65                         linux,code = <KEY_WPS_BUTTON>;
66                 };
67
68                 ap {
69                         label = "ap";
70                         gpios = <&gpio2 14 1>;
71                         linux,code = <BTN_0>;
72                         linux,input-type = <EV_SW>;
73                 };
74
75                 bridge {
76                         label = "bridge";
77                         gpios = <&gpio2 15 1>;
78                         linux,code = <BTN_0>;
79                         linux,input-type = <EV_SW>;
80                 };
81         };
82 };
83
84 &gpio2 {
85         status = "okay";
86 };
87
88 &spi0 {
89         status = "okay";
90
91         m25p80@0 {
92                 #address-cells = <1>;
93                 #size-cells = <1>;
94                 compatible = "jedec,spi-nor";
95                 reg = <0>;
96                 spi-max-frequency = <10000000>;
97
98                 partition@0 {
99                         label = "u-boot";
100                         reg = <0x0 0x30000>;
101                         read-only;
102                 };
103
104                 partition@30000 {
105                         label = "u-boot-env";
106                         reg = <0x30000 0x10000>;
107                         read-only;
108                 };
109
110                 factory: partition@40000 {
111                         label = "factory";
112                         reg = <0x40000 0x10000>;
113                         read-only;
114                 };
115
116                 partition@50000 {
117                         label = "firmware";
118                         reg = <0x50000 0x7b0000>;
119                 };
120         };
121 };
122
123 &pinctrl {
124         state_default: pinctrl0 {
125                 gpio {
126                         ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
127                         ralink,function = "gpio";
128                 };
129         };
130 };
131
132 &ethernet {
133         pinctrl-names = "default";
134         pinctrl-0 = <&ephy_pins>;
135         mtd-mac-address = <&factory 0x4>;
136         mediatek,portmap = "llllw";
137 };
138
139 &gsw {
140         mediatek,port4 = "ephy";
141 };
142
143 &wmac {
144         ralink,mtd-eeprom = <&factory 0>;
145 };
146
147 &pcie {
148         status = "okay";
149
150         pcie-bridge {
151                 wifi@1814,5592 {
152                         compatible = "pci1814,5592";
153                         reg = <0x0000 0 0 0 0>;
154                         ralink,mtd-eeprom = <&factory 0x8000>;
155                 };
156         };
157 };