Revert "ramips: improve interrupt mapping"
[oweals/openwrt.git] / target / linux / ramips / dts / WIZFI630A.dts
1 /dts-v1/;
2
3 #include "rt5350.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9         compatible = "wiznet,wizfi630a", "ralink,rt5350-soc";
10         model = "WIZnet WizFi630A";
11
12         chosen {
13                 bootargs = "console=ttyS1,115200";
14         };
15
16         gpio-leds {
17                 compatible = "gpio-leds";
18
19                 run {
20                         label = "wizfi630a::run";
21                         gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
22                 };
23
24                 wps {
25                         label = "wizfi630a::wps";
26                         gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
27                 };
28
29                 uart1 {
30                         label = "wizfi630a::uart1";
31                         gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
32                 };
33
34                 uart2 {
35                         label = "wizfi630a::uart2";
36                         gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
37                 };
38         };
39
40         gpio-keys-polled {
41                 compatible = "gpio-keys-polled";
42                 #address-cells = <1>;
43                 #size-cells = <0>;
44                 poll-interval = <20>;
45
46                 reset {
47                         label = "reset";
48                         gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
49                         linux,code = <KEY_RESTART>;
50                 };
51
52                 wps {
53                         label = "wps";
54                         gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
55                         linux,code = <KEY_WPS_BUTTON>;
56                 };
57                 
58                 scm1 {
59                         label = "SCM1";
60                         gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
61                         linux,code = <BTN_0>;
62                 };
63
64                 scm2 {
65                         label = "SCM2";
66                         gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
67                         linux,code = <BTN_1>;
68                 };
69         };
70 };
71
72 &gpio1 {
73         status = "okay";
74 };
75
76 &spi0 {
77         status = "okay";
78
79         m25p80@0 {
80                 #address-cells = <1>;
81                 #size-cells = <1>;
82                 compatible = "jedec,spi-nor";
83                 reg = <0>;
84                 spi-max-frequency = <10000000>;
85
86                 partition@0 {
87                         #size-cells = <1>;
88                         label = "uboot";
89                         reg = <0x0 0x30000>;
90                         read-only;
91                 };
92
93                 partition@30000 {
94                         #size-cells = <1>;
95                         label = "uboot-env";
96                         reg = <0x30000 0x10000>;
97                         read-only;
98                 };
99
100                 factory: partition@40000 {
101                         #size-cells = <1>;
102                         label = "factory";
103                         reg = <0x40000 0x10000>;
104                         read-only;
105                 };
106
107                 partition@50000 {
108                         #size-cells = <1>;
109                         label = "firmware";
110                         reg = <0x50000 0xfb0000>;
111                 };
112         };
113 };
114
115 &uart {
116         status = "okay";
117         pinctrl-names = "default";
118         pinctrl-0 = <&uartf_pins>;
119 };
120
121 &pinctrl {
122         state_default: pinctrl0 {
123                 gpio {
124                         ralink,group = "i2c", "jtag" ;
125                         ralink,function = "gpio";
126                 };
127         };
128 };
129
130 &ethernet {
131         mtd-mac-address = <&factory 0x4>;
132 };
133
134 &esw {
135         mediatek,portmap = <0x17>;
136 };
137
138 &wmac {
139         ralink,mtd-eeprom = <&factory 0>;
140 };
141
142 &ehci {
143         status = "okay";
144 };
145
146 &ohci {
147         status = "okay";
148 };