From 7be36cfde6a728857c6ec77e12aa6125e8209b5d Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Mon, 25 Oct 2021 19:01:50 +0200 Subject: Set subslots_per_pchan_vamos[GSM_PCHAN_OSMO_DYN] = 0 VAMOS secondary lchans are to be used specifically when the osmocom dyn TS is set to pchan_is=TCH_{F,H}. Setting secondary subslots for OSMO_DYN TS is not needed since it's only used to initialize the TS, and OSMO DYN already initializes 8 subslots (subslots_per_pchan[GSM_PCHAN_OSMO_DYN]=8). Otherwise, ts_setup_lchans() will try to initialize 8+2 lchans on the TS, which is more than needed and will access out of bounds in the array. Related: OS#5278 Change-Id: I8727d5b446179c0ebcd8738507efe5a50afaf1e2 --- src/osmo-bsc/gsm_data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osmo-bsc/gsm_data.c b/src/osmo-bsc/gsm_data.c index b0e0a68d1..0134e34c9 100644 --- a/src/osmo-bsc/gsm_data.c +++ b/src/osmo-bsc/gsm_data.c @@ -633,7 +633,7 @@ static const uint8_t subslots_per_pchan_vamos[] = { [GSM_PCHAN_SDCCH8_SACCH8C] = 0, [GSM_PCHAN_CCCH_SDCCH4_CBCH] = 0, [GSM_PCHAN_SDCCH8_SACCH8C_CBCH] = 0, - [GSM_PCHAN_OSMO_DYN] = 2, + [GSM_PCHAN_OSMO_DYN] = 0, [GSM_PCHAN_TCH_F_PDCH] = 2, }; -- cgit v1.2.3