]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net/mlx5: E-Switch, Return EBUSY if can't get mode lock
authorJianbo Liu <jianbol@nvidia.com>
Sun, 2 Oct 2022 04:56:32 +0000 (21:56 -0700)
committerJakub Kicinski <kuba@kernel.org>
Mon, 3 Oct 2022 23:55:29 +0000 (16:55 -0700)
It is to avoid tc retrying during device mode change.

Signed-off-by: Jianbo Liu <jianbol@nvidia.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c

index 0872a214d2a3bc40ed5facfda3f25da0059b4426..70a7a61f97087a22991448978af56164b2353fb5 100644 (file)
@@ -4463,7 +4463,7 @@ int mlx5e_configure_flower(struct net_device *dev, struct mlx5e_priv *priv,
        int err = 0;
 
        if (!mlx5_esw_hold(priv->mdev))
-               return -EAGAIN;
+               return -EBUSY;
 
        mlx5_esw_get(priv->mdev);