dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/33796 )
Change subject: PCU_Tests: use PCUIF v.11 exclusively ......................................................................
PCU_Tests: use PCUIF v.11 exclusively
OsmoPCU has support for PCUIF v.11 for quite some time now. Let's upgrade the testsuite as well.
Related: OS#5927 Change-Id: I6c4042f2224cd48aecc1b1499226f7d23caddd4f --- M pcu/GPRS_Components.ttcn M pcu/PCU_Tests.default 2 files changed, 35 insertions(+), 15 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/96/33796/1
diff --git a/pcu/GPRS_Components.ttcn b/pcu/GPRS_Components.ttcn index 64a39dd..9d3aeec 100644 --- a/pcu/GPRS_Components.ttcn +++ b/pcu/GPRS_Components.ttcn @@ -628,7 +628,7 @@ ms.ul_tbf := f_ultbf_new_from_rr_imm_ass(rr_imm_ass); }
-function f_ms_exp_dl_tbf_ass_ccch(inout GprsMS ms, template PCUIF_Sapi sapi := PCU_IF_SAPI_PCH, +function f_ms_exp_dl_tbf_ass_ccch(inout GprsMS ms, template PCUIF_Sapi sapi := PCU_IF_SAPI_PCH_DT, template GsmRrMessage t_imm_ass := tr_IMM_TBF_ASS(true, ?, ?), template (present) TsTrxBtsNum nr := tr_TsTrxBtsNum) runs on MS_BTS_IFACE_CT { @@ -862,24 +862,31 @@ /* This function can be used to send DATA.cnf in response to the IUT originated DATA.req. */ function f_pcuif_tx_data_cnf(in BTS_CCCH_Block data_msg) runs on MS_BTS_IFACE_CT { - var PCUIF_Message pcu_msg_cnf := { - msg_type := PCU_IF_MSG_DATA_CNF, - bts_nr := data_msg.bts_nr, - spare := '0000'O, - u := { data_cnf := data_msg.raw } + var PCUIF_data_cnf_dt cnf_dt := { + sapi := data_msg.raw.sapi, + tlli := data_msg.tlli, + fn := data_msg.raw.fn, + /* TODO: The following fields are unused, remove them (in pcuif_proto.h and in PCUIF_Types.ttcn) */ + arfcn := 0, + trx_nr := 0, + ts_nr := 0, + block_nr := 0, + rssi := 0, + ber10k := 0, + ta_offs_qbits := 0, + lqual_cb := 0 };
- /* PCU wants DATA.cnf containing basically everything that was in DATA.req, - * but PCU_IF_SAPI_PCH is a special case - paging group shall be excluded. */ - if (data_msg.raw.sapi == PCU_IF_SAPI_PCH) { - pcu_msg_cnf.u.data_cnf.data := substr(data_msg.raw.data, 3, - data_msg.raw.len - 3); - } + var PCUIF_Message pcu_msg_cnf := { + msg_type := PCU_IF_MSG_DATA_CNF_DT, + bts_nr := data_msg.bts_nr, + spare := '0000'O, + u := { data_cnf_dt := cnf_dt} + };
BTS.send(pcu_msg_cnf); }
- private function f_ms_gtfi_tmpl(inout GprsMS ms) runs on MS_BTS_IFACE_CT return template (present) GlobalTfi { var template (present) GlobalTfi gtfi; @@ -1054,7 +1061,7 @@ rr_imm_ass := data_msg.rr_msg; log("Rx Immediate Assignment: ", rr_imm_ass); /* Send DATA.cnf back to the IUT (only needed for PCH) */ - if (data_msg.raw.sapi == PCU_IF_SAPI_PCH) { + if (data_msg.raw.sapi == PCU_IF_SAPI_PCH_DT) { f_pcuif_tx_data_cnf(data_msg); } setverdict(pass); diff --git a/pcu/PCU_Tests.default b/pcu/PCU_Tests.default index 6f633d2..07d1ffc 100644 --- a/pcu/PCU_Tests.default +++ b/pcu/PCU_Tests.default @@ -29,7 +29,7 @@ } }; Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU"; -PCUIF_Types.mp_pcuif_version := 10; +PCUIF_Types.mp_pcuif_version := 11;
[TESTPORT_PARAMETERS] *.PCU.socket_type := "SEQPACKET"