]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum: Teach mlxsw_sp_port_vlan_set to accept any vlan range
authorJiri Pirko <jiri@mellanox.com>
Tue, 18 Apr 2017 14:55:35 +0000 (16:55 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 20 Apr 2017 19:32:30 +0000 (15:32 -0400)
commit6b2e9b0034f22ef6a51097cd11da6f21bb245925
tree53da1c57ebd1ad2246c2ef6c11722cd24c30faf2
parent107d3e25c41454f73d19398145d0a10d5ef16a53
mlxsw: spectrum: Teach mlxsw_sp_port_vlan_set to accept any vlan range

So far, mlxsw_sp_port_vlan_set range is limited by
MLXSW_REG_SPVM_REC_MAX_COUNT. In spectrum_switchdev code this is
wrapped up by a helper function which actually does multiple calls
to FW for bigger ranges. Move the code into mlxsw_sp_port_vlan_set
and use it always. That allows caller not to care about the range.

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