ramips: use rfkill for wps button on wlan only boards
[oweals/openwrt.git] / target / linux / ramips / dts / WSR-600.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 / {
6         compatible = "ralink,mt7621-eval-board", "ralink,mt7621-soc";
7         model = "Buffalo WSR-600DHP";
8
9         memory@0 {
10                 device_type = "memory";
11                 reg = <0x0 0x4000000>;
12         };
13
14         chosen {
15                 bootargs = "console=ttyS0,57600";
16         };
17
18         gpio-leds {
19                 compatible = "gpio-leds";
20
21                 power {
22                         label = "wsr-600:green:power";
23                         gpios = <&gpio0 12 1>;
24                 };
25
26                 wifi_o {
27                         label = "wsr-600:orange:wifi";
28                         gpios = <&gpio1 9 1>;
29                 };
30
31                 diag {
32                         label = "wsr-600:orange:diag";
33                         gpios = <&gpio1 10 1>;
34                 };
35
36                 wifi_g {
37                         label = "wsr-600:green:wifi";
38                         gpios = <&gpio1 12 1>;
39                 };
40
41                 router_o {
42                         label = "wsr-600:orange:router";
43                         gpios = <&gpio1 13 1>;
44                 };
45
46                 router_g {
47                         label = "wsr-600:green:router";
48                         gpios = <&gpio1 14 1>;
49                 };
50
51                 internet_o {
52                         label = "wsr-600:orange:internet";
53                         gpios = <&gpio1 15 1>;
54                 };
55
56                 internet_g {
57                         label = "wsr-600:green:internet";
58                         gpios = <&gpio1 16 1>;
59                 };
60         };
61
62         gpio-keys-polled {
63                 compatible = "gpio-keys-polled";
64                 #address-cells = <1>;
65                 #size-cells = <0>;
66                 poll-interval = <20>;
67
68                 power {
69                         label = "power";
70                         gpios = <&gpio0 8 1>;
71                         linux,code = <0x74>;
72                 };
73
74                 reset {
75                         label = "reset";
76                         gpios = <&gpio0 11 1>;
77                         linux,code = <0x198>;
78                 };
79
80                 aoss {
81                         label = "aoss";
82                         gpios = <&gpio0 18 1>;
83                         linux,code = <0x211>;
84                 };
85
86                 auto {
87                         label = "mode";
88                         gpios = <&gpio0 7 0>;
89                         linux,code = <0x100>;
90                         linux,input-type = <5>; /* EV_SW */
91                 };
92
93                 ap {
94                         label = "ap";
95                         gpios = <&gpio0 6 0>;
96                         linux,code = <0x100>;
97                         linux,input-type = <5>; /* EV_SW */
98                 };
99
100                 router {
101                         label = "router";
102                         gpios = <&gpio0 10 0>;
103                         linux,code = <0x100>;
104                         linux,input-type = <5>; /* EV_SW */
105                 };
106         };
107
108         gpio_poweroff {
109                 compatible = "gpio-poweroff";
110                 gpios = <&gpio1 11 1>;
111         };
112 };
113
114 &spi0 {
115         status = "okay";
116
117         m25p80@0 {
118                 #address-cells = <1>;
119                 #size-cells = <1>;
120                 compatible = "jedec,spi-nor";
121                 reg = <0>;
122                 linux,modalias = "m25p80";
123                 spi-max-frequency = <10000000>;
124
125                 partition@0 {
126                         label = "u-boot";
127                         reg = <0x0 0x30000>;
128                         read-only;
129                 };
130
131                 partition@30000 {
132                         label = "u-boot-env";
133                         reg = <0x30000 0x10000>;
134                         read-only;
135                 };
136
137                 factory: partition@40000 {
138                         label = "factory";
139                         reg = <0x40000 0x10000>;
140                         read-only;
141                 };
142
143                 partition@50000 {
144                         label = "firmware";
145                         reg = <0x50000 0xfb0000>;
146                 };
147         };
148 };
149
150 &pinctrl {
151         state_default: pinctrl0 {
152                 gpio {
153                         ralink,group = "i2c", "uart2", "uart3", "rgmii2", "sdhci";
154                         ralink,function = "gpio";
155                 };
156         };
157 };