diff options
author | Harald Welte <laforge@osmocom.org> | 2019-12-15 17:35:58 +0100 |
---|---|---|
committer | Harald Welte <laforge@osmocom.org> | 2019-12-15 17:39:26 +0100 |
commit | 17146791064365d29b925ea128685f8c63ce57e3 (patch) | |
tree | bcb6c119a51a0180ca4f77dc492966c2113040af | |
parent | a812de808d30f0ff809b591ceda30b2111e70d07 (diff) |
pseudo_talloc: Increment number of buffers from 10 to 20
We need at least one per IN/IRQ endpoint, as well as at least 3 for
every OUT endpoint. Plus some more depending on the application,
in case of cardem there could be one in uart_tx and one in uart_rx.
So for cardem, it should be 7 per slot, resulting 14 for dual-slot
devices like OWHW and QMOD.
Given that we have plenty of RAM available (utilization up from 49%
to 56% with this change), we can be on the comfortable size and
easily have 20 buffers for now.
Future MITM / triple-play applications likely need more.
Change-Id: I022ba3bb3e1f5fd0c364aafe1a23f8fd9b2d8499
Related: OS#4251
-rw-r--r-- | firmware/libcommon/source/pseudo_talloc.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/firmware/libcommon/source/pseudo_talloc.c b/firmware/libcommon/source/pseudo_talloc.c index 7c452b3..3407a59 100644 --- a/firmware/libcommon/source/pseudo_talloc.c +++ b/firmware/libcommon/source/pseudo_talloc.c @@ -22,7 +22,9 @@ #include "utils.h" #include <osmocom/core/utils.h> -#define NUM_RCTX_SMALL 10 +/* TODO: this number should dynamically scale. We need at least one per IN/IRQ endpoint, + * as well as at least 3 for every OUT endpoint. Plus some more depending on the application */ +#define NUM_RCTX_SMALL 20 #define RCTX_SIZE_SMALL 348 static uint8_t msgb_data[NUM_RCTX_SMALL][RCTX_SIZE_SMALL] __attribute__((aligned(sizeof(long)))); |