]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Eswitch, use state_lock to synchronize vlan change
authorVlad Buslov <vladbu@mellanox.com>
Tue, 11 Sep 2018 12:48:59 +0000 (15:48 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 29 Jul 2019 23:40:26 +0000 (16:40 -0700)
commitb74025436e04de99493cbfbb94a1cbfea9587226
tree46db327d8a07e4188937642582c450634d244741
parentcda300cc9a5de087a4c69e817d397ff0b8e04e93
net/mlx5e: Eswitch, use state_lock to synchronize vlan change

esw->state_lock is already used to protect vlan vport configuration change.
However, all preparation and correctness checks, and code that sets vport
data are not protected by this lock and assume external synchronization by
rtnl lock. In order to remove dependency on rtnl lock, extend
esw->state_lock protection to whole eswitch vlan add/del functions.

Signed-off-by: Vlad Buslov <vladbu@mellanox.com>
Reviewed-by: Jianbo Liu <jianbol@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c