patches for DPDK stable branches
 help / color / mirror / Atom feed
* [PATCH] mempool: fix internal function documentation
@ 2023-10-20 14:46 Ferruh Yigit
  2023-10-20 16:08 ` Morten Brørup
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Ferruh Yigit @ 2023-10-20 14:46 UTC (permalink / raw)
  To: Thomas Monjalon, Andrew Rybchenko; +Cc: dev, stable, Mahesh Adulla

static function `rte_mempool_do_generic_get()` returns zero on success,
not >=0 as its function comment documents.

Since this function called by public API, the comment causes confusion
on the public API return value.

Fixing the internal function documentation for return value.

Fixes: af75078fece3 ("first public release")
Cc: stable@dpdk.org

Reported-by: Mahesh Adulla <mahesh.adulla@amd.com>
Signed-off-by: Ferruh Yigit <ferruh.yigit@amd.com>
---
 .mailmap                  | 1 +
 lib/mempool/rte_mempool.h | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.mailmap b/.mailmap
index 3f5bab26a81f..bfe451980f1c 100644
--- a/.mailmap
+++ b/.mailmap
@@ -836,6 +836,7 @@ Maciej Rabeda <maciej.rabeda@intel.com>
 Maciej Szwed <maciej.szwed@intel.com>
 Madhu Chittim <madhu.chittim@intel.com>
 Madhuker Mythri <madhuker.mythri@oracle.com>
+Mahesh Adulla <mahesh.adulla@amd.com>
 Mahipal Challa <mchalla@marvell.com>
 Mah Yock Gen <yock.gen.mah@intel.com>
 Mairtin o Loingsigh <mairtin.oloingsigh@intel.com>
diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h
index f70bf36080fb..86598bc639e6 100644
--- a/lib/mempool/rte_mempool.h
+++ b/lib/mempool/rte_mempool.h
@@ -1484,7 +1484,7 @@ rte_mempool_put(struct rte_mempool *mp, void *obj)
  * @param cache
  *   A pointer to a mempool cache structure. May be NULL if not needed.
  * @return
- *   - >=0: Success; number of objects supplied.
+ *   - 0: Success; number of objects supplied.
  *   - <0: Error; code of driver dequeue function.
  */
 static __rte_always_inline int
-- 
2.34.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-11-27 15:27 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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   ` [PATCH v2 2/2] mempool: clarify enqueue and dequeue ops return type Ferruh Yigit
2023-10-23  9:43     ` 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

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).