9d7dcd84028396f9ead988a991454fb950a3dcd7
[openwrt/openwrt.git] /
1 From c00df1018791185ea398f78af415a2a0aaa0c79c Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= <noltari@gmail.com>
3 Date: Sat, 14 Jun 2025 09:59:59 +0200
4 Subject: [PATCH] net: dsa: b53: fix b53_imp_vlan_setup for BCM5325
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 CPU port should be B53_CPU_PORT instead of B53_CPU_PORT_25 for
10 B53_PVLAN_PORT_MASK register.
11
12 Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
13 Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
14 Link: https://patch.msgid.link/20250614080000.1884236-14-noltari@gmail.com
15 Signed-off-by: Jakub Kicinski <kuba@kernel.org>
16 ---
17 drivers/net/dsa/b53/b53_common.c | 4 ++++
18 1 file changed, 4 insertions(+)
19
20 --- a/drivers/net/dsa/b53/b53_common.c
21 +++ b/drivers/net/dsa/b53/b53_common.c
22 @@ -543,6 +543,10 @@ void b53_imp_vlan_setup(struct dsa_switc
23 unsigned int i;
24 u16 pvlan;
25
26 + /* BCM5325 CPU port is at 8 */
27 + if ((is5325(dev) || is5365(dev)) && cpu_port == B53_CPU_PORT_25)
28 + cpu_port = B53_CPU_PORT;
29 +
30 /* Enable the IMP port to be in the same VLAN as the other ports
31 * on a per-port basis such that we only have Port i and IMP in
32 * the same VLAN.