ramips: use DT trigger for 2G WiFi on ASUS RT-AC51U
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_storylink_sap-g3200u3.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 = "storylink,sap-g3200u3", "mediatek,mt7621-soc";
10 model = "STORYLiNK SAP-G3200U3";
11
12 chosen {
13 bootargs = "console=ttyS0,57600";
14 };
15
16 leds {
17 compatible = "gpio-leds";
18
19 usb {
20 label = "sap-g3200u3:green:usb";
21 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
22 trigger-sources = <&xhci_ehci_port1>, <&ehci_port2>;
23 linux,default-trigger = "usbport";
24 };
25 };
26
27 keys {
28 compatible = "gpio-keys";
29
30 reset {
31 label = "reset";
32 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
33 linux,code = <KEY_RESTART>;
34 };
35
36 rfkill {
37 label = "rfkill";
38 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
39 linux,code = <KEY_RFKILL>;
40 };
41 };
42 };
43
44 &spi0 {
45 status = "okay";
46
47 flash@0 {
48 compatible = "jedec,spi-nor";
49 reg = <0>;
50 spi-max-frequency = <10000000>;
51
52 partitions {
53 compatible = "fixed-partitions";
54 #address-cells = <1>;
55 #size-cells = <1>;
56
57 partition@0 {
58 label = "u-boot";
59 reg = <0x0 0x30000>;
60 read-only;
61 };
62
63 partition@30000 {
64 label = "u-boot-env";
65 reg = <0x30000 0x1000>;
66 read-only;
67 };
68
69 partition@31000 {
70 label = "config";
71 reg = <0x31000 0xf000>;
72 read-only;
73 };
74
75 factory: partition@40000 {
76 label = "factory";
77 reg = <0x40000 0x10000>;
78 read-only;
79 };
80
81 partition@50000 {
82 compatible = "denx,uimage";
83 label = "firmware";
84 reg = <0x50000 0x7b0000>;
85 };
86 };
87 };
88 };
89
90 &pcie {
91 status = "okay";
92 };
93
94 &pcie0 {
95 mt76@0,0 {
96 reg = <0x0000 0 0 0 0>;
97 mediatek,mtd-eeprom = <&factory 0x8000>;
98 ieee80211-freq-limit = <5000000 6000000>;
99 };
100 };
101
102 &pcie1 {
103 mt76@0,0 {
104 reg = <0x0000 0 0 0 0>;
105 mediatek,mtd-eeprom = <&factory 0x0000>;
106 ieee80211-freq-limit = <2400000 2500000>;
107 };
108 };
109
110 &gmac0 {
111 mtd-mac-address = <&factory 0xe006>;
112 };
113
114 &switch0 {
115 ports {
116 port@0 {
117 status = "okay";
118 label = "lan1";
119 };
120
121 port@1 {
122 status = "okay";
123 label = "lan2";
124 };
125
126 port@2 {
127 status = "okay";
128 label = "lan3";
129 };
130
131 port@3 {
132 status = "okay";
133 label = "lan4";
134 };
135
136 port@4 {
137 status = "okay";
138 label = "wan";
139 mtd-mac-address = <&factory 0xe006>;
140 mtd-mac-address-increment = <1>;
141 };
142 };
143 };
144
145 &state_default {
146 gpio {
147 groups = "uart3", "jtag";
148 function = "gpio";
149 };
150 };