From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f193.google.com (mail-wr0-f193.google.com [209.85.128.193]) by dpdk.org (Postfix) with ESMTP id A3B4828F3 for ; Wed, 23 May 2018 14:11:49 +0200 (CEST) Received: by mail-wr0-f193.google.com with SMTP id l41-v6so838381wre.7 for ; Wed, 23 May 2018 05:11:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=hQolUO9N15DjQGge7VRyD7nf1O2HNycn5P3lW7S358A=; b=pq6dLQkLzi/BmqdJvjMAMj9P2Ku20O1sI4zDyFW2jYgfyk4LP9f6873ROI9sd5pz91 37uO18vEHUVnJxXMM6Ro2hffzWnMfoUzanOUcrgacS1N0BOzzQ/0GXe6Sc+nT6900mT+ TqUyPgOmkYvRYgEHvx1SG7MWhzE/OMCqjk1BILS2KlrrK4hO0lN5IMjnZAoIQuaoXwqU F+eOPstBiyXQ8OcF4dcCIFEaB/wixJRvY05paA4ZpdEK3U7In6dzFkQucWbYq1i0Ebmo m+LaEBE1XM83spNM0z38wdc7zWyN9N5utv6yQslmW+F0Ufl3Sehz//+xl3cQc0BOuVLH YP5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=hQolUO9N15DjQGge7VRyD7nf1O2HNycn5P3lW7S358A=; b=PnPuNSduA3s5G+bJsfaa9aYKmGkuLWmHl3F0sRSsiQFrHdTLbdkzzG8t1vOURnckuN sXLbsIZapcO8NBZcHapBEV8rZBYd7gOJWzMJGFRyh8pfn+G73ne0nO8acvEr7eolWrCw 4ISzp4Ua8RUPwl/OfPn/4hMvo2bbDLm+zfGsD1v0/fGiYifm8SCEPPmXrMH36q0AuBFb eI5KStunkrNf9sl8Uo/f9StNSEBWlWp1jRDohm/5IKBvNydAC7hgfPQw58T5Hm1Qcs8i XY1bBM33DtUharJ12pim98sD3pWZ9Q/6b6OFVPUTsxoyvpP2eNGSi9N/QMetT0fAotNn H8HQ== X-Gm-Message-State: ALKqPwcxkcrhzGzs5Ec8LaBVtGEDlXV0UKIxg6PrrzDHtTJXiuEvIAOp 36zvRY9ApMHIQ0L8qgOFhilyCWT9Kxg= X-Google-Smtp-Source: AB8JxZqCXKIOVVRSuEAG2o/2vYnGt6IkU8iEBK+fUzULMeXn+CAO2KWroroFONr6rGoY7vSwL+5wDg== X-Received: by 2002:adf:9986:: with SMTP id y6-v6mr2390121wrb.40.1527077509373; Wed, 23 May 2018 05:11:49 -0700 (PDT) Received: from localhost ([2a00:23c5:be9a:5200:ce4c:82c0:d567:ecbb]) by smtp.gmail.com with ESMTPSA id i76-v6sm3702208wmd.20.2018.05.23.05.11.48 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 23 May 2018 05:11:48 -0700 (PDT) From: luca.boccassi@gmail.com To: Ajit Khaparde Cc: dpdk stable Date: Wed, 23 May 2018 13:10:09 +0100 Message-Id: <20180523121010.8385-58-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180523121010.8385-1-luca.boccassi@gmail.com> References: <20180516101323.2234-2-luca.boccassi@gmail.com> <20180523121010.8385-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'net/bnxt: fix Rx checksum flags' has been queued to stable release 18.02.2 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 May 2018 12:11:49 -0000 Hi, FYI, your patch has been queued to stable release 18.02.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/25/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From 65a18cf1acc8c3eca2cd31df67b42a0d286ccf78 Mon Sep 17 00:00:00 2001 From: Ajit Khaparde Date: Tue, 22 May 2018 11:13:47 -0700 Subject: [PATCH] net/bnxt: fix Rx checksum flags [ upstream commit 65ee636872ebd13b85bb0bebeb3cade56f94e6f1 ] For frames where the hardware is not able to calculate checksum we are indicating such frames to be bad. And that is incorrect. Indicate PKT_RX_IP_CKSUM_UNKNOWN or PKT_RX_L4_CKSUM_UNKNOWN for such frames. Fixes: 7ec39d8c524b ("net/bnxt: update status of Rx IP/L4 CKSUM") Signed-off-by: Ajit Khaparde --- drivers/net/bnxt/bnxt_rxr.c | 4 ++++ drivers/net/bnxt/bnxt_rxr.h | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c index de6719122..216ca7144 100644 --- a/drivers/net/bnxt/bnxt_rxr.c +++ b/drivers/net/bnxt/bnxt_rxr.c @@ -492,11 +492,15 @@ static int bnxt_rx_pkt(struct rte_mbuf **rx_pkt, if (likely(RX_CMP_IP_CS_OK(rxcmp1))) mbuf->ol_flags |= PKT_RX_IP_CKSUM_GOOD; + else if (likely(RX_CMP_IP_CS_UNKNOWN(rxcmp1))) + mbuf->ol_flags |= PKT_RX_IP_CKSUM_UNKNOWN; else mbuf->ol_flags |= PKT_RX_IP_CKSUM_BAD; if (likely(RX_CMP_L4_CS_OK(rxcmp1))) mbuf->ol_flags |= PKT_RX_L4_CKSUM_GOOD; + else if (likely(RX_CMP_L4_CS_UNKNOWN(rxcmp1))) + mbuf->ol_flags |= PKT_RX_L4_CKSUM_UNKNOWN; else mbuf->ol_flags |= PKT_RX_L4_CKSUM_BAD; diff --git a/drivers/net/bnxt/bnxt_rxr.h b/drivers/net/bnxt/bnxt_rxr.h index 174e1832f..d26fefd4a 100644 --- a/drivers/net/bnxt/bnxt_rxr.h +++ b/drivers/net/bnxt/bnxt_rxr.h @@ -64,6 +64,9 @@ (((rxcmp1)->flags2 & RX_CMP_L4_CS_BITS) && \ !((rxcmp1)->errors_v2 & RX_CMP_L4_CS_ERR_BITS)) +#define RX_CMP_L4_CS_UNKNOWN(rxcmp1) \ + !((rxcmp1)->flags2 & RX_CMP_L4_CS_BITS) + #define RX_CMP_IP_CS_ERR_BITS \ rte_cpu_to_le_32(RX_PKT_CMPL_ERRORS_IP_CS_ERROR | \ RX_PKT_CMPL_ERRORS_T_IP_CS_ERROR) @@ -76,6 +79,9 @@ (((rxcmp1)->flags2 & RX_CMP_IP_CS_BITS) && \ !((rxcmp1)->errors_v2 & RX_CMP_IP_CS_ERR_BITS)) +#define RX_CMP_IP_CS_UNKNOWN(rxcmp1) \ + !((rxcmp1)->flags2 & RX_CMP_IP_CS_BITS) + enum pkt_hash_types { PKT_HASH_TYPE_NONE, /* Undefined type */ PKT_HASH_TYPE_L2, /* Input: src_MAC, dest_MAC */ -- 2.14.2