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 5BA04A0547 for ; Tue, 9 Feb 2021 11:36:45 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4EA0940147; Tue, 9 Feb 2021 11:36:45 +0100 (CET) Received: from mail-wm1-f41.google.com (mail-wm1-f41.google.com [209.85.128.41]) by mails.dpdk.org (Postfix) with ESMTP id F0BE316070A for ; Tue, 9 Feb 2021 11:36:43 +0100 (CET) Received: by mail-wm1-f41.google.com with SMTP id o24so2952427wmh.5 for ; Tue, 09 Feb 2021 02:36:43 -0800 (PST) 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 :mime-version:content-transfer-encoding; bh=mLiTzdOXdTZmdyPJCNigG9GXp3VxpVh7P3HjaqsfYkk=; b=EmRiJ6rekN/3d2MdfqSoIRKDDZBmC8CBxFvacfAgs3o6dsoIw3J11YkzTlxLN2Zi2J MlFLN/qGWWbjqLzQoTDHaHJHzfu1Dnppg2G1oYFFoUDQh13ilYqiW/zUqMRIyVXECb/G XCBS3IIuwil8Rbv8j6/F9GWGS7NjmbMEfe+Nu1MGG2hmkOSmRAuAtxOoVJXq6H6VBBoY M96CV5fkdGG4mJoBk5I6Tr0CatuxMhjVtw0135DtiEn43rycNy0eaCs2Wvj55TqdtgTK AUfK70H9Bq4Fk5oxaQNlJARuFmfK9A0Ub5t6w+5smhWgETrph7Y+GwfqAlREN353W7iy ua6A== 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:mime-version:content-transfer-encoding; bh=mLiTzdOXdTZmdyPJCNigG9GXp3VxpVh7P3HjaqsfYkk=; b=aiaFloc0PUZlNDyG5fKn9tOLgT15o/C6KMPBpU7VbXXZgnuaLOKhTF3VDyQpIluROJ bhSvZuq1T2/w3Kd7ycIydtjiB0K89XcMYFTjaZSG7ThP8whTEpTWG4xINnHAvngkxDKo vzUlpQbCQxkgDvqH0mBxX244eibbg35OUgtc6ho+PRjms5WC3tg+2UOiQtmZxNNrmK1Y QkjuAD2BsfsZ6CPeq1VkMgmofgeedct5VRSXdczo1uSvADuhuDzRN65rHeSQn5Hjh269 4p7x2E6eNQ+bSfxzaDEnVYlW73X6TMilGx/ad3Svs4tDBZfLIycoOzpv8zB9J5TwA2g0 iAKQ== X-Gm-Message-State: AOAM533zNO/qGu3Pp1uazOkqVdZk60DPCMK2ug9ipgbVbKq2ctx4Ha6f wc9Qi2ACIoNocch7yyePe00liJayqvBkCg== X-Google-Smtp-Source: ABdhPJwhS/Iz4urIFPJ6Yc1C5+bHhcz9KHNfZ2kMzhz5JB5hyTnV24S9wrLzhfPnQyHm3CkvkumXmg== X-Received: by 2002:a1c:dfd6:: with SMTP id w205mr2797643wmg.90.1612867002722; Tue, 09 Feb 2021 02:36:42 -0800 (PST) Received: from localhost ([88.98.246.218]) by smtp.gmail.com with ESMTPSA id v5sm15663577wro.71.2021.02.09.02.36.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Feb 2021 02:36:42 -0800 (PST) From: luca.boccassi@gmail.com To: Ferruh Yigit Cc: Cian Ferriter , dpdk stable Date: Tue, 9 Feb 2021 10:35:21 +0000 Message-Id: <20210209103529.466775-23-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210209103529.466775-1-luca.boccassi@gmail.com> References: <20210205111920.1272063-1-luca.boccassi@gmail.com> <20210209103529.466775-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/pcap: fix byte stats for drop Tx' has been queued to stable release 20.11.1 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 Sender: "stable" Hi, FYI, your patch has been queued to stable release 20.11.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 02/11/21. 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/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/63e152d10758a6eae614f9d39ade06f24fcdf0d1 Thanks. Luca Boccassi --- >From 63e152d10758a6eae614f9d39ade06f24fcdf0d1 Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Wed, 3 Feb 2021 17:30:25 +0000 Subject: [PATCH] net/pcap: fix byte stats for drop Tx [ upstream commit cec222d6e55d9bd15eff7fbbf45464c0c6a941c0 ] Drop Tx path in pcap is Tx that just drops the packets, which is used for the case only Rx from a pcap file is requested/matters. The byte stats was calculated using first mbuf segment, which gives wrong values for multi segmented mbufs, updated to use packet length instead. Bugzilla ID: 597 Fixes: a3f5252e5cbd ("net/pcap: enable infinitely Rx a pcap file") Reported-by: Cian Ferriter Signed-off-by: Ferruh Yigit Acked-by: Cian Ferriter --- drivers/net/pcap/rte_eth_pcap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c index a32b1f3f37..d44e1d39ae 100644 --- a/drivers/net/pcap/rte_eth_pcap.c +++ b/drivers/net/pcap/rte_eth_pcap.c @@ -386,7 +386,7 @@ eth_tx_drop(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) return 0; for (i = 0; i < nb_pkts; i++) { - tx_bytes += bufs[i]->data_len; + tx_bytes += bufs[i]->pkt_len; rte_pktmbuf_free(bufs[i]); } -- 2.29.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-02-09 10:34:58.854556574 +0000 +++ 0023-net-pcap-fix-byte-stats-for-drop-Tx.patch 2021-02-09 10:34:57.926584313 +0000 @@ -1 +1 @@ -From cec222d6e55d9bd15eff7fbbf45464c0c6a941c0 Mon Sep 17 00:00:00 2001 +From 63e152d10758a6eae614f9d39ade06f24fcdf0d1 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit cec222d6e55d9bd15eff7fbbf45464c0c6a941c0 ] + @@ -15 +16,0 @@ -Cc: stable@dpdk.org @@ -25 +26 @@ -index ff02ade70d..c7751b7ba7 100644 +index a32b1f3f37..d44e1d39ae 100644