laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/41935?usp=email )
Change subject: bts: rename g_next_meas_res_nr / g_first_meas_res ......................................................................
bts: rename g_next_meas_res_nr / g_first_meas_res
These variables are used by as_rsl_meas_res() to track MEASurement RESult PDUs on the A-bis/RSL link. Clarify their names.
Change-Id: Iceb58bb636817afcd0fdf1eb3344d03153860a56 Related: OS#6933 --- M bts/BTS_Tests.ttcn 1 file changed, 13 insertions(+), 11 deletions(-)
Approvals: Jenkins Builder: Verified pespin: Looks good to me, approved
diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn index 960761f..940b409 100644 --- a/bts/BTS_Tests.ttcn +++ b/bts/BTS_Tests.ttcn @@ -218,8 +218,10 @@ timer g_Tmeas_exp := 2.0; /* >= 103 SACCH multiframe ~ 500ms */
var ConnHdlrPars g_pars; - var uint8_t g_next_meas_res_nr := 0; - var boolean g_first_meas_res := true; + + /* RSL MEASurement RESult params for as_rsl_meas_res() */ + var uint8_t g_rsl_meas_res_nr := 0; + var boolean g_rsl_meas_res_first := true;
/* PCU Interface of BTS */ port PCUIF_CODEC_PT PCU; @@ -2336,7 +2338,7 @@ }; var uint8_t offs := toffs256s_to_rsl(l1p.timing_offset_256syms); var template uint8_t t_toffs := f_tolerance(offs, 0, 255, mp_tolerance_timing_offset_256syms/256); - return tr_RSL_MEAS_RES_OSMO(g_chan_nr, g_next_meas_res_nr, ul_meas, bs_power, l1_info, + return tr_RSL_MEAS_RES_OSMO(g_chan_nr, g_rsl_meas_res_nr, ul_meas, bs_power, l1_info, ?, t_toffs); }
@@ -2372,7 +2374,7 @@ power_level := l1p.bs_power_level };
- return tr_RSL_MEAS_RES_EMPTY(g_chan_nr, g_next_meas_res_nr, ul_meas, bs_power); + return tr_RSL_MEAS_RES_EMPTY(g_chan_nr, g_rsl_meas_res_nr, ul_meas, bs_power); }
/* verify we regularly receive measurement reports on RSL with incrementing numbers */ @@ -2387,7 +2389,7 @@ * comming back as we expect them. */ [] RSL.receive(f_build_meas_res_tmpl()) -> value rsl { /* increment counter of next to-be-expected meas rep */ - g_next_meas_res_nr := (g_next_meas_res_nr + 1) mod 256; + g_rsl_meas_res_nr := (g_rsl_meas_res_nr + 1) mod 256; /* Re-start the timer expecting the next MEAS RES */ f_timer_safe_restart(g_Tmeas_exp);
@@ -2407,7 +2409,7 @@ * information of the MS. This is normal and we tolerate this behavior. */ [chan_est == false] RSL.receive(f_build_meas_res_tmpl_empty()) -> value rsl { /* increment counter of next to-be-expected meas rep */ - g_next_meas_res_nr := (g_next_meas_res_nr + 1) mod 256; + g_rsl_meas_res_nr := (g_rsl_meas_res_nr + 1) mod 256; /* Re-start the timer expecting the next MEAS RES */ f_timer_safe_restart(g_Tmeas_exp); repeat; @@ -2419,11 +2421,11 @@ * report or a hardcoded one. If TRXCON picks the hardcoded measurement * report the templates above will not match. We tolerate this * behavior, but only once. */ - [chan_est == false] RSL.receive(tr_RSL_MEAS_RES(g_chan_nr, g_next_meas_res_nr)) -> value rsl { + [chan_est == false] RSL.receive(tr_RSL_MEAS_RES(g_chan_nr, g_rsl_meas_res_nr)) -> value rsl { /* increment counter of next to-be-expected meas rep */ - g_next_meas_res_nr := (g_next_meas_res_nr + 1) mod 256; - if (g_first_meas_res) { - g_first_meas_res := false; + g_rsl_meas_res_nr := (g_rsl_meas_res_nr + 1) mod 256; + if (g_rsl_meas_res_first) { + g_rsl_meas_res_first := false; repeat; } else { Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, log2str("Received unspecific MEAS RES ", rsl)); @@ -2579,7 +2581,7 @@ amr_codecs_bitmask := amr_codecs_bitmask)); }
- g_first_meas_res := true; + g_rsl_meas_res_first := true; }
private function get_start_amr_ft() runs on ConnHdlr return integer {