aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2023-12-21 19:15:31 +0100
committerPau Espin Pedrol <pespin@sysmocom.de>2023-12-21 19:15:33 +0100
commita5bb8076a0fdc24952ef13acdde2b3ae9c1de568 (patch)
tree6adaea52acf21611b27d90c4e74d115681c76e63
parent2f32707d9bbb96090894e2031f733609550973d1 (diff)
S1AP_Emulation: Allow retrieving {MME,ENB}_UE_ID from UeContextReleaseCmd
It's not true that it can contain several IDs. The only difference is that it has a choice IE which can hold a pair containing both MME/ENB UE IDs, or only MME_UE_ID. Change-Id: I4fb51f3f50fa10400184b65d272530ea26a2bc8e
-rw-r--r--library/S1AP_Emulation.ttcn16
1 files changed, 14 insertions, 2 deletions
diff --git a/library/S1AP_Emulation.ttcn b/library/S1AP_Emulation.ttcn
index 9f362251..401a26ea 100644
--- a/library/S1AP_Emulation.ttcn
+++ b/library/S1AP_Emulation.ttcn
@@ -699,7 +699,13 @@ function f_S1AP_get_ENB_UE_S1AP_ID(S1AP_PDU s1ap) return template (omit) ENB_UE_
case (tr_S1AP_UeContextReleaseReq) {
return im.value_.UEContextReleaseRequest.protocolIEs[1].value_.ENB_UE_S1AP_ID;
}
- /* UeContextReleaseCmd needs special handling; it can contain any number of MME/UE IDs */
+ case (tr_S1AP_UeContextReleaseCmd) {
+ if (ispresent(im.value_.uEContextReleaseCommand.protocolIEs[0].value_.uE_S1AP_IDs.uE_S1AP_ID_pair)) {
+ return im.value_.uEContextReleaseCommand.protocolIEs[0].value_.uE_S1AP_IDs.uE_S1AP_ID_pair.eNB_UE_S1AP_ID;
+ } else {
+ return omit;
+ }
+ }
case (tr_S1AP_ConnEstInd) {
return im.value_.ConnectionEstablishmentIndication.protocolIEs[1].value_.ENB_UE_S1AP_ID;
}
@@ -745,7 +751,13 @@ function f_S1AP_get_MME_UE_S1AP_ID(S1AP_PDU s1ap) return template (omit) MME_UE_
case (tr_S1AP_UeContextReleaseReq) {
return im.value_.UEContextReleaseRequest.protocolIEs[0].value_.MME_UE_S1AP_ID;
}
- /* UeContextReleaseCmd needs special handling; it can contain any number of MME/UE IDs */
+ case (tr_S1AP_UeContextReleaseCmd) {
+ if (ispresent(im.value_.uEContextReleaseCommand.protocolIEs[0].value_.uE_S1AP_IDs.uE_S1AP_ID_pair)) {
+ return im.value_.uEContextReleaseCommand.protocolIEs[0].value_.uE_S1AP_IDs.uE_S1AP_ID_pair.mME_UE_S1AP_ID;
+ } else {
+ return im.value_.uEContextReleaseCommand.protocolIEs[0].value_.uE_S1AP_IDs.mME_UE_S1AP_ID;
+ }
+ }
case (tr_S1AP_ConnEstInd) {
return im.value_.ConnectionEstablishmentIndication.protocolIEs[0].value_.MME_UE_S1AP_ID;
}