[v2,1/3] bbdev: new queue stat for available enqueue depth

Message ID 20240812234201.2196633-2-nicolas.chautru@intel.com (mailing list archive)
State New
Delegated to: Maxime Coquelin
Headers
Series bbdev: sdditional queue stats |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Nicolas Chautru Aug. 12, 2024, 11:41 p.m. UTC
Capturing additional queue stats counter for the
depth of enqueue batch still available on the given
queue. This can help application to monitor that depth
at run time.

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
 doc/guides/rel_notes/release_24_11.rst | 3 +++
 lib/bbdev/rte_bbdev.h                  | 2 ++
 2 files changed, 5 insertions(+)
  

Patch

diff --git a/doc/guides/rel_notes/release_24_11.rst b/doc/guides/rel_notes/release_24_11.rst
index 0ff70d9057..a45b9b2dc6 100644
--- a/doc/guides/rel_notes/release_24_11.rst
+++ b/doc/guides/rel_notes/release_24_11.rst
@@ -88,6 +88,9 @@  API Changes
 ABI Changes
 -----------
 
+  * bbdev: Structure ``rte_bbdev_stats`` was updated to add new parameter
+    to optionally report number of enqueue batch available ``enqueue_depth_avail``.
+
 .. This section should contain ABI changes. Sample format:
 
    * sample: Add a short 1-2 sentence description of the ABI change
diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h
index 0cbfdd1c95..25514c58ac 100644
--- a/lib/bbdev/rte_bbdev.h
+++ b/lib/bbdev/rte_bbdev.h
@@ -283,6 +283,8 @@  struct rte_bbdev_stats {
 	 *     bbdev operation
 	 */
 	uint64_t acc_offload_cycles;
+	/** Available number of enqueue batch on that queue. */
+	uint16_t enqueue_depth_avail;
 };
 
 /**