From: Ferruh Yigit <ferruh.yigit@amd.com>
To: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>,
Olivier Matz <olivier.matz@6wind.com>,
David Hunt <david.hunt@intel.com>,
Shreyansh Jain <shreyansh.jain@nxp.com>
Cc: dev@dpdk.org, stable@dpdk.org,
"Morten Brørup" <mb@smartsharesystems.com>
Subject: [PATCH v2 2/2] mempool: clarify enqueue and dequeue ops return type
Date: Mon, 23 Oct 2023 10:38:43 +0100 [thread overview]
Message-ID: <20231023093844.4150572-2-ferruh.yigit@amd.com> (raw)
In-Reply-To: <20231023093844.4150572-1-ferruh.yigit@amd.com>
API documentations doesn't clarify expected return types for enqueue and
dequeue mempool_ops, clarifying it.
Fixes: 449c49b93a6b ("mempool: support handler operations")
Cc: stable@dpdk.org
Reported-by: Morten Brørup <mb@smartsharesystems.com>
Signed-off-by: Ferruh Yigit <ferruh.yigit@amd.com>
---
lib/mempool/rte_mempool.h | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h
index 86598bc639e6..8ed0386ba3f1 100644
--- a/lib/mempool/rte_mempool.h
+++ b/lib/mempool/rte_mempool.h
@@ -465,13 +465,19 @@ typedef int (*rte_mempool_alloc_t)(struct rte_mempool *mp);
typedef void (*rte_mempool_free_t)(struct rte_mempool *mp);
/**
- * Enqueue an object into the external pool.
+ * Enqueue 'n' objects into the external pool.
+ * @return
+ * - 0: Success
+ * - <0: Error
*/
typedef int (*rte_mempool_enqueue_t)(struct rte_mempool *mp,
void * const *obj_table, unsigned int n);
/**
- * Dequeue an object from the external pool.
+ * Dequeue 'n' objects from the external pool.
+ * @return
+ * - 0: Success
+ * - <0: Error
*/
typedef int (*rte_mempool_dequeue_t)(struct rte_mempool *mp,
void **obj_table, unsigned int n);
--
2.34.1
next prev parent reply other threads:[~2023-10-23 9:39 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-20 14:46 [PATCH] mempool: fix internal function documentation Ferruh Yigit
2023-10-20 16:08 ` Morten Brørup
2023-10-23 9:07 ` Ferruh Yigit
2023-10-21 3:09 ` lihuisong (C)
2023-10-23 9:38 ` [PATCH v2 1/2] " Ferruh Yigit
2023-10-23 9:38 ` Ferruh Yigit [this message]
2023-10-23 9:43 ` [PATCH v2 2/2] mempool: clarify enqueue and dequeue ops return type Morten Brørup
2023-11-27 15:27 ` Thomas Monjalon
2023-11-06 12:24 ` [PATCH v2 1/2] mempool: fix internal function documentation Andrew Rybchenko
2023-11-27 14:41 ` 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=20231023093844.4150572-2-ferruh.yigit@amd.com \
--to=ferruh.yigit@amd.com \
--cc=andrew.rybchenko@oktetlabs.ru \
--cc=david.hunt@intel.com \
--cc=dev@dpdk.org \
--cc=mb@smartsharesystems.com \
--cc=olivier.matz@6wind.com \
--cc=shreyansh.jain@nxp.com \
--cc=stable@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).