ramips: add support for XiaoYu XY-C5
[oweals/openwrt.git] / target / linux / ramips / dts / mt7621_zbtlink_zbt-we1326.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9         compatible = "zbtlink,zbt-we1326", "mediatek,mt7621-soc";
10         model = "ZBT-WE1326";
11
12         aliases {
13                 label-mac-device = &wifi1;
14         };
15
16         chosen {
17                 bootargs = "console=ttyS0,115200";
18         };
19
20         keys {
21                 compatible = "gpio-keys-polled";
22                 poll-interval = <20>;
23
24                 reset {
25                         label = "reset";
26                         gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
27                         linux,code = <KEY_RESTART>;
28                 };
29         };
30 };
31
32 &pinctrl {
33         state_default: pinctrl0 {
34                 gpio {
35                         ralink,group = "wdt";
36                         ralink,function = "gpio";
37                 };
38         };
39 };
40
41 &spi0 {
42         status = "okay";
43
44         m25p80@0 {
45                 compatible = "jedec,spi-nor";
46                 reg = <0>;
47                 spi-max-frequency = <10000000>;
48
49                 partitions {
50                         compatible = "fixed-partitions";
51                         #address-cells = <1>;
52                         #size-cells = <1>;
53
54                         partition@0 {
55                                 label = "u-boot";
56                                 reg = <0x0 0x30000>;
57                                 read-only;
58                         };
59
60                         partition@30000 {
61                                 label = "u-boot-env";
62                                 reg = <0x30000 0x10000>;
63                                 read-only;
64                         };
65
66                         factory: partition@40000 {
67                                 label = "factory";
68                                 reg = <0x40000 0x10000>;
69                                 read-only;
70                         };
71
72                         partition@50000 {
73                                 compatible = "denx,uimage";
74                                 label = "firmware";
75                                 reg = <0x50000 0xfb0000>;
76                         };
77                 };
78         };
79 };
80
81 &ethernet {
82         mtd-mac-address = <&factory 0xe000>;
83 };
84
85 &pcie {
86         status = "okay";
87 };
88
89 &pcie0 {
90         wifi0: 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 &pcie1 {
98         wifi1: mt76@0,0 {
99                 reg = <0x0000 0 0 0 0>;
100                 mediatek,mtd-eeprom = <&factory 0x0000>;
101                 ieee80211-freq-limit = <2400000 2500000>;
102         };
103 };
104
105 &sdhci {
106         status = "okay";
107 };