From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C6D59A00C4 for ; Fri, 18 Nov 2022 00:10:26 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BC83E4067B; Fri, 18 Nov 2022 00:10:26 +0100 (CET) Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) by mails.dpdk.org (Postfix) with ESMTP id 41FE24021F for ; Fri, 18 Nov 2022 00:10:25 +0100 (CET) Received: by mail-wr1-f50.google.com with SMTP id y16so6332259wrt.12 for ; Thu, 17 Nov 2022 15:10:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=q6i/xQf8f3SZR0OpfexQmJ1FVyBWWYW2wVwryqDIQe0=; b=k+aU2vpWO/mLen6V1pJwmmbRE4BhaHOxl5pJsCdhtNvevegjf8JflhDs8I7iR3qhpf mHsMCMG16HZAKU65kx5P6Ytg8UW9NBF3rYanNfX2KOlHpa3ci7oGO4xAZC/YTsauONBu H6BdNzz9NVD7EjeUP+kuj9nO3FrodEHHCiNjp0XCDS53J5VtOrICooH7RfZbQRc1vWW6 W/12GPTV5eeLcKrvjXp3HwUetT3nf4HLGnW2Wq7U6C3kpaXfYKsxpgV7muUjlwIOtvxF Aaclk4TpImehDP/TOp77k0K1R3o/GAZPvX+9mcq2n350mRB3/Zn2dfQzNb4qvsh26uwO OuQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=q6i/xQf8f3SZR0OpfexQmJ1FVyBWWYW2wVwryqDIQe0=; b=56j3+N7agDOhOJQ8ugb3XA7+fcl4lx+3z6xWuMAwfHqJPynqQJmdi9eAdxmvFXljsq k7ECPXh0e8QUDgzetZXj+iLICJoniAoKBJMRABYWQ8iuiHmIA13FthbaiYQeymVUXIif SaP/gFjFbcNE4lMm7NfpUF7KxF7jZgpg+sb9er3pzpNeYdDryfVn+cWcPug87dsDdnX1 ZRKa6UByF0vAsjDjH3CdbdACuoW9+AGopAva4yzECLnfKHNdiv1SbwFbrN7J5sHujCCX dy+A82lioCmWstdKvHydF6TdIvntULTGEJ3+I00T+R9cTKHQBE+OuCwwV3ezxC1M7DIQ VfMg== X-Gm-Message-State: ANoB5pn1vsGtQChz+QvBNLfwiEpNzkyTe1zjAkLbF4bBoUfCd4sWkW+i TYapH3JJmFhhGEcmGAzIPWa2wIFY/Ds= X-Google-Smtp-Source: AA0mqf4SNyRD62rRbjInM8wJH+Dnq/rTZhiimXJ1s6XRNKDZWJosCTy7v62Pjkk9vgyXK37vAEI+dQ== X-Received: by 2002:a5d:5151:0:b0:236:6f26:a0f2 with SMTP id u17-20020a5d5151000000b002366f26a0f2mr2725327wrt.278.1668726625008; Thu, 17 Nov 2022 15:10:25 -0800 (PST) Received: from localhost ([2a01:4b00:d307:1000:f1d3:eb5e:11f4:a7d9]) by smtp.gmail.com with ESMTPSA id q3-20020adfcd83000000b0022eafed36ebsm2060338wrj.73.2022.11.17.15.10.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Nov 2022 15:10:23 -0800 (PST) From: luca.boccassi@gmail.com To: Mingjin Ye Cc: Qi Zhang , dpdk stable Subject: patch 'net/ice: fix scalar Rx path segment' has been queued to stable release 20.11.7 Date: Thu, 17 Nov 2022 23:08:45 +0000 Message-Id: <20221117230859.611465-21-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221117230859.611465-1-luca.boccassi@gmail.com> References: <20221105171146.1520039-47-luca.boccassi@gmail.com> <20221117230859.611465-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 20.11.7 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/19/22. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/kevintraynor/dpdk-stable This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable/commit/f711f82ed6a3f6ac1b5729df9e3204a4105aa52b Thanks. Luca Boccassi --- >From f711f82ed6a3f6ac1b5729df9e3204a4105aa52b Mon Sep 17 00:00:00 2001 From: Mingjin Ye Date: Fri, 11 Nov 2022 12:04:00 +0000 Subject: [PATCH] net/ice: fix scalar Rx path segment [ upstream commit 90ba4442058a14763e57ca96d03ab1e6044e3e5c ] CRC is stripped by the hardware in the scattered Rx path. The last buffer is invalid if it's packet length is zero. This patch adds a judgment for the last buffer length to fix this issue, it would free the mbuf associated to the last one if the last buffer is empty. Fixes: 6eac0b7fde95 ("net/ice: support advance Rx/Tx") Signed-off-by: Mingjin Ye Acked-by: Qi Zhang --- drivers/net/ice/ice_rxtx.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c index 9a7f8ecfe4..bafb853ab9 100644 --- a/drivers/net/ice/ice_rxtx.c +++ b/drivers/net/ice/ice_rxtx.c @@ -1850,6 +1850,10 @@ ice_recv_scattered_pkts(void *rx_queue, } else rxm->data_len = (uint16_t)(rx_packet_len - RTE_ETHER_CRC_LEN); + } else if (rx_packet_len == 0) { + rte_pktmbuf_free_seg(rxm); + first_seg->nb_segs--; + last_seg->next = NULL; } first_seg->port = rxq->port_id; -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-11-17 23:07:56.412706827 +0000 +++ 0021-net-ice-fix-scalar-Rx-path-segment.patch 2022-11-17 23:07:55.528331178 +0000 @@ -1 +1 @@ -From 90ba4442058a14763e57ca96d03ab1e6044e3e5c Mon Sep 17 00:00:00 2001 +From f711f82ed6a3f6ac1b5729df9e3204a4105aa52b Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 90ba4442058a14763e57ca96d03ab1e6044e3e5c ] + @@ -14 +15,0 @@ -Cc: stable@dpdk.org @@ -23 +24 @@ -index cd046a3432..3224a02db2 100644 +index 9a7f8ecfe4..bafb853ab9 100644 @@ -26 +27 @@ -@@ -2113,6 +2113,10 @@ ice_recv_scattered_pkts(void *rx_queue, +@@ -1850,6 +1850,10 @@ ice_recv_scattered_pkts(void *rx_queue,