ath79: update WA/XC devices UBNT_VERSION to 8.7.4
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / ar9331_glinet_gl-mifi.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9331.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
8
9 / {
10 compatible = "glinet,gl-mifi", "qca,ar9331";
11 model = "GL.iNet GL-MiFi";
12
13 aliases {
14 label-mac-device = &eth0;
15 };
16
17 leds {
18 compatible = "gpio-leds";
19
20 wlan {
21 function = LED_FUNCTION_WLAN;
22 color = <LED_COLOR_ID_GREEN>;
23 gpios = <&gpio 1 GPIO_ACTIVE_HIGH>;
24 linux,default-trigger = "phy0tpt";
25 };
26
27 lan {
28 function = LED_FUNCTION_LAN;
29 color = <LED_COLOR_ID_GREEN>;
30 gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
31 };
32
33 wan {
34 function = LED_FUNCTION_WAN;
35 color = <LED_COLOR_ID_GREEN>;
36 gpios = <&gpio 27 GPIO_ACTIVE_HIGH>;
37 };
38
39 3g4g {
40 label = "green:3g4g";
41 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
42 };
43 };
44
45 keys {
46 compatible = "gpio-keys";
47
48 reset {
49 label = "reset";
50 linux,code = <KEY_RESTART>;
51 gpios = <&gpio 11 GPIO_ACTIVE_HIGH>;
52 debounce-interval = <60>;
53 };
54 };
55
56 reg_usb_vbus: reg_usb_vbus {
57 compatible = "regulator-fixed";
58 regulator-name = "usb_vbus";
59 regulator-min-microvolt = <5000000>;
60 regulator-max-microvolt = <5000000>;
61 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
62 };
63
64 gpio-export {
65 compatible = "gpio-export";
66
67 minipcie {
68 gpio-export,name = "minipcie";
69 gpio-export,output = <0>;
70 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
71 };
72 };
73 };
74
75 &usb {
76 status = "okay";
77
78 dr_mode = "host";
79 vbus-supply = <&reg_usb_vbus>;
80 };
81
82 &usb_phy {
83 status = "okay";
84 };
85
86 &spi {
87 status = "okay";
88
89 flash@0 {
90 compatible = "jedec,spi-nor";
91 spi-max-frequency = <33000000>;
92 reg = <0>;
93
94 partitions {
95 compatible = "fixed-partitions";
96 #address-cells = <1>;
97 #size-cells = <1>;
98
99 partition@0 {
100 label = "u-boot";
101 reg = <0x000000 0x040000>;
102 read-only;
103 };
104
105 partition@40000 {
106 label = "u-boot-env";
107 reg = <0x040000 0x010000>;
108 };
109
110 partition@50000 {
111 compatible = "denx,uimage";
112 label = "firmware";
113 reg = <0x050000 0xfa0000>;
114 };
115
116 art: partition@ff0000 {
117 label = "art";
118 reg = <0xff0000 0x010000>;
119 read-only;
120
121 nvmem-layout {
122 compatible = "fixed-layout";
123 #address-cells = <1>;
124 #size-cells = <1>;
125
126 macaddr_art_0: macaddr@0 {
127 reg = <0x0 0x6>;
128 };
129 };
130 };
131 };
132 };
133 };
134
135 &eth0 {
136 status = "okay";
137
138 nvmem-cells = <&macaddr_art_0>;
139 nvmem-cell-names = "mac-address";
140
141 gmac-config {
142 device = <&gmac>;
143
144 switch-phy-addr-swap = <0>;
145 switch-phy-swap = <0>;
146 };
147 };
148
149 &eth1 {
150 status = "okay";
151
152 nvmem-cells = <&macaddr_art_0>;
153 nvmem-cell-names = "mac-address";
154 };
155
156 &wmac {
157 status = "okay";
158
159 mtd-cal-data = <&art 0x1000>;
160 };