f7ef9335f1cf2544c1bdae912526774dfb6ca590
[openwrt/openwrt.git] / target / linux / ramips / dts / WRH-300CR.dts
1 /dts-v1/;
2
3 #include "mt7620n.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "elecom,wrh-300cr", "ralink,mt7620n-soc";
9 model = "ELECOM WRH-300CR";
10
11 gpio-leds {
12 compatible = "gpio-leds";
13
14 wps {
15 label = "wrh-300cr:green:wps";
16 gpios = <&gpio2 0 1>;
17 };
18
19 ethernet {
20 label = "wrh-300cr:green:ethernet";
21 gpios = <&gpio2 3 1>;
22 };
23
24 wlan {
25 label = "wrh-300cr:green:wlan";
26 gpios = <&gpio3 0 1>;
27 };
28 };
29
30 gpio-keys-polled {
31 compatible = "gpio-keys-polled";
32 #address-cells = <1>;
33 #size-cells = <0>;
34 poll-interval = <20>;
35
36 reset {
37 label = "reset";
38 gpios = <&gpio0 1 1>;
39 linux,code = <KEY_RESTART>;
40 };
41
42 wps {
43 label = "wps";
44 gpios = <&gpio0 2 1>;
45 linux,code = <KEY_WPS_BUTTON>;
46 };
47 };
48 };
49
50 &gpio1 {
51 status = "okay";
52 };
53
54 &gpio2 {
55 status = "okay";
56 };
57
58 &gpio3 {
59 status = "okay";
60 };
61
62 &spi0 {
63 status = "okay";
64
65 m25p80@0 {
66 #address-cells = <1>;
67 #size-cells = <1>;
68 compatible = "jedec,spi-nor";
69 reg = <0>;
70 linux,modalias = "m25p80", "mx25l12805d";
71 spi-max-frequency = <10000000>;
72
73 partition@0 {
74 label = "u-boot";
75 reg = <0x0 0x30000>;
76 read-only;
77 };
78
79 partition@30000 {
80 label = "u-boot-env";
81 reg = <0x30000 0x10000>;
82 };
83
84 factory: partition@40000 {
85 label = "factory";
86 reg = <0x40000 0x10000>;
87 read-only;
88 };
89
90 partition@50000 {
91 label = "recover";
92 reg = <0x50000 0x1c0000>;
93 read-only;
94 };
95
96 partition@210000 {
97 label = "firmware";
98 reg = <0x210000 0xdf0000>;
99 };
100 };
101 };
102
103 &ehci {
104 status = "okay";
105 };
106
107 &ohci {
108 status = "okay";
109 };
110
111 &ethernet {
112 mtd-mac-address = <&factory 0x2e>;
113 mediatek,portmap = "llllw";
114 };
115
116 &wmac {
117 ralink,mtd-eeprom = <&factory 0>;
118 };
119
120 &pinctrl {
121 state_default: pinctrl0 {
122 default {
123 ralink,group = "i2c", "ephy", "wled";
124 ralink,function = "gpio";
125 };
126 };
127 };