summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2020-06-12 16:16:55 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2020-06-20 21:43:21 +0200
commit90f8096890902c4fd632c592591ddb0c4dcf6b3c (patch)
tree3f4bbe5556ce0f932c2c2efc2327bbfd4295dcbf
parent4f11841173c929ecf5113622706eea3818ee5529 (diff)
bsc: undup pars.sccp_addr_msc and _bsc
Handover testing required passing MSC and BSC addresses to f_tc_* functions and added pars.handover.sccp_addr_msc and .handover.sccp_addr_bsc. MSC pool tests added a separate sub-record pars.mscpool which also contains these two fields. Move them both up one level, to form a single pair of pars.sccp_addr_msc and pars.sccp_addr_bsc. This eliminates the pars.handover sub-record. Change-Id: Iae81ca58001455099218ce769a97dc6402832490
-rw-r--r--bsc/BSC_Tests.ttcn42
-rw-r--r--bsc/MSC_ConnectionHandler.ttcn15
2 files changed, 25 insertions, 32 deletions
diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn
index 377b193..485411b 100644
--- a/bsc/BSC_Tests.ttcn
+++ b/bsc/BSC_Tests.ttcn
@@ -3313,7 +3313,7 @@ private function f_tc_ho_into_this_bsc(charstring id) runs on MSC_ConnHdlr {
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
activate(as_Media());
- BSSAP.send(ts_BSSAP_Conn_Req(g_pars.handover.sccp_addr_bsc, g_pars.handover.sccp_addr_msc,
+ BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
f_gen_handover_req()));
BSSAP.receive(RAN_Conn_Prim:MSC_CONN_PRIM_CONF_IND);
@@ -3368,8 +3368,8 @@ testcase TC_ho_into_this_bsc() runs on test_CT {
f_init(1, true);
f_sleep(1.0);
- pars.handover.sccp_addr_msc := g_bssap[0].sccp_addr_own;
- pars.handover.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
+ pars.sccp_addr_msc := g_bssap[0].sccp_addr_own;
+ pars.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
vc_conn := f_start_handler(refers(f_tc_ho_into_this_bsc), pars);
vc_conn.done;
@@ -3385,7 +3385,7 @@ private function f_tc_ho_in_fail_msc_clears(charstring id) runs on MSC_ConnHdlr
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
activate(as_Media());
- BSSAP.send(ts_BSSAP_Conn_Req(g_pars.handover.sccp_addr_bsc, g_pars.handover.sccp_addr_msc,
+ BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
f_gen_handover_req()));
BSSAP.receive(RAN_Conn_Prim:MSC_CONN_PRIM_CONF_IND);
@@ -3441,8 +3441,8 @@ testcase TC_ho_in_fail_msc_clears() runs on test_CT {
f_init(1, true);
f_sleep(1.0);
- pars.handover.sccp_addr_msc := g_bssap[0].sccp_addr_own;
- pars.handover.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
+ pars.sccp_addr_msc := g_bssap[0].sccp_addr_own;
+ pars.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
vc_conn := f_start_handler(refers(f_tc_ho_in_fail_msc_clears), pars);
vc_conn.done;
@@ -3463,7 +3463,7 @@ private function f_tc_ho_in_fail_msc_clears_after_ho_detect(charstring id) runs
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
activate(as_Media());
- BSSAP.send(ts_BSSAP_Conn_Req(g_pars.handover.sccp_addr_bsc, g_pars.handover.sccp_addr_msc,
+ BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
f_gen_handover_req()));
BSSAP.receive(RAN_Conn_Prim:MSC_CONN_PRIM_CONF_IND);
@@ -3521,8 +3521,8 @@ testcase TC_ho_in_fail_msc_clears_after_ho_detect() runs on test_CT {
f_init(1, true);
f_sleep(1.0);
- pars.handover.sccp_addr_msc := g_bssap[0].sccp_addr_own;
- pars.handover.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
+ pars.sccp_addr_msc := g_bssap[0].sccp_addr_own;
+ pars.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
vc_conn := f_start_handler(refers(f_tc_ho_in_fail_msc_clears_after_ho_detect), pars);
vc_conn.done;
@@ -3539,7 +3539,7 @@ private function f_tc_ho_in_fail_no_detect(charstring id) runs on MSC_ConnHdlr {
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
activate(as_Media());
- BSSAP.send(ts_BSSAP_Conn_Req(g_pars.handover.sccp_addr_bsc, g_pars.handover.sccp_addr_msc,
+ BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
f_gen_handover_req()));
BSSAP.receive(RAN_Conn_Prim:MSC_CONN_PRIM_CONF_IND);
@@ -3602,8 +3602,8 @@ testcase TC_ho_in_fail_no_detect() runs on test_CT {
f_init(1, true);
f_sleep(1.0);
- pars.handover.sccp_addr_msc := g_bssap[0].sccp_addr_own;
- pars.handover.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
+ pars.sccp_addr_msc := g_bssap[0].sccp_addr_own;
+ pars.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
vc_conn := f_start_handler(refers(f_tc_ho_in_fail_no_detect), pars);
vc_conn.done;
@@ -3620,7 +3620,7 @@ private function f_tc_ho_in_fail_no_detect2(charstring id) runs on MSC_ConnHdlr
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
activate(as_Media());
- BSSAP.send(ts_BSSAP_Conn_Req(g_pars.handover.sccp_addr_bsc, g_pars.handover.sccp_addr_msc,
+ BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
f_gen_handover_req()));
BSSAP.receive(RAN_Conn_Prim:MSC_CONN_PRIM_CONF_IND);
@@ -3673,8 +3673,8 @@ testcase TC_ho_in_fail_no_detect2() runs on test_CT {
f_init(1, true);
f_sleep(1.0);
- pars.handover.sccp_addr_msc := g_bssap[0].sccp_addr_own;
- pars.handover.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
+ pars.sccp_addr_msc := g_bssap[0].sccp_addr_own;
+ pars.sccp_addr_bsc := g_bssap[0].sccp_addr_peer;
vc_conn := f_start_handler(refers(f_tc_ho_in_fail_no_detect2), pars);
vc_conn.done;
@@ -4901,7 +4901,7 @@ private function f_tc_mscpool_paging_imsi(charstring id) runs on MSC_ConnHdlr {
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
- paging := valueof(ts_BSSAP_UNITDATA_req(g_pars.mscpool.sccp_addr_bsc, g_pars.mscpool.sccp_addr_msc,
+ paging := valueof(ts_BSSAP_UNITDATA_req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
valueof(ts_BSSMAP_Paging(imsi, cid_list, omit, bssmap_chneed))));
BSSAP.send(paging);
@@ -4930,8 +4930,8 @@ testcase TC_mscpool_paging_and_response_imsi() runs on test_CT {
var MSC_ConnHdlr vc_conn1;
var TestHdlrParams pars1 := f_gen_test_hdlr_pars(bssap_idx := 0);
pars1.mscpool.rsl_idx := 0;
- pars1.mscpool.sccp_addr_bsc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_peer;
- pars1.mscpool.sccp_addr_msc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_own;
+ pars1.sccp_addr_bsc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_peer;
+ pars1.sccp_addr_msc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_own;
vc_conn1 := f_start_handler(refers(f_tc_mscpool_paging_imsi), pars1);
vc_conn1.done;
}
@@ -4949,7 +4949,7 @@ private function f_tc_mscpool_paging_tmsi(charstring id) runs on MSC_ConnHdlr {
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
- paging := valueof(ts_BSSAP_UNITDATA_req(g_pars.mscpool.sccp_addr_bsc, g_pars.mscpool.sccp_addr_msc,
+ paging := valueof(ts_BSSAP_UNITDATA_req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
valueof(ts_BSSMAP_Paging('001010000000011'H, cid_list, tmsi, bssmap_chneed))));
BSSAP.send(paging);
@@ -4979,8 +4979,8 @@ testcase TC_mscpool_paging_and_response_tmsi() runs on test_CT {
var MSC_ConnHdlr vc_conn1;
var TestHdlrParams pars1 := f_gen_test_hdlr_pars(bssap_idx := 0);
pars1.mscpool.rsl_idx := 0;
- pars1.mscpool.sccp_addr_bsc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_peer;
- pars1.mscpool.sccp_addr_msc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_own;
+ pars1.sccp_addr_bsc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_peer;
+ pars1.sccp_addr_msc := g_bssap[pars1.mscpool.bssap_idx].sccp_addr_own;
vc_conn1 := f_start_handler(refers(f_tc_mscpool_paging_tmsi), pars1);
vc_conn1.done;
}
diff --git a/bsc/MSC_ConnectionHandler.ttcn b/bsc/MSC_ConnectionHandler.ttcn
index fece825..8ac7051 100644
--- a/bsc/MSC_ConnectionHandler.ttcn
+++ b/bsc/MSC_ConnectionHandler.ttcn
@@ -509,15 +509,8 @@ type record TestHdlrParamsLcls {
boolean adjust_cx_exp
}
-type record TestHdlrParamsHandover {
- SCCP_PAR_Address sccp_addr_msc,
- SCCP_PAR_Address sccp_addr_bsc
-}
-
type record TestHdlrParamsMSCPool {
integer bssap_idx,
- SCCP_PAR_Address sccp_addr_msc optional,
- SCCP_PAR_Address sccp_addr_bsc optional,
integer rsl_idx,
PDU_ML3_MS_NW l3_info optional
}
@@ -533,7 +526,8 @@ type record TestHdlrParams {
bitstring expect_mr_s0_s7 optional, /* typically present for AMR codecs */
TestHdlrEncrParams encr optional,
TestHdlrParamsLcls lcls,
- TestHdlrParamsHandover handover optional,
+ SCCP_PAR_Address sccp_addr_msc optional,
+ SCCP_PAR_Address sccp_addr_bsc optional,
uint5_t exp_ms_power_level,
boolean exp_ms_power_params,
boolean aoip,
@@ -561,15 +555,14 @@ template (value) TestHdlrParams t_def_TestHdlrPars := {
exp_sts := omit,
adjust_cx_exp := true
},
- handover := omit,
+ sccp_addr_msc := omit,
+ sccp_addr_bsc := omit,
exp_ms_power_level := 7, /* calculated from osmo-bsc.cfg "ms max power" */
exp_ms_power_params := false,
aoip := true,
use_osmux := false,
mscpool := {
bssap_idx := 0,
- sccp_addr_msc := omit,
- sccp_addr_bsc := omit,
rsl_idx := 0,
l3_info := omit
}