From: Vithal Mohare <vmohare@arubanetworks.com>
To: "dev@dpdk.org" <dev@dpdk.org>
Subject: [dpdk-dev] mbuf pool and ring size...
Date: Tue, 22 Sep 2015 05:10:12 +0000 [thread overview]
Message-ID: <98DB008FA2AC6644B40AD8C766FAB271020CB4B3FE@BOREAL.arubanetworks.com> (raw)
Hi,
While creating mbuf pool, suppose if mbuf-pool size passed to DPDK API is already pow-of-2 [ rte_mempool_create()-->rte_mempool_xmem_create()]. Then, noticed that, corresponding size of the ring created for this pool will be double the size of mbuf-pool. This is because of below code snippet:
rte_mempool_xmem_create(...) {
....
r = rte_ring_create(rg_name, rte_align32pow2(n+1), socket_id, rg_flags); <<<<<<<< Notice that its 'n+1' here, rte_align32pow2(n+1)
....
}
Question: why is this 'n+1'? Shouldn't this be just 'n'?
Thanks,
-Vithal
next reply other threads:[~2015-09-22 5:10 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-22 5:10 Vithal Mohare [this message]
2015-09-22 9:07 ` Olivier MATZ
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=98DB008FA2AC6644B40AD8C766FAB271020CB4B3FE@BOREAL.arubanetworks.com \
--to=vmohare@arubanetworks.com \
--cc=dev@dpdk.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).