aboutsummaryrefslogtreecommitdiffstats
path: root/src/svm/fifo_types.h
diff options
context:
space:
mode:
authorRyujiro Shibuya <ryujiro.shibuya@owmobility.com>2019-12-25 07:40:54 +0000
committerDave Barach <openvpp@barachs.net>2020-02-25 19:18:49 +0000
commit234fe894d80a6ebc7e457bc86f2eea80d5ef01ea (patch)
tree89d1e728091669f4199f668b2438b26ab3f95d9b /src/svm/fifo_types.h
parentf22f4e562e1b922cff036ef628b77fd2d479d015 (diff)
session svm: tracking segment memory usage
1. segment manager would attempt to balance the usages across the segments, when it allocate fifos 2. the memory presure level is determined per fifo-segment 3. updated unit test 4. updated cli output for segments Type: feature Signed-off-by: Ryujiro Shibuya <ryujiro.shibuya@owmobility.com> Change-Id: I2923f3e0a43dd919196a0cb2cd55e098fde6cf66
Diffstat (limited to 'src/svm/fifo_types.h')
-rw-r--r--src/svm/fifo_types.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/svm/fifo_types.h b/src/svm/fifo_types.h
index 3e6a14eea7d..f0a286d46a0 100644
--- a/src/svm/fifo_types.h
+++ b/src/svm/fifo_types.h
@@ -112,11 +112,14 @@ struct fifo_segment_header_
fifo_segment_slice_t *slices; /** Fixed array of slices */
ssvm_shared_header_t *ssvm_sh; /**< Pointer to fs ssvm shared hdr */
uword n_free_bytes; /**< Segment free bytes */
+ uword n_cached_bytes; /**< Cached bytes */
u32 n_active_fifos; /**< Number of active fifos */
u32 n_reserved_bytes; /**< Bytes not to be allocated */
u32 max_log2_chunk_size; /**< Max log2(chunk size) for fs */
u8 flags; /**< Segment flags */
u8 n_slices; /**< Number of slices */
+ u8 high_watermark; /**< Memory pressure watermark high */
+ u8 low_watermark; /**< Memory pressure watermark low */
};
#endif /* SRC_SVM_FIFO_TYPES_H_ */