Commit 9034b292 authored by Emeel Hakim's avatar Emeel Hakim Committed by Saeed Mahameed
Browse files

net/mlx5e: MACsec, block offload requests with encrypt off



Currently offloading MACsec with authentication only (encrypt
property set to off) is not supported, block such requests
when adding/updating a macsec device.

Fixes: 8ff0ac5b ("net/mlx5: Add MACsec offload Tx command support")
Signed-off-by: default avatarEmeel Hakim <ehakim@nvidia.com>
Reviewed-by: default avatarRaed Salem <raeds@nvidia.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
parent 7c5578e2
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -458,6 +458,11 @@ static bool mlx5e_macsec_secy_features_validate(struct macsec_context *ctx)
		return false;
	}

	if (!ctx->secy->tx_sc.encrypt) {
		netdev_err(netdev, "MACsec offload: encrypt off isn't supported\n");
		return false;
	}

	return true;
}