kernel: mtdsplit_uimage: replace "netgear, uimage" parser
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar7240_netgear_wnr1000-v2.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar7240.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/mtd/partitions/uimage.h>
8
9 / {
10 compatible = "netgear,wnr1000-v2", "qca,ar7240";
11 model = "Netgear WNR1000 v2";
12
13 chosen {
14 bootargs = "console=ttyS0,115200n8";
15 };
16
17 aliases {
18 led-boot = &led_power_amber;
19 led-failsafe = &led_power_amber;
20 led-running = &led_power_green;
21 led-upgrade = &led_power_amber;
22 label-mac-device = &eth1;
23 };
24
25 ath9k-keys {
26 compatible = "gpio-keys-polled";
27 poll-interval = <20>;
28
29 wps {
30 label = "wps";
31 linux,code = <KEY_WPS_BUTTON>;
32 gpios = <&ath9k 6 GPIO_ACTIVE_LOW>;
33 debounce-interval = <60>;
34 };
35
36 reset {
37 label = "reset";
38 linux,code = <KEY_RESTART>;
39 gpios = <&ath9k 7 GPIO_ACTIVE_LOW>;
40 debounce-interval = <60>;
41 };
42
43 rfkill {
44 label = "rfkill";
45 linux,code = <KEY_RFKILL>;
46 gpios = <&ath9k 8 GPIO_ACTIVE_LOW>;
47 debounce-interval = <60>;
48 };
49 };
50
51 leds {
52 compatible = "gpio-leds";
53
54 pinctrl-names = "default";
55 pinctrl-0 = <&jtag_disable_pins &switch_led_disable_pins &clks_disable_pins>;
56
57 led_power_green: power_green {
58 label = "green:power";
59 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
60 };
61
62 led_power_amber: power_amber {
63 label = "amber:power";
64 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
65 default-state = "keep";
66 };
67
68 wan_green {
69 label = "green:wan";
70 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
71 };
72
73 wan_amber {
74 label = "amber:wan";
75 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
76 };
77
78 lan1_green {
79 label = "green:lan1";
80 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
81 };
82
83 lan1_amber {
84 label = "amber:lan1";
85 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
86 };
87
88 lan2_green {
89 label = "green:lan2";
90 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
91 };
92
93 lan2_amber {
94 label = "amber:lan2";
95 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
96 };
97
98 lan3_green {
99 label = "green:lan3";
100 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
101 };
102
103 lan3_amber {
104 label = "amber:lan3";
105 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
106 };
107
108 lan4_green {
109 label = "green:lan4";
110 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
111 };
112
113 lan4_amber {
114 label = "amber:lan4";
115 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
116 };
117 };
118
119 ath9k-leds {
120 compatible = "gpio-leds";
121
122 wps_green {
123 label = "green:wps";
124 gpios = <&ath9k 5 GPIO_ACTIVE_LOW>;
125 };
126
127 wlan_blue {
128 label = "blue:wlan";
129 gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
130 linux,default-trigger = "phy0tpt";
131 };
132 };
133 };
134
135 &spi {
136 status = "okay";
137
138 flash@0 {
139 compatible = "jedec,spi-nor";
140 reg = <0>;
141 spi-max-frequency = <25000000>;
142
143 partitions {
144 compatible = "fixed-partitions";
145 #address-cells = <1>;
146 #size-cells = <1>;
147
148 partition@0 {
149 label = "u-boot";
150 reg = <0x0 0x40000>;
151 read-only;
152 };
153
154 partition@40000 {
155 label = "u-boot-env";
156 reg = <0x40000 0x10000>;
157 };
158
159 partition@50000 {
160 label = "firmware";
161 reg = <0x50000 0x3a0000>;
162 compatible = "openwrt,uimage", "denx,uimage";
163 openwrt,ih-magic = <0x31303031>;
164 openwrt,ih-type = <IH_TYPE_FILESYSTEM>;
165 };
166
167 art: partition@3f0000 {
168 label = "art";
169 reg = <0x3f0000 0x10000>;
170 read-only;
171 };
172 };
173 };
174 };
175
176 &eth0 {
177 mtd-mac-address = <&art 0x0>;
178 };
179
180 &eth1 {
181 status = "okay";
182
183 mtd-mac-address = <&art 0x6>;
184 };
185
186 &pcie {
187 status = "okay";
188
189 ath9k: wifi@0,0 {
190 compatible = "pci168c,002b";
191 reg = <0x0000 0 0 0 0>;
192 mtd-mac-address = <&art 0x0>;
193 mtd-mac-address-increment = <1>;
194 qca,no-eeprom;
195 #gpio-cells = <2>;
196 gpio-controller;
197 };
198 };
199
200 &uart {
201 status = "okay";
202 };