ramips: add support for EnGenius ESR600
[oweals/openwrt.git] / target / linux / ramips / dts / mt7620a_lenovo_newifi-y1.dtsi
1 #include "mt7620a.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7         compatible = "lenovo,newifi-y1", "ralink,mt7620a-soc";
8
9         chosen {
10                 bootargs = "console=ttyS0,115200";
11         };
12
13         keys {
14                 compatible = "gpio-keys-polled";
15                 poll-interval = <20>;
16
17                 reset {
18                         label = "reset";
19                         gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
20                         linux,code = <KEY_RESTART>;
21                 };
22         };
23 };
24
25 &gpio0 {
26         status = "okay";
27 };
28
29 &gpio2 {
30         status = "okay";
31 };
32
33 &gpio3 {
34         status = "okay";
35 };
36
37 &spi0 {
38         status = "okay";
39
40         m25p80@0 {
41                 compatible = "jedec,spi-nor";
42                 reg = <0>;
43                 spi-max-frequency = <10000000>;
44
45                 partitions {
46                         compatible = "fixed-partitions";
47                         #address-cells = <1>;
48                         #size-cells = <1>;
49
50                         partition@0 {
51                                 label = "u-boot";
52                                 reg = <0x0 0x30000>;
53                                 read-only;
54                         };
55
56                         partition@30000 {
57                                 label = "u-boot-env";
58                                 reg = <0x30000 0x10000>;
59                                 read-only;
60                         };
61
62                         factory: partition@40000 {
63                                 label = "factory";
64                                 reg = <0x40000 0x10000>;
65                                 read-only;
66                         };
67
68                         partition@50000 {
69                                 compatible = "denx,uimage";
70                                 label = "firmware";
71                                 reg = <0x50000 0xfb0000>;
72                         };
73                 };
74         };
75 };
76
77 &ehci {
78         status = "okay";
79 };
80
81 &ohci {
82         status = "okay";
83 };
84
85 &pcie {
86         status = "okay";
87 };
88
89 &pcie0 {
90         mt76@0,0 {
91                 reg = <0x0000 0 0 0 0>;
92                 mediatek,mtd-eeprom = <&factory 0x8000>;
93                 ieee80211-freq-limit = <5000000 6000000>;
94         };
95 };
96
97 &wmac {
98         ralink,mtd-eeprom = <&factory 0>;
99         pinctrl-names = "default";
100         pinctrl-0 = <&pa_pins>;
101 };
102
103 &pinctrl {
104         state_default: pinctrl0 {
105                 gpio {
106                         ralink,group = "uartf", "wled", "nd_sd";
107                         ralink,function = "gpio";
108                 };
109         };
110 };