]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_switchdev: Allow port enslavement to a VLAN-unaware bridge
authorIdo Schimmel <idosch@mellanox.com>
Tue, 20 Feb 2018 07:45:12 +0000 (08:45 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 26 Feb 2018 16:12:26 +0000 (11:12 -0500)
commitf08466eb22302caa0d60264c6a0d92c67715405b
treef943275a51cdb90153ffd22aa8f73369eb9bf40a
parentef8f98e709a990a547fd80acf82c3e70b0b0e530
mlxsw: spectrum_switchdev: Allow port enslavement to a VLAN-unaware bridge

Up until now we only allowed VLAN devices to be put in a VLAN-unaware
bridge, but some users need the ability to enslave physical ports as
well.

This is achieved by mapping the port and VID 1 to the bridge's vFID,
instead of the port and the VID used by the VLAN device.

The above is valid because as long as the port is not enslaved to a
bridge, VID 1 is guaranteed to be configured as PVID and egress
untagged.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Tested-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c