Commit e33f9f5f authored by Raed Salem's avatar Raed Salem Committed by Saeed Mahameed
Browse files

net/mlx5e: Enable XDP for Connect-X IPsec capable devices



This limitation was inherited by previous Innova (FPGA) IPsec
implementation, it uses its private set of RQ handlers which
does not support XDP, for Connect-X this is no longer true.

Fix by keeping this limitation only for Innova IPsec supporting devices,
as otherwise this limitation effectively wrongly blocks XDP for all
future Connect-X devices for all flows even if IPsec offload is not
used.

Fixes: 2d64663c ("net/mlx5: IPsec: Add HW crypto offload support")
Signed-off-by: default avatarRaed Salem <raeds@nvidia.com>
Reviewed-by: default avatarAlaa Hleihel <alaa@nvidia.com>
Reviewed-by: default avatarTariq Toukan <tariqt@nvidia.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
parent e4484d9d
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -4456,8 +4456,9 @@ static int mlx5e_xdp_allowed(struct mlx5e_priv *priv, struct bpf_prog *prog)
		return -EINVAL;
	}

	if (MLX5_IPSEC_DEV(priv->mdev)) {
		netdev_warn(netdev, "can't set XDP with IPSec offload\n");
	if (mlx5_fpga_is_ipsec_device(priv->mdev)) {
		netdev_warn(netdev,
			    "XDP is not available on Innova cards with IPsec support\n");
		return -EINVAL;
	}