From 3e446f29375c0908e8b68ad3a4fd0c5958538150 Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Sat, 6 Apr 2019 13:34:17 +0200 Subject: lib: Set independent size for rbuff This allows setting the size of the rbuffs in a system independently of the main packet buffer using SHM_RBUFF_SIZE. The benefit of setting a smaller rbuff size is that a single process can't fully occupy the main packet buffer. Signed-off-by: Dimitri Staessens Signed-off-by: Sander Vrijders --- include/ouroboros/shm_rbuff.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include') diff --git a/include/ouroboros/shm_rbuff.h b/include/ouroboros/shm_rbuff.h index c47ae46e..d8c53ee0 100644 --- a/include/ouroboros/shm_rbuff.h +++ b/include/ouroboros/shm_rbuff.h @@ -54,6 +54,10 @@ void shm_rbuff_fini(struct shm_rbuff * rb); int shm_rbuff_write(struct shm_rbuff * rb, size_t idx); +int shm_rbuff_write_b(struct shm_rbuff * rb, + size_t idx, + const struct timespec * abstime); + ssize_t shm_rbuff_read(struct shm_rbuff * rb); ssize_t shm_rbuff_read_b(struct shm_rbuff * rb, -- cgit v1.2.3