ath79: update WA/XC devices UBNT_VERSION to 8.7.4
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / ar7241_netgear_wnr2200.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar7241.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
8 #include <dt-bindings/mtd/partitions/uimage.h>
9
10 / {
11 chosen {
12 bootargs = "console=ttyS0,115200n8";
13 };
14
15 aliases {
16 led-boot = &led_power_amber;
17 led-failsafe = &led_power_amber;
18 led-running = &led_power_green;
19 led-upgrade = &led_power_amber;
20 };
21
22 ath9k-keys {
23 compatible = "gpio-keys-polled";
24 poll-interval = <20>;
25
26 wps {
27 label = "wps";
28 linux,code = <KEY_WPS_BUTTON>;
29 gpios = <&ath9k 5 GPIO_ACTIVE_LOW>;
30 debounce-interval = <60>;
31 };
32
33 reset {
34 label = "reset";
35 linux,code = <KEY_RESTART>;
36 gpios = <&ath9k 6 GPIO_ACTIVE_LOW>;
37 debounce-interval = <60>;
38 };
39
40 rfkill {
41 label = "rfkill";
42 linux,code = <KEY_RFKILL>;
43 gpios = <&ath9k 3 GPIO_ACTIVE_LOW>;
44 debounce-interval = <60>;
45 };
46 };
47
48 leds {
49 compatible = "gpio-leds";
50
51 pinctrl-names = "default";
52 pinctrl-0 = <&jtag_disable_pins &switch_led_disable_pins &clks_disable_pins>;
53
54 wan_green {
55 function = LED_FUNCTION_WAN;
56 color = <LED_COLOR_ID_GREEN>;
57 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
58 };
59
60 wan_amber {
61 function = LED_FUNCTION_WAN;
62 color = <LED_COLOR_ID_AMBER>;
63 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
64 };
65
66 lan1_green {
67 label = "green:lan1";
68 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
69 };
70
71 lan1_amber {
72 label = "amber:lan1";
73 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
74 };
75
76 lan2_green {
77 label = "green:lan2";
78 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
79 };
80
81 lan2_amber {
82 label = "amber:lan2";
83 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
84 };
85
86 lan3_green {
87 label = "green:lan3";
88 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
89 };
90
91 lan3_amber {
92 label = "amber:lan3";
93 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
94 };
95
96 lan4_green {
97 label = "green:lan4";
98 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
99 };
100
101 lan4_amber {
102 label = "amber:lan4";
103 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
104 };
105
106 wps_green {
107 function = LED_FUNCTION_WPS;
108 color = <LED_COLOR_ID_GREEN>;
109 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
110 };
111
112 usb_green {
113 function = LED_FUNCTION_USB;
114 color = <LED_COLOR_ID_GREEN>;
115 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
116 trigger-sources = <&hub_port>;
117 linux,default-trigger = "usbport";
118 };
119 };
120
121 ath9k-leds {
122 compatible = "gpio-leds";
123
124 led_power_green: power_green {
125 function = LED_FUNCTION_POWER;
126 color = <LED_COLOR_ID_GREEN>;
127 gpios = <&ath9k 2 GPIO_ACTIVE_LOW>;
128 };
129
130 led_power_amber: power_amber {
131 function = LED_FUNCTION_POWER;
132 color = <LED_COLOR_ID_AMBER>;
133 gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
134 default-state = "keep";
135 };
136
137 wlan_blue {
138 function = LED_FUNCTION_WLAN;
139 color = <LED_COLOR_ID_BLUE>;
140 gpios = <&ath9k 0 GPIO_ACTIVE_LOW>;
141 linux,default-trigger = "phy0tpt";
142 };
143 };
144 };
145
146 &spi {
147 status = "okay";
148
149 flash@0 {
150 compatible = "jedec,spi-nor";
151 reg = <0>;
152 spi-max-frequency = <25000000>;
153
154 partitions: partitions {
155 compatible = "fixed-partitions";
156 #address-cells = <1>;
157 #size-cells = <1>;
158 };
159 };
160 };
161
162 &eth0 {
163 status = "okay";
164 };
165
166 &eth1 {
167 compatible = "qca,ar7241-eth", "syscon", "simple-mfd";
168 };
169
170 &pcie {
171 status = "okay";
172
173 ath9k: wifi@0,0 {
174 compatible = "pci168c,002e";
175 reg = <0x0000 0 0 0 0>;
176 qca,no-eeprom;
177 #gpio-cells = <2>;
178 gpio-controller;
179
180 usb_power {
181 gpio-hog;
182 line-name = "netgear:power:usb";
183 gpios = <4 GPIO_ACTIVE_HIGH>;
184 output-high;
185 };
186 };
187 };
188
189 &usb_phy {
190 status = "okay";
191 };
192
193 &usb {
194 status = "okay";
195 };