Change in osmo-ttcn3-hacks[master]: bsc: TC_ho_int: verify TSC in HandoverCommand

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

neels gerrit-no-reply at lists.osmocom.org
Mon Oct 4 10:43:10 UTC 2021


neels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/25663 )

Change subject: bsc: TC_ho_int: verify TSC in HandoverCommand
......................................................................

bsc: TC_ho_int: verify TSC in HandoverCommand

For intra-BSC handovers, also verify the correct Training Sequence Code
in the RR Handover Command (not only in the Channel Activation as added
in previous patch).

Related: SYS#4895 OS#5244
Related: Iae20df4387c3d75752301bd5daeeea7508966393 (osmo-bsc)
Change-Id: I32e3553581eb17812082f1f2ee96cc978e8db668
---
M bsc/BSC_Tests.ttcn
M bsc/MSC_ConnectionHandler.ttcn
2 files changed, 21 insertions(+), 4 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, but someone else must approve
  pespin: Looks good to me, but someone else must approve
  neels: Looks good to me, approved



diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn
index e8bb99c..04e895a 100644
--- a/bsc/BSC_Tests.ttcn
+++ b/bsc/BSC_Tests.ttcn
@@ -5079,7 +5079,8 @@
 	var HandoverState hs := {
 		rr_ho_cmpl_seen := false,
 		handover_done := false,
-		old_chan_nr := -
+		old_chan_nr := -,
+		expect_target_tsc := BTS_TSC[1]
 	};
 	/* issue hand-over command on VTY, from BTS 0 to BTS 1 */
 	f_vty_handover(BSCVTY, 0, 0, g_chan_nr, 1);
@@ -5197,7 +5198,8 @@
 	var HandoverState hs := {
 		rr_ho_cmpl_seen := false,
 		handover_done := false,
-		old_chan_nr := -
+		old_chan_nr := -,
+		expect_target_tsc := BTS_TSC[1]
 	};
 	/* issue hand-over command on VTY */
 	f_vty_handover(BSCVTY, 0, 0, g_chan_nr, 1);
@@ -9347,7 +9349,8 @@
 	var HandoverState hs := {
 		rr_ho_cmpl_seen := false,
 		handover_done := false,
-		old_chan_nr := -
+		old_chan_nr := -,
+		expect_target_tsc := BTS_TSC[1]
 	};
 	/* issue hand-over command on VTY */
 	f_vty_handover(BSCVTY, 0, 0, g_chan_nr, 1);
diff --git a/bsc/MSC_ConnectionHandler.ttcn b/bsc/MSC_ConnectionHandler.ttcn
index 5f77764..2b1f711 100644
--- a/bsc/MSC_ConnectionHandler.ttcn
+++ b/bsc/MSC_ConnectionHandler.ttcn
@@ -1467,7 +1467,8 @@
 	boolean rr_ho_cmpl_seen,
 	integer mdcx_seen_before_ho,
 	boolean handover_done,
-	RslChannelNr old_chan_nr
+	RslChannelNr old_chan_nr,
+	uint3_t expect_target_tsc optional
 };
 
 altstep as_handover(inout HandoverState st) runs on MSC_ConnHdlr {
@@ -1482,6 +1483,19 @@
 					   new_chan_nr, arfcn);
 			/* FIXME: Determine TRX NR by ARFCN, instead of hard-coded TRX0! */
 
+			/* Verify correct TSC in handoverCommand */
+			if (ispresent(st.expect_target_tsc)) {
+				var uint3_t got_tsc := rr_chan_desc_tsc(l3.msgs.rrm.handoverCommand.channelDescription2);
+				if (not match(got_tsc, st.expect_target_tsc)) {
+					setverdict(fail, "RR Handover Command: unexpected TSC in Channel Description: expected ",
+						   st.expect_target_tsc, " got ", got_tsc);
+					mtc.stop;
+				} else {
+					log("handoverCommand: verified TSC = ", got_tsc, " (matches ",
+					    st.expect_target_tsc, ")");
+				}
+			}
+
 			/* register our component for this channel number at the RSL Emulation */
 			f_rslem_register(0, new_chan_nr, RSL1_PROC);
 

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/25663
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I32e3553581eb17812082f1f2ee96cc978e8db668
Gerrit-Change-Number: 25663
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20211004/42297f7b/attachment.htm>


More information about the gerrit-log mailing list