FAILED: patch "[PATCH] ixgbe: fail to create xfrm offload of IPsec tunnel mode SA" failed to apply to 4.19-stable tree
Subsystems (3)
[email protected]
maintainerThe patch below does not apply to the 4.19-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From d785e1fec60179f534fbe8d006c890e5ad186e51 Mon Sep 17 00:00:00 2001
From: Antony Antony <[email protected]>
Date: Wed, 14 Oct 2020 16:17:48 +0200
Subject: [PATCH] ixgbe: fail to create xfrm offload of IPsec tunnel mode SA
Based on talks and indirect references ixgbe IPsec offlod do not support IPsec tunnel mode offload. It can only support IPsec transport mode offload. Now explicitly fail when creating non transport mode SA with offload to avoid false performance expectations.
drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c +5 -0
@@ -575,6 +575,11 @@ static int ixgbe_ipsec_add_sa(struct xfrm_state *xs)return -EINVAL ; } +if (xs->props.mode !=XFRM_MODE_TRANSPORT ) { +netdev_err (dev,"Unsupported mode for ipsec offload\n" ); +return -EINVAL ; + } +if (ixgbe_ipsec_check_mgmt_ip (xs)) {netdev_err (dev,"IPsec IP addr clash with mgmt filters\n" );return -EINVAL ;
drivers/net/ethernet/intel/ixgbevf/ipsec.c +5 -0
@@ -272,6 +272,11 @@ static int ixgbevf_ipsec_add_sa(struct xfrm_state *xs)return -EINVAL ; } +if (xs->props.mode !=XFRM_MODE_TRANSPORT ) { +netdev_err (dev,"Unsupported mode for ipsec offload\n" ); +return -EINVAL ; + } +if (xs->xso.flags &XFRM_OFFLOAD_INBOUND ) {struct rx_sa rsa;