ggsn: Configure GTP_CodecPort to decode proper UpdatePDPContextRequest/Response
From GTPC_Types.ttcn:
"""
// determines SUT, needed for decoding updatePDPContextRequest
// and updatePDPContextResponse messages
type enumerated SystemUnderTest{SGSN(0),GGSN(1),CGW(2),MME(3)};
"""
Otherwise decoded UpdatePDPContextResponse is decoded taking choise
UpdatePDPContextResponseSGSN.
Change-Id: I52a27222d0e37ed2170972af3fd0e07da49a8c61
diff --git a/ggsn_tests/GGSN_Tests.default b/ggsn_tests/GGSN_Tests.default
index 4d52e24..33b96cb 100644
--- a/ggsn_tests/GGSN_Tests.default
+++ b/ggsn_tests/GGSN_Tests.default
@@ -21,5 +21,6 @@
GGSN_Tests.m_ggsn_ip6_dns1 := "2001:4860:4860::8888"
GGSN_Tests.m_ggsn_ip6_dns2 := "2001:4860:4860::8844"
Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoGGSN";
+GTP_CodecPort.mp_pl_SystemUnderTest := GGSN;
[EXECUTE]
diff --git a/library/GTP_CodecPort.ttcn b/library/GTP_CodecPort.ttcn
index a8507a6..317210e 100644
--- a/library/GTP_CodecPort.ttcn
+++ b/library/GTP_CodecPort.ttcn
@@ -15,6 +15,10 @@
import from GTPC_Types all;
import from GTPU_Types all;
+ modulepar {
+ SystemUnderTest mp_pl_SystemUnderTest := SGSN;
+ }
+
/* identifies a remote peer (sender or receiver) */
type record GtpPeer {
ConnectionId connId,
@@ -58,7 +62,7 @@
out_ud.peer.connId := in_ud.connId;
out_ud.peer.remName := in_ud.remName;
out_ud.peer.remPort := in_ud.remPort;
- out_ud.gtpc := dec_PDU_GTPC(in_ud.msg);
+ out_ud.gtpc := dec_PDU_GTPC(in_ud.msg, pl_SystemUnderTest := mp_pl_SystemUnderTest);
} with { extension "prototype(fast)" };