From 092e4e85b369b3b7a96752ff7727942804029cdb Mon Sep 17 00:00:00 2001 From: Philipp Maier Date: Tue, 21 Aug 2018 15:23:08 +0200 Subject: measurement: fix measurement interval end detection for SDDCH4 channels, the detection is not working correctly since the function uses the lookup table for SDCCH8 interval endings there. This needs to be corrected. Also there are two unnecessary assignments in the code which should be removed. - use correct table (sdcch4_meas_rep_fn102 instead of sdcch8_meas_rep_fn102. - remove unnecessary assignments to last_fn_mod Change-Id: If8a269ecd3f9fa4eeadf379114db816ef5c77d77 Related: OS#2975 --- src/common/measurement.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/common/measurement.c b/src/common/measurement.c index 41844b1f..cb45e6e3 100644 --- a/src/common/measurement.c +++ b/src/common/measurement.c @@ -328,7 +328,6 @@ bool is_meas_overdue(struct gsm_lchan *lchan, uint32_t *fn_missed_end, uint32_t break; case GSM_PCHAN_TCH_H: modulus = 104; - last_fn_mod = lchan->meas.last_fn % 104; if (lchan->nr == 0) tbl = tchh0_meas_rep_fn104; else @@ -339,13 +338,12 @@ bool is_meas_overdue(struct gsm_lchan *lchan, uint32_t *fn_missed_end, uint32_t case GSM_PCHAN_SDCCH8_SACCH8C: case GSM_PCHAN_SDCCH8_SACCH8C_CBCH: modulus = 102; - last_fn_mod = lchan->meas.last_fn % 102; interval_end = sdcch8_meas_rep_fn102[lchan->ts->nr]; break; case GSM_PCHAN_CCCH_SDCCH4: case GSM_PCHAN_CCCH_SDCCH4_CBCH: modulus = 102; - interval_end = sdcch8_meas_rep_fn102[lchan->ts->nr]; + interval_end = sdcch4_meas_rep_fn102[lchan->ts->nr]; break; default: return false; -- cgit v1.2.3