From: Shannon Nelson <snelson@pensando.io>
To: Antony Antony <antony@phenome.org>,
Jesse Brandeburg <jesse.brandeburg@intel.com>,
Tony Nguyen <anthony.l.nguyen@intel.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>
Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>,
Shannon Nelson <shannon.nelson@oracle.com>,
intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org,
Steffen Klassert <steffen.klassert@secunet.com>
Subject: Re: [PATCH] ixgbe: fail to create xfrm offload of IPsec tunnel mode SA
Date: Wed, 14 Oct 2020 11:14:21 -0700 [thread overview]
Message-ID: <9ca1d11f-5dfa-1be1-6ced-b046dddd5d00@pensando.io> (raw)
In-Reply-To: <20201014141748.GA4910@AntonyAntony.local>
On 10/14/20 7:17 AM, Antony Antony wrote:
> 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.
>
> Fixes: 63a67fe229ea ("ixgbe: add ipsec offload add and remove SA")
> Signed-off-by: Antony Antony <antony@phenome.org>
Acked-by: Shannon Nelson <snelson@pensando.io>
> ---
> drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c | 5 +++++
> drivers/net/ethernet/intel/ixgbevf/ipsec.c | 5 +++++
> 2 files changed, 10 insertions(+)
>
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c
> index eca73526ac86..54d47265a7ac 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c
> @@ -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;
> diff --git a/drivers/net/ethernet/intel/ixgbevf/ipsec.c b/drivers/net/ethernet/intel/ixgbevf/ipsec.c
> index 5170dd9d8705..caaea2c920a6 100644
> --- a/drivers/net/ethernet/intel/ixgbevf/ipsec.c
> +++ b/drivers/net/ethernet/intel/ixgbevf/ipsec.c
> @@ -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;
>
prev parent reply other threads:[~2020-10-14 18:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-28 11:11 [PATCH RFC] xfrm: fail to create ixgbe offload of IPsec tunnel mode sa Antony Antony
2020-10-14 14:17 ` [PATCH] ixgbe: fail to create xfrm offload of IPsec tunnel mode SA Antony Antony
2020-10-14 18:14 ` Shannon Nelson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9ca1d11f-5dfa-1be1-6ced-b046dddd5d00@pensando.io \
--to=snelson@pensando.io \
--cc=anthony.l.nguyen@intel.com \
--cc=antony@phenome.org \
--cc=davem@davemloft.net \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jeffrey.t.kirsher@intel.com \
--cc=jesse.brandeburg@intel.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=shannon.nelson@oracle.com \
--cc=steffen.klassert@secunet.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox