kernel: bump 4.9 to 4.9.65
[oweals/openwrt.git] / target / linux / ramips / dts / HLKRM04.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 = "hilink,hlk-rm04", "ralink,rt5350-soc";
10         model = "HILINK HLK-RM04";
11
12         memory@0 {
13                 device_type = "memory";
14                 reg = <0x0 0x1000000>;
15         };
16
17         chosen {
18                 bootargs = "console=ttyS1,57600";
19         };
20
21         gpio-export {
22                 compatible = "gpio-export";
23                 #size-cells = <0>;
24
25                 /* I2C */
26                 gpio1 {
27                         /* I2C_I2C_SD */
28                         gpio-export,name = "hlk-rm04:gpio0";
29                         gpio-export,direction_may_change = <1>;
30                         gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
31                 };
32                 gpio2 {
33                         /* I2C_I2C_SCLK */
34                         gpio-export,name = "hlk-rm04:gpio1";
35                         gpio-export,direction_may_change = <1>;
36                         gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
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                 reset {
46                         label = "reset";
47                         gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
48                         linux,code = <KEY_RESTART>;
49                 };
50                 wps {
51                         label = "wps";
52                         gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
53                         linux,code = <KEY_WPS_BUTTON>;
54                 };
55         };
56 };
57
58 &uart {
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                 spi-max-frequency = <10000000>;
71
72                 partition@0 {
73                         label = "u-boot";
74                         reg = <0x0 0x30000>;
75                         read-only;
76                 };
77
78                 partition@30000 {
79                         label = "u-boot-env";
80                         reg = <0x30000 0x10000>;
81                         read-only;
82                 };
83
84                 factory: partition@40000 {
85                         label = "factory";
86                         reg = <0x40000 0x10000>;
87                         read-only;
88                 };
89
90                 partition@50000 {
91                         label = "firmware";
92                         reg = <0x50000 0x3b0000>;
93                 };
94         };
95 };
96
97 &pinctrl {
98         state_default: pinctrl0 {
99                 gpio {
100                         ralink,group = "i2c", "jtag";
101                         ralink,function = "gpio";
102                 };
103
104                 uartf_gpio {
105                         ralink,group = "uartf";
106                         ralink,function = "gpio uartf";
107                 };
108         };
109 };
110
111 &ethernet {
112         mtd-mac-address = <&factory 0x4>;
113 };
114
115 &wmac {
116         ralink,mtd-eeprom = <&factory 0>;
117 };
118
119 &ehci {
120         status = "okay";
121 };
122
123 &ohci {
124         status = "okay";
125 };