From e476629bcff32106e3f8942738da024a85b5bce2 Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Mon, 4 Jan 2021 21:46:00 +0100 Subject: [PATCH] l1sap: fix: enable UL SACCH repetition if RxQual threshold is 0 It is expected that setting RxQual threshold to 0 would make the L1SAP logic enable repetition for both Uplink SACCH and Downlink FACCH unconditionally. However, this was only valid for the later. Let's add the missing check and make it consistent. Change-Id: Ia44a134e7f28ea990798d1b79c87b644504c0876 Related: SYS#5114 --- src/common/l1sap.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/common/l1sap.c b/src/common/l1sap.c index 33d10a5ac..48773f1e1 100644 --- a/src/common/l1sap.c +++ b/src/common/l1sap.c @@ -1408,6 +1408,12 @@ static void repeated_ul_sacch_active_decision(struct gsm_lchan *lchan, if (!lchan->repeated_acch_capability.ul_sacch) return; + /* Threshold disabled (repetition is always on) */ + if (lchan->repeated_acch_capability.rxqual == 0) { + lchan->repeated_ul_sacch_active = true; + return; + } + /* convert from RXQUAL value to ber10k vale, * see also GSM 05.08, section 8.2.4 */ static const uint16_t ber10k_by_rxqual_upper[] =