dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
From: "A.McLoughlin" <aideen.mcloughlin@intel.com>
To: Ferruh Yigit <ferruh.yigit@intel.com>
Cc: dev@dpdk.org, "A.McLoughlin" <aideen.mcloughlin@intel.com>,
	stable@dpdk.org, tero.aho@coriant.com
Subject: [dpdk-dev] [PATCH] net/pcap: fix issue with unnecessary mbufs freeing
Date: Thu, 11 Jul 2019 14:59:46 +0100	[thread overview]
Message-ID: <20190711135946.811-1-aideen.mcloughlin@intel.com> (raw)

In the eth_pcap_tx() and eth_pcap_tx_dumper() functions mbufs were freed
without incrementing num_tx. To fix the issue, the mbuf freeing was
removed as it was not of any benefit.

Fixes: 6db141c91e1f ("pcap: support jumbo frames")
Cc: stable@dpdk.org
Cc: tero.aho@coriant.com

Signed-off-by: A.McLoughlin <aideen.mcloughlin@intel.com>
---
 drivers/net/pcap/rte_eth_pcap.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c
index 26e85183e..77bb66337 100644
--- a/drivers/net/pcap/rte_eth_pcap.c
+++ b/drivers/net/pcap/rte_eth_pcap.c
@@ -349,7 +349,6 @@ eth_pcap_tx_dumper(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 					mbuf->pkt_len,
 					RTE_ETHER_MAX_JUMBO_FRAME_LEN);
 
-				rte_pktmbuf_free(mbuf);
 				break;
 			}
 		}
@@ -435,7 +434,6 @@ eth_pcap_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 					mbuf->pkt_len,
 					RTE_ETHER_MAX_JUMBO_FRAME_LEN);
 
-				rte_pktmbuf_free(mbuf);
 				break;
 			}
 		}
-- 
2.17.1

--------------------------------------------------------------
Intel Research and Development Ireland Limited
Registered in Ireland
Registered Office: Collinstown Industrial Park, Leixlip, County Kildare
Registered Number: 308263


This e-mail and any attachments may contain confidential material for the sole
use of the intended recipient(s). Any review or distribution by others is
strictly prohibited. If you are not the intended recipient, please contact the
sender and delete all copies.


             reply	other threads:[~2019-07-11 14:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-11 13:59 A.McLoughlin [this message]
2019-07-11 14:15 ` [dpdk-dev] [PATCH] net/pcap: fix issue with unnecessary mbufs freeing Ferruh Yigit
2019-07-16 17:17   ` Ferruh Yigit
2019-07-24  7:15 ` [dpdk-dev] [dpdk-stable] " 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=20190711135946.811-1-aideen.mcloughlin@intel.com \
    --to=aideen.mcloughlin@intel.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=stable@dpdk.org \
    --cc=tero.aho@coriant.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).