patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Shiyang He <shiyangx.he@intel.com>
To: dev@dpdk.org
Cc: stable@dpdk.org, Shiyang He <shiyangx.he@intel.com>,
	Qi Zhang <qi.z.zhang@intel.com>,
	Murphy Yang <murphyx.yang@intel.com>
Subject: [PATCH] net/ice: fix EIPT check is always true
Date: Mon,  8 Apr 2024 15:16:17 +0000	[thread overview]
Message-ID: <20240408151617.2095307-1-shiyangx.he@intel.com> (raw)

When enabling hardware outer UDP TX offload checksum, the EIPT judgment
is always true because ICE_TX_CTX_EIPT_NONE = 0x0.

This patch fixes it by checking the non-zero EIPT flag.

Fixes: 2ed011776334 ("net/ice: fix outer UDP Tx checksum offload")
Cc: stable@dpdk.org

Signed-off-by: Shiyang He <shiyangx.he@intel.com>
---
 drivers/net/ice/ice_rxtx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index 13aabe97a5..3e2264de7d 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -2751,7 +2751,7 @@ ice_parse_tunneling_params(uint64_t ol_flags,
 	 * Calculate the tunneling UDP checksum.
 	 * Shall be set only if L4TUNT = 01b and EIPT is not zero
 	 */
-	if (!(*cd_tunneling & ICE_TX_CTX_EIPT_NONE) &&
+	if ((*cd_tunneling & ICE_TXD_CTX_QW0_EIPT_M) != ICE_TX_CTX_EIPT_NONE &&
 		(*cd_tunneling & ICE_TXD_CTX_UDP_TUNNELING) &&
 		(ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM))
 		*cd_tunneling |= ICE_TXD_CTX_QW0_L4T_CS_M;
-- 
2.34.1


             reply	other threads:[~2024-04-08  7:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-08 15:16 Shiyang He [this message]
2024-04-08  9:28 ` David Marchand

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=20240408151617.2095307-1-shiyangx.he@intel.com \
    --to=shiyangx.he@intel.com \
    --cc=dev@dpdk.org \
    --cc=murphyx.yang@intel.com \
    --cc=qi.z.zhang@intel.com \
    --cc=stable@dpdk.org \
    /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;
as well as URLs for NNTP newsgroup(s).