提交 a546432f 编写于 作者: E Eli Cohen 提交者: Saeed Mahameed

net/mlx5: Remove unnecessary spin lock protection

Taking lag_lock to access ldev->tracker is meaningless in the context of
do_bond() and mlx5_lag_netdev_event().
Signed-off-by: NEli Cohen <elic@nvidia.com>
Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com>
上级 71513c05
......@@ -280,9 +280,7 @@ static void mlx5_do_bond(struct mlx5_lag *ldev)
if (!mlx5_lag_is_ready(ldev))
return;
spin_lock(&lag_lock);
tracker = ldev->tracker;
spin_unlock(&lag_lock);
do_bond = tracker.is_bonded && mlx5_lag_check_prereq(ldev);
......@@ -481,9 +479,7 @@ static int mlx5_lag_netdev_event(struct notifier_block *this,
break;
}
spin_lock(&lag_lock);
ldev->tracker = tracker;
spin_unlock(&lag_lock);
if (changed)
mlx5_queue_bond_work(ldev, 0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册