DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Richardson, Bruce" <bruce.richardson@intel.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [RFC PATCH DRAFT 1/2] ethdev: add buffered single pkt TX function to API
Date: Wed, 25 Jun 2014 00:05:06 +0000	[thread overview]
Message-ID: <59AF69C657FD0841A61C55336867B5B02CEE35C9@IRSMSX103.ger.corp.intel.com> (raw)
In-Reply-To: <20140624160545.136ad9e4@nehalam.linuxnetplumber.net>

> -----Original Message-----
> From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> Sent: Tuesday, June 24, 2014 4:06 PM
> To: Richardson, Bruce
> Cc: dev@dpdk.org
> Subject: Re: [dpdk-dev] [RFC PATCH DRAFT 1/2] ethdev: add buffered single pkt
> TX function to API
> 
> On Tue, 24 Jun 2014 23:32:15 +0100
> Bruce Richardson <bruce.richardson@intel.com> wrote:
> 
> >
> > +static void
> > +free_unsent_pkts(struct rte_mbuf **pkts, uint16_t unsent,
> > +		void *userdata __rte_unused)
> > +{
> > +	unsigned i;
> > +	for (i = 0; i < unsent; i++)
> > +		rte_pktmbuf_free(pkts[i]);
> > +}
> > +
> 
> This should be moved into mbuf layer, and there it could be
> optimized to do a rte_mempool_mp_put_bulk. This would speed
> up operations becuase it would mean a single ring operation
> per set rather per mbuf segment.
> 
> Of course, the optimization would have to handle the refcnt
> issues.

I'm not sure how we can improve this by bringing it into the mbuf layer. As well as handling of refcounts, we also have no guarantee than each mbuf queued up for a particular port comes from the same mempool.
Can you please clarify how you think this might be better done?

  reply	other threads:[~2014-06-25  0:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-24 22:32 [dpdk-dev] [RFC PATCH DRAFT 0/2] ethdev: Proposal to expand API for single-pkt-tx Bruce Richardson
2014-06-24 22:32 ` [dpdk-dev] [RFC PATCH DRAFT 1/2] ethdev: add buffered single pkt TX function to API Bruce Richardson
2014-06-24 23:05   ` Stephen Hemminger
2014-06-25  0:05     ` Richardson, Bruce [this message]
2014-06-24 23:07   ` Stephen Hemminger
2014-06-25  0:02     ` Richardson, Bruce
2014-06-24 22:32 ` [dpdk-dev] [RFC PATCH DRAFT 2/2] l2fwd: update l2fwd to use tx_buffer API Bruce Richardson

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=59AF69C657FD0841A61C55336867B5B02CEE35C9@IRSMSX103.ger.corp.intel.com \
    --to=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=stephen@networkplumber.org \
    /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).