laforge submitted this change.

View Change

Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved
pcu: TC_paging_cs_from_sgsn_*: Fix race condition between BSSGP tx and RLCMAC rx

It can happen that the RLCMAC req arrives at osmo-pcu before the
CS_PAGING we send to it over BSSGP, in which case osmo-pcu will schedule
an RLCMAC DL Dummy Block. Take into account this scenario to avoid
failing id it occurs.

Change-Id: I30da93835c7738aefcd84691d83f39759dd4b599
---
M pcu/PCU_Tests.ttcn
1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/pcu/PCU_Tests.ttcn b/pcu/PCU_Tests.ttcn
index 4b909c7..876b282 100644
--- a/pcu/PCU_Tests.ttcn
+++ b/pcu/PCU_Tests.ttcn
@@ -3627,8 +3627,16 @@
BSSGP[0].send(ts_BSSGP_CS_PAGING_IMSI(bvci, imsi));
}

- /* Receive it on BTS side towards MS */
- f_rx_rlcmac_dl_block_exp_pkt_pag_req(dl_block);
+ /* Now receive it on BTS side towards MS.
+ * Skip any dummy blocks in case the PCUIF req arrives before the BSSP CS_PAGING:
+ */
+ f_rx_rlcmac_dl_block_skip_dummy(dl_block, max_dummy := 10);
+
+ if (not match(dl_block, tr_RLCMAC_PACKET_PAG_REQ())) {
+ setverdict(fail, "Failed to match Packet Paging Request: ",
+ dl_block, " vs ", tr_RLCMAC_PACKET_PAG_REQ());
+ f_shutdown(__BFILE__, __LINE__);
+ }

/* Make sure that Packet Paging Request contains the same P-TMSI/IMSI */
var PacketPagingReq req := dl_block.ctrl.payload.u.paging;

To view, visit change 30374. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I30da93835c7738aefcd84691d83f39759dd4b599
Gerrit-Change-Number: 30374
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: laforge <laforge@osmocom.org>
Gerrit-MessageType: merged