Skip to content

Commit 2900083

Browse files
arinc9ffainelli
authored andcommitted
ARM: dts: BCM5301X: Add DT for ASUS RT-AC3100
ASUS RT-AC3100 is ASUS RT-AC88U without the external switch. Move the shared bindings to bcm47094-asus-rt-ac3100.dtsi. Remove the fixed-link node on port@7 as commit ba4aebc ("ARM: dts: BCM5301X: Describe switch ports in the main DTS") states it's not necessary. Replace the copyright notice with an author notice. Rename the model name from Asus to ASUS on bcm47094-asus-rt-ac88u.dts. Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20230803071454.5902-2-arinc.unal@arinc9.com Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
1 parent d90d0fa commit 2900083

File tree

4 files changed

+190
-152
lines changed

4 files changed

+190
-152
lines changed

arch/arm/boot/dts/broadcom/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \
7070
bcm4709-netgear-r7000.dtb \
7171
bcm4709-netgear-r8000.dtb \
7272
bcm4709-tplink-archer-c9-v1.dtb \
73+
bcm47094-asus-rt-ac3100.dtb \
7374
bcm47094-asus-rt-ac88u.dtb \
7475
bcm47094-dlink-dir-885l.dtb \
7576
bcm47094-dlink-dir-890l.dtb \
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2+
/*
3+
* Author: Arınç ÜNAL <arinc.unal@arinc9.com>
4+
*/
5+
6+
/dts-v1/;
7+
8+
#include "bcm47094-asus-rt-ac3100.dtsi"
9+
10+
/ {
11+
compatible = "asus,rt-ac3100", "brcm,bcm47094", "brcm,bcm4708";
12+
model = "ASUS RT-AC3100";
13+
14+
nvram@1c080000 {
15+
et0macaddr: et0macaddr {
16+
};
17+
};
18+
};
19+
20+
&gmac0 {
21+
nvmem-cells = <&et0macaddr>;
22+
nvmem-cell-names = "mac-address";
23+
};
Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2+
/*
3+
* Author: Arınç ÜNAL <arinc.unal@arinc9.com>
4+
*/
5+
6+
#include "bcm47094.dtsi"
7+
#include "bcm5301x-nand-cs0-bch8.dtsi"
8+
9+
/ {
10+
chosen {
11+
bootargs = "earlycon";
12+
};
13+
14+
memory@0 {
15+
device_type = "memory";
16+
reg = <0x00000000 0x08000000>,
17+
<0x88000000 0x18000000>;
18+
};
19+
20+
nvram@1c080000 {
21+
compatible = "brcm,nvram";
22+
reg = <0x1c080000 0x00180000>;
23+
};
24+
25+
leds {
26+
compatible = "gpio-leds";
27+
28+
led-power {
29+
label = "white:power";
30+
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
31+
linux,default-trigger = "default-on";
32+
};
33+
34+
led-wan-red {
35+
label = "red:wan";
36+
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
37+
};
38+
39+
led-lan {
40+
label = "white:lan";
41+
gpios = <&chipcommon 21 GPIO_ACTIVE_LOW>;
42+
};
43+
44+
led-usb2 {
45+
label = "white:usb2";
46+
gpios = <&chipcommon 16 GPIO_ACTIVE_LOW>;
47+
trigger-sources = <&ehci_port2>;
48+
linux,default-trigger = "usbport";
49+
};
50+
51+
led-usb3 {
52+
label = "white:usb3";
53+
gpios = <&chipcommon 17 GPIO_ACTIVE_LOW>;
54+
trigger-sources = <&ehci_port1>, <&xhci_port1>;
55+
linux,default-trigger = "usbport";
56+
};
57+
58+
led-wps {
59+
label = "white:wps";
60+
gpios = <&chipcommon 19 GPIO_ACTIVE_LOW>;
61+
};
62+
};
63+
64+
gpio-keys {
65+
compatible = "gpio-keys";
66+
67+
button-wps {
68+
label = "WPS";
69+
linux,code = <KEY_WPS_BUTTON>;
70+
gpios = <&chipcommon 20 GPIO_ACTIVE_LOW>;
71+
};
72+
73+
button-reset {
74+
label = "Reset";
75+
linux,code = <KEY_RESTART>;
76+
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
77+
};
78+
79+
button-wifi {
80+
label = "Wi-Fi";
81+
linux,code = <KEY_RFKILL>;
82+
gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>;
83+
};
84+
85+
button-led {
86+
label = "Backlight";
87+
linux,code = <KEY_BRIGHTNESS_ZERO>;
88+
gpios = <&chipcommon 4 GPIO_ACTIVE_LOW>;
89+
};
90+
};
91+
};
92+
93+
&srab {
94+
compatible = "brcm,bcm53012-srab", "brcm,bcm5301x-srab";
95+
status = "okay";
96+
97+
ports {
98+
port@0 {
99+
label = "lan4";
100+
};
101+
102+
port@1 {
103+
label = "lan3";
104+
};
105+
106+
port@2 {
107+
label = "lan2";
108+
};
109+
110+
port@3 {
111+
label = "lan1";
112+
};
113+
114+
port@4 {
115+
label = "wan";
116+
};
117+
118+
port@5 {
119+
label = "cpu";
120+
};
121+
122+
port@7 {
123+
label = "cpu";
124+
};
125+
126+
port@8 {
127+
label = "cpu";
128+
};
129+
};
130+
};
131+
132+
&usb2 {
133+
vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
134+
};
135+
136+
&usb3_phy {
137+
status = "okay";
138+
};
139+
140+
&nandcs {
141+
partitions {
142+
compatible = "fixed-partitions";
143+
#address-cells = <1>;
144+
#size-cells = <1>;
145+
146+
partition@0 {
147+
label = "boot";
148+
reg = <0x00000000 0x00080000>;
149+
read-only;
150+
};
151+
152+
partition@80000 {
153+
label = "nvram";
154+
reg = <0x00080000 0x00180000>;
155+
};
156+
157+
partition@200000 {
158+
label = "firmware";
159+
reg = <0x00200000 0x07e00000>;
160+
compatible = "brcm,trx";
161+
};
162+
};
163+
};
Lines changed: 3 additions & 152 deletions
Original file line numberDiff line numberDiff line change
@@ -1,102 +1,21 @@
11
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
22
/*
3-
* Copyright (C) 2021-2022 Arınç ÜNAL <arinc.unal@arinc9.com>
3+
* Author: Arınç ÜNAL <arinc.unal@arinc9.com>
44
*/
55

66
/dts-v1/;
77

8-
#include "bcm47094.dtsi"
9-
#include "bcm5301x-nand-cs0-bch8.dtsi"
8+
#include "bcm47094-asus-rt-ac3100.dtsi"
109

1110
/ {
1211
compatible = "asus,rt-ac88u", "brcm,bcm47094", "brcm,bcm4708";
13-
model = "Asus RT-AC88U";
14-
15-
chosen {
16-
bootargs = "earlycon";
17-
};
18-
19-
memory@0 {
20-
device_type = "memory";
21-
reg = <0x00000000 0x08000000>,
22-
<0x88000000 0x18000000>;
23-
};
12+
model = "ASUS RT-AC88U";
2413

2514
nvram@1c080000 {
26-
compatible = "brcm,nvram";
27-
reg = <0x1c080000 0x00180000>;
28-
2915
et1macaddr: et1macaddr {
3016
};
3117
};
3218

33-
leds {
34-
compatible = "gpio-leds";
35-
36-
led-power {
37-
label = "white:power";
38-
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
39-
linux,default-trigger = "default-on";
40-
};
41-
42-
led-wan-red {
43-
label = "red:wan";
44-
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
45-
};
46-
47-
led-lan {
48-
label = "white:lan";
49-
gpios = <&chipcommon 21 GPIO_ACTIVE_LOW>;
50-
};
51-
52-
led-usb2 {
53-
label = "white:usb2";
54-
gpios = <&chipcommon 16 GPIO_ACTIVE_LOW>;
55-
trigger-sources = <&ehci_port2>;
56-
linux,default-trigger = "usbport";
57-
};
58-
59-
led-usb3 {
60-
label = "white:usb3";
61-
gpios = <&chipcommon 17 GPIO_ACTIVE_LOW>;
62-
trigger-sources = <&ehci_port1>, <&xhci_port1>;
63-
linux,default-trigger = "usbport";
64-
};
65-
66-
led-wps {
67-
label = "white:wps";
68-
gpios = <&chipcommon 19 GPIO_ACTIVE_LOW>;
69-
};
70-
};
71-
72-
gpio-keys {
73-
compatible = "gpio-keys";
74-
75-
button-wps {
76-
label = "WPS";
77-
linux,code = <KEY_WPS_BUTTON>;
78-
gpios = <&chipcommon 20 GPIO_ACTIVE_LOW>;
79-
};
80-
81-
button-reset {
82-
label = "Reset";
83-
linux,code = <KEY_RESTART>;
84-
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
85-
};
86-
87-
button-wifi {
88-
label = "Wi-Fi";
89-
linux,code = <KEY_RFKILL>;
90-
gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>;
91-
};
92-
93-
button-led {
94-
label = "Backlight";
95-
linux,code = <KEY_BRIGHTNESS_ZERO>;
96-
gpios = <&chipcommon 4 GPIO_ACTIVE_LOW>;
97-
};
98-
};
99-
10019
switch {
10120
compatible = "realtek,rtl8365mb";
10221
/* 7 = MDIO (has input reads), 6 = MDC (clock, output only) */
@@ -175,31 +94,9 @@
17594
};
17695

17796
&srab {
178-
compatible = "brcm,bcm53012-srab", "brcm,bcm5301x-srab";
179-
status = "okay";
18097
dsa,member = <0 0>;
18198

18299
ports {
183-
port@0 {
184-
label = "lan4";
185-
};
186-
187-
port@1 {
188-
label = "lan3";
189-
};
190-
191-
port@2 {
192-
label = "lan2";
193-
};
194-
195-
port@3 {
196-
label = "lan1";
197-
};
198-
199-
port@4 {
200-
label = "wan";
201-
};
202-
203100
sw0_p5: port@5 {
204101
/delete-property/ethernet;
205102

@@ -212,19 +109,6 @@
212109
pause;
213110
};
214111
};
215-
216-
port@7 {
217-
label = "cpu";
218-
219-
fixed-link {
220-
speed = <1000>;
221-
full-duplex;
222-
};
223-
};
224-
225-
port@8 {
226-
label = "cpu";
227-
};
228112
};
229113
};
230114

@@ -236,36 +120,3 @@
236120
nvmem-cells = <&et1macaddr>;
237121
nvmem-cell-names = "mac-address";
238122
};
239-
240-
&usb2 {
241-
vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
242-
};
243-
244-
&usb3_phy {
245-
status = "okay";
246-
};
247-
248-
&nandcs {
249-
partitions {
250-
compatible = "fixed-partitions";
251-
#address-cells = <1>;
252-
#size-cells = <1>;
253-
254-
partition@0 {
255-
label = "boot";
256-
reg = <0x00000000 0x00080000>;
257-
read-only;
258-
};
259-
260-
partition@80000 {
261-
label = "nvram";
262-
reg = <0x00080000 0x00180000>;
263-
};
264-
265-
partition@200000 {
266-
label = "firmware";
267-
reg = <0x00200000 0x07e00000>;
268-
compatible = "brcm,trx";
269-
};
270-
};
271-
};

0 commit comments

Comments
 (0)