98d132e891f1ab19b09968b4bc543d21a6bc992e
[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 nvmem-layout {
88 compatible = "fixed-layout";
89 #address-cells = <1>;
90 #size-cells = <1>;
91
92 eeprom_factory_0: eeprom@0 {
93 reg = <0x0 0x400>;
94 };
95
96 eeprom_factory_8000: eeprom@8000 {
97 reg = <0x8000 0x200>;
98 };
99
100 macaddr_factory_4: macaddr@4 {
101 compatible = "mac-base";
102 reg = <0x4 0x6>;
103 #nvmem-cell-cells = <1>;
104 };
105 };
106 };
107
108 partition@60000 {
109 label = "nvram";
110 reg = <0x60000 0x30000>;
111 read-only;
112 };
113 };
114 };
115 };
116
117 &wmac {
118 status = "okay";
119
120 nvmem-cells = <&eeprom_factory_0>;
121 nvmem-cell-names = "eeprom";
122 };
123
124 &ethernet {
125 nvmem-cells = <&macaddr_factory_4 0>;
126 nvmem-cell-names = "mac-address";
127 };
128
129 &pcie {
130 status = "okay";
131 };
132
133 &pcie0 {
134 wifi5: wifi@0,0 {
135 reg = <0x0000 0 0 0 0>;
136 nvmem-cells = <&eeprom_factory_8000>;
137 nvmem-cell-names = "eeprom";
138 ieee80211-freq-limit = <5000000 6000000>;
139 };
140 };