summaryrefslogtreecommitdiffstats
path: root/src/svm/fifo_segment.h
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-05-03 11:46:55 -0700
committerFlorin Coras <florin.coras@gmail.com>2019-05-03 20:27:45 +0000
commit344ce4277885e448912fdfc35bcfaf130c74d086 (patch)
treee2ecaf3ad0c4ca224a32815af44ffd781bcfae5d /src/svm/fifo_segment.h
parenta7570b0378b071129937a89a5632011a962cdb43 (diff)
session/svm: apis for fifo shrinking
Change-Id: Ie519683bb90aae6fb95f2a09e251cded1890ed41 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/svm/fifo_segment.h')
-rw-r--r--src/svm/fifo_segment.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/svm/fifo_segment.h b/src/svm/fifo_segment.h
index 6ff538fcc07..bb4f4080502 100644
--- a/src/svm/fifo_segment.h
+++ b/src/svm/fifo_segment.h
@@ -128,6 +128,15 @@ void fifo_segment_preallocate_fifo_pairs (fifo_segment_t * fs,
*/
int fifo_segment_grow_fifo (fifo_segment_t * fs, svm_fifo_t * f,
u32 chunk_size);
+
+/**
+ * Collect unused chunks for fifo
+ *
+ * @param fs fifo segment for fifo
+ * @param f fifo whose chunks are to be collected
+ * @return 0 on success, error otherwise
+ */
+int fifo_segment_collect_fifo_chunks (fifo_segment_t * fs, svm_fifo_t * f);
u8 fifo_segment_has_fifos (fifo_segment_t * fs);
svm_fifo_t *fifo_segment_get_fifo_list (fifo_segment_t * fs);
u32 fifo_segment_num_fifos (fifo_segment_t * fs);