DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bruce Richardson <bruce.richardson@intel.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>
Cc: dev@dpdk.org, olivier.matz@6wind.com
Subject: Re: [dpdk-dev] [PATCH] mempool: rename functions with confusing names
Date: Wed, 29 Jun 2016 17:00:22 +0100	[thread overview]
Message-ID: <20160629160022.GA11824@bricha3-MOBL3> (raw)
In-Reply-To: <1544094.1XHU1bnLrI@xps13>

On Wed, Jun 29, 2016 at 05:55:27PM +0200, Thomas Monjalon wrote:
> 2016-06-29 14:55, Bruce Richardson:
> > The mempool_count and mempool_free_count behaved contrary to what their
> > names suggested. The free_count function actually returned the number of
> > elements that were allocated from the pool, not the number unallocated as
> > the name implied.
> > 
> > Fix this by introducing two new functions to replace the old ones,
> > * rte_mempool_unallocated_count to replace rte_mempool_count
> > * rte_mempool_allocated_count to replace rte_mempool_free_count
> 
> What about available/used instead of unallocated/allocated?
> 

I don't particularly mind what the name is, to be honest. I like "avail"
because it is shorter, but I'm a little uncertain about "used", because it
implies that the entries are finished with i.e. like a used match, or tissue :-)

How about "avail/in_use"?

/Bruce

  reply	other threads:[~2016-06-29 16:00 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-29 13:55 Bruce Richardson
2016-06-29 15:55 ` Thomas Monjalon
2016-06-29 16:00   ` Bruce Richardson [this message]
2016-06-29 16:02     ` Wiles, Keith
2016-06-29 16:05       ` Olivier MATZ
2016-06-29 16:19         ` Richardson, Bruce
2016-06-29 16:27 ` [dpdk-dev] [PATCH v2] " Bruce Richardson
2016-06-29 16:30   ` Bruce Richardson
2016-06-30 12:00   ` Thomas Monjalon
2016-06-30 12:02     ` Panu Matilainen
2016-06-30 12:09       ` Bruce Richardson
2016-06-30 12:08     ` Bruce Richardson
2016-06-30 12:49 ` [dpdk-dev] [PATCH v3] " Bruce Richardson
2016-06-30 20:05   ` Thomas Monjalon
2016-07-01  8:57     ` Olivier MATZ
2016-07-01 10:21       ` Thomas Monjalon

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=20160629160022.GA11824@bricha3-MOBL3 \
    --to=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=olivier.matz@6wind.com \
    --cc=thomas.monjalon@6wind.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).