I'm working on a use case that SoC w/ only one ethnet port(eth1) connect to a SJA1105 switch chip. As mentioned in linux kernel documents, the DSA mechanism will take eth1 as management port and have limitation to open socket directly on this interface. For Vlan-unware case, I use the reference configuration from document as below:
ip link set eth1 up
ip link set swp1 up
ip link set swp2 up
ip link add name br0 type bridge
ip link set dev swp1 master br0
ip link set dev swp2 master br0
ip addr add 172.20.1.129/24 dev br0
ip link set dev br0 up
it works fine. I can use br0 as replacement of eth1 to access hosts behind swpN. But when it comes w/ Vlan-aware case, it doesn't work out. I still use the configuration revised from reference:
ip link set eth1 up
ip link set swp1 up
ip link set swp2 up
ip link add name br0 type bridge
ip link set dev br0 type bridge vlan_filtering 1
ip link set dev swp1 master br0
ip link set dev swp2 master br0
bridge vlan add dev swp1 vid 100 pvid untagged
bridge vlan add dev swp2 vid 100 pvid untagged
bridge vlan add dev br0 vid 100 pvid untagged self
ip addr add 172.20.1.129/24 dev br0
ip link set dev br0 up
The hosts behind swpN still can ping each other but can not ping br0, vice versa. tcpdump capture no packets on br0, but found packets on eth1.
is there anything wrong in my configuration? or any other methods to achieve the goal that cpu daemon can communicate w/ the hosts behind swpN w/ Vlan tagged in such setup?
Will really appreciate if any comments, thanks in advance!