Commit 68931c7d authored by Roi Dayan's avatar Roi Dayan Committed by Saeed Mahameed

net/mlx5e: Update check for merged eswitch device

The current check only validates if both netdevs use the same ops
which means both are vf reps or both uplink reps.

Unlike the case where the two uplinks are bonded (VF LAG), under
multipath scheme the switchdev parent id is not unified between the
uplink reps (and all the associated vf reps). However, we still want
to duplicate in the driver encap flows, adjust the merged eswitch
check for that matter.
Signed-off-by: default avatarRoi Dayan <roid@mellanox.com>
Reviewed-by: default avatarOr Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
parent 5fb091e8
...@@ -2360,10 +2360,9 @@ static bool is_merged_eswitch_dev(struct mlx5e_priv *priv, ...@@ -2360,10 +2360,9 @@ static bool is_merged_eswitch_dev(struct mlx5e_priv *priv,
peer_priv = netdev_priv(peer_netdev); peer_priv = netdev_priv(peer_netdev);
return (MLX5_CAP_ESW(priv->mdev, merged_eswitch) && return (MLX5_CAP_ESW(priv->mdev, merged_eswitch) &&
(priv->netdev->netdev_ops == peer_netdev->netdev_ops) && mlx5e_eswitch_rep(priv->netdev) &&
same_hw_devs(priv, peer_priv) && mlx5e_eswitch_rep(peer_netdev) &&
MLX5_VPORT_MANAGER(peer_priv->mdev) && same_hw_devs(priv, peer_priv));
(peer_priv->mdev->priv.eswitch->mode == SRIOV_OFFLOADS));
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment