a40be00887f1857938d5c6abc58eaefff7c30390
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_glinet_vixmini_microuter.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_power_blue;
11 led-failsafe = &led_power_blue;
12 led-running = &led_power_blue;
13 led-upgrade = &led_power_blue;
14
15 label-mac-device = &ethernet;
16 };
17
18 chosen {
19 bootargs = "console=ttyS0,115200";
20 };
21
22 leds {
23 compatible = "gpio-leds";
24
25 led_power_blue: power {
26 label = "blue:power";
27 gpios = <&gpio 42 GPIO_ACTIVE_LOW>;
28 };
29
30 wlan {
31 label = "white:wlan";
32 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
33 linux,default-trigger = "phy0tpt";
34 };
35 };
36
37 keys {
38 compatible = "gpio-keys";
39
40 reset {
41 label = "reset";
42 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
43 linux,code = <KEY_RESTART>;
44 };
45 };
46 };
47
48 &state_default {
49 gpio {
50 groups = "wdt", "wled_an", "p1led_an";
51 function = "gpio";
52 };
53 };
54
55 &ethernet {
56 nvmem-cells = <&macaddr_factory_4>;
57 nvmem-cell-names = "mac-address";
58 };
59
60 &wmac {
61 status = "okay";
62
63 nvmem-cells = <&eeprom_factory_0>;
64 nvmem-cell-names = "eeprom";
65 };
66
67 &spi0 {
68 status = "okay";
69
70 flash@0 {
71 compatible = "jedec,spi-nor";
72 reg = <0>;
73 spi-max-frequency = <10000000>;
74
75 partitions: partitions {
76 compatible = "fixed-partitions";
77 #address-cells = <1>;
78 #size-cells = <1>;
79
80 partition@0 {
81 label = "u-boot";
82 reg = <0x0 0x30000>;
83 read-only;
84 };
85
86 partition@30000 {
87 label = "u-boot-env";
88 reg = <0x30000 0x10000>;
89 read-only;
90 };
91
92 factory: partition@40000 {
93 label = "factory";
94 reg = <0x40000 0x10000>;
95 read-only;
96
97 nvmem-layout {
98 compatible = "fixed-layout";
99 #address-cells = <1>;
100 #size-cells = <1>;
101
102 eeprom_factory_0: eeprom@0 {
103 reg = <0x0 0x400>;
104 };
105
106 macaddr_factory_4: macaddr@4 {
107 reg = <0x4 0x6>;
108 };
109 };
110 };
111
112 /*
113 * Firmware-partition size is model-specific
114 * due to different flash sizes.
115 */
116 firmware_part: partition@50000 {
117 compatible = "denx,uimage";
118 label = "firmware";
119 };
120 };
121 };
122 };