patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Sunil Kumar Kori <skori@marvell.com>
To: Jerin Jacob <jerinj@marvell.com>,
	Nithin Dabilpuram <ndabilpuram@marvell.com>,
	Vamsi Attunuru <vattunuru@marvell.com>,
	"Kiran Kumar K" <kirankumark@marvell.com>
Cc: <dev@dpdk.org>, <stable@dpdk.org>, Sunil Kumar Kori <skori@marvell.com>
Subject: [dpdk-stable] [PATCH] drivers/octeontx2: fix parser error to ol_flags translation
Date: Thu, 3 Oct 2019 12:02:29 +0530	[thread overview]
Message-ID: <20191003063229.19892-1-skori@marvell.com> (raw)

NPC errors were incorrectly translated to ol_flag as
error code enum was not in sync with NPC profile.

Fixes: 371d3212cbed ("common/octeontx2: add build infrastructure and HW definition")

Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---
 drivers/common/octeontx2/hw/otx2_npc.h | 7 ++++---
 drivers/net/octeontx2/otx2_lookup.c    | 2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/common/octeontx2/hw/otx2_npc.h b/drivers/common/octeontx2/hw/otx2_npc.h
index 0f85d7fdb..8045bed11 100644
--- a/drivers/common/octeontx2/hw/otx2_npc.h
+++ b/drivers/common/octeontx2/hw/otx2_npc.h
@@ -132,6 +132,7 @@ enum npc_kpu_err_code {
 	NPC_EC_NOERR = 0, /* has to be zero */
 	NPC_EC_UNK,
 	NPC_EC_IH_LENGTH,
+	NPC_EC_EDSA_UNK,
 	NPC_EC_L2_K1,
 	NPC_EC_L2_K2,
 	NPC_EC_L2_K3,
@@ -245,9 +246,6 @@ enum npc_kpu_lf_ltype {
 	NPC_LT_LF_TU_3RD_NSH,
 };
 
-/* Don't modify Ltypes upto SCTP, otherwise it will
- * effect flow tag calculation and thus RSS.
- */
 enum npc_kpu_lg_ltype {
 	NPC_LT_LG_TU_IP = 1,
 	NPC_LT_LG_TU_IP6,
@@ -255,6 +253,9 @@ enum npc_kpu_lg_ltype {
 	NPC_LT_LG_TU_ETHER_IN_NSH,
 };
 
+/* Don't modify Ltypes upto SCTP, otherwise it will
+ * effect flow tag calculation and thus RSS.
+ */
 enum npc_kpu_lh_ltype {
 	NPC_LT_LH_TU_TCP = 1,
 	NPC_LT_LH_TU_UDP,
diff --git a/drivers/net/octeontx2/otx2_lookup.c b/drivers/net/octeontx2/otx2_lookup.c
index 99199d08a..6cdca9b33 100644
--- a/drivers/net/octeontx2/otx2_lookup.c
+++ b/drivers/net/octeontx2/otx2_lookup.c
@@ -272,13 +272,13 @@ nix_create_rx_ol_flags_array(void *mem)
 				val |= PKT_RX_IP_CKSUM_GOOD;
 			break;
 		case NPC_ERRLEV_NIX:
+			val |= PKT_RX_IP_CKSUM_GOOD;
 			if (errcode == NIX_RX_PERRCODE_OL4_CHK) {
 				val |= PKT_RX_OUTER_L4_CKSUM_BAD;
 				val |= PKT_RX_L4_CKSUM_BAD;
 			} else if (errcode == NIX_RX_PERRCODE_IL4_CHK) {
 				val |= PKT_RX_L4_CKSUM_BAD;
 			} else {
-				val |= PKT_RX_IP_CKSUM_GOOD;
 				val |= PKT_RX_L4_CKSUM_GOOD;
 			}
 			break;
-- 
2.17.2


             reply	other threads:[~2019-10-03  6:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-03  6:32 Sunil Kumar Kori [this message]
2019-10-03 14:37 ` [dpdk-stable] [dpdk-dev] " Jerin Jacob

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=20191003063229.19892-1-skori@marvell.com \
    --to=skori@marvell.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=kirankumark@marvell.com \
    --cc=ndabilpuram@marvell.com \
    --cc=stable@dpdk.org \
    --cc=vattunuru@marvell.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;
as well as URLs for NNTP newsgroup(s).