net/mlx5e: Disable IPsec offload support if not FW steering
authorChris Mi <cmi@nvidia.com>
Mon, 30 Oct 2023 13:44:47 +0000 (15:44 +0200)
committerSaeed Mahameed <saeedm@nvidia.com>
Tue, 5 Dec 2023 06:11:53 +0000 (22:11 -0800)
commit762a55a54eec4217e4cec9265ab6e5d4c11b61bd
tree09a8720efdeac53d7fe77d869d6756d8ae6dd7e9
parent4e25b661f484df54b6751b65f9ea2434a3b67539
net/mlx5e: Disable IPsec offload support if not FW steering

IPsec FDB offload can only work with FW steering as of now,
disable the cap upon non FW steering.

And since the IPSec cap is dynamic now based on steering mode.
Cleanup the resources if they exist instead of checking the
IPsec cap again.

Fixes: edd8b295f9e2 ("Merge branch 'mlx5-ipsec-packet-offload-support-in-eswitch-mode'")
Signed-off-by: Chris Mi <cmi@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec_offload.c