ramips: add support for ALFA Network Quad-E4G
[oweals/openwrt.git] / target / linux / ramips / dts / mt7628an_glinet_vixmini.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include "mt7628an.dtsi"
5
6 #include <dt-bindings/gpio/gpio.h>
7 #include <dt-bindings/input/input.h>
8
9 /{
10         compatible = "glinet,vixmini", "mediatek,mt7628an-soc";
11         model = "GL.iNet VIXMINI";
12
13         aliases {
14                 led-boot = &led_power;
15                 led-failsafe = &led_power;
16                 led-running = &led_power;
17                 led-upgrade = &led_power;
18         };
19
20         chosen {
21                 bootargs = "console=ttyS0,115200";
22         };
23
24         leds {
25                 compatible = "gpio-leds";
26
27                 led_power: power {
28                         label = "vixmini:blue:power";
29                         default-state = "on";
30                         gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
31                 };
32
33                 wlan {
34                         label = "vixmini:white:wlan";
35                         gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
36                         linux,default-trigger = "phy0tpt";
37                 };
38         };
39
40         keys {
41                 compatible = "gpio-keys";
42
43                 reset {
44                         label = "reset";
45                         gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
46                         linux,code = <KEY_RESTART>;
47                 };
48         };
49 };
50
51 &pinctrl {
52         state_default: pinctrl0 {
53                 gpio {
54                         ralink,group = "wdt", "wled_an", "p1led_an";
55                         ralink,function = "gpio";
56                 };
57         };
58 };
59
60 &ethernet {
61         mtd-mac-address = <&factory 0x4>;
62 };
63
64 &wmac {
65         status = "okay";
66 };
67
68 &spi0 {
69         status = "okay";
70
71         flash@0 {
72                 compatible = "jedec,spi-nor";
73                 reg = <0>;
74                 spi-max-frequency = <10000000>;
75
76                 partitions {
77                         compatible = "fixed-partitions";
78                         #address-cells = <1>;
79                         #size-cells = <1>;
80
81                         partition@0 {
82                                 label = "u-boot";
83                                 reg = <0x0 0x30000>;
84                                 read-only;
85                         };
86
87                         partition@30000 {
88                                 label = "u-boot-env";
89                                 reg = <0x30000 0x10000>;
90                                 read-only;
91                         };
92
93                         factory: partition@40000 {
94                                 label = "factory";
95                                 reg = <0x40000 0x10000>;
96                                 read-only;
97                         };
98
99                         partition@50000 {
100                                 compatible = "denx,uimage";
101                                 label = "firmware";
102                                 reg = <0x50000 0x7b0000>;
103                         };
104                 };
105         };
106 };