ramips: improve Xiaomi mi-mini indications
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_netgear_r6xxx.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;
11 led-failsafe = &led_power;
12 led-running = &led_power;
13 led-upgrade = &led_power;
14 };
15
16 keys {
17 compatible = "gpio-keys";
18
19 reset {
20 label = "reset";
21 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
22 linux,code = <KEY_RESTART>;
23 };
24 };
25
26 leds {
27 compatible = "gpio-leds";
28
29 lan {
30 label = "green:lan";
31 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
32 };
33
34 led_power: power {
35 label = "green:power";
36 gpios = <&gpio 43 GPIO_ACTIVE_LOW>;
37 };
38
39 wlan2g_green {
40 label = "green:wlan2g";
41 gpios = <&gpio 42 GPIO_ACTIVE_LOW>;
42 linux,default-trigger = "phy0tpt";
43 };
44
45 wlan2g_orange {
46 label = "orange:wlan2g";
47 gpios = <&gpio 41 GPIO_ACTIVE_LOW>;
48 };
49
50 wan_green {
51 label = "green:wan";
52 gpios = <&gpio 40 GPIO_ACTIVE_LOW>;
53 };
54
55 wan_orange {
56 label = "orange:wan";
57 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
58 };
59 };
60 };
61
62 &spi0 {
63 status = "okay";
64
65 flash@0 {
66 compatible = "jedec,spi-nor";
67 reg = <0>;
68 spi-max-frequency = <86000000>;
69 m25p,fast-read;
70
71 partitions: partitions {
72 compatible = "fixed-partitions";
73 #address-cells = <1>;
74 #size-cells = <1>;
75
76 partition@0 {
77 label = "u-boot";
78 reg = <0x0 0x40000>;
79 read-only;
80 };
81
82 factory: partition@40000 {
83 label = "factory";
84 reg = <0x40000 0x20000>;
85 read-only;
86 };
87
88 partition@60000 {
89 label = "nvram";
90 reg = <0x60000 0x30000>;
91 read-only;
92 };
93 };
94 };
95 };
96
97 &wmac {
98 status = "okay";
99
100 mediatek,mtd-eeprom = <&factory 0x0>;
101 };
102
103 &ethernet {
104 nvmem-cells = <&macaddr_factory_4>;
105 nvmem-cell-names = "mac-address";
106 };
107
108 &pcie {
109 status = "okay";
110 };
111
112 &pcie0 {
113 wifi5: wifi@0,0 {
114 reg = <0x0000 0 0 0 0>;
115 mediatek,mtd-eeprom = <&factory 0x8000>;
116 ieee80211-freq-limit = <5000000 6000000>;
117 };
118 };
119
120 &factory {
121 compatible = "nvmem-cells";
122 #address-cells = <1>;
123 #size-cells = <1>;
124
125 macaddr_factory_4: macaddr@4 {
126 reg = <0x4 0x6>;
127 };
128 };