aboutsummaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2018-07-13 15:07:43 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2018-07-13 19:16:22 +0200
commit67e47dd328af6447a158929ed726075f1431a0d9 (patch)
treee1f76d0e26d0f9ce059aa9cde207062b72091e1e /library
parent8466722f3f40bc2aea021fa061e122743c4ad0ab (diff)
lib: L3_Templates: Fix DEACT PDP REQ msg type and make tearDownInd optional
Specs state in 3GPP TS 24.008 that TearDownInd IE is optional, so allow possibility to omit it. Also fix protocolConfigOpts being passed as parameter but not being used in template tr_SM_DEACT_PDP_REQ_MT. Change-Id: I006d64f51c17a22a42a225ddfa4119933e48a022
Diffstat (limited to 'library')
-rw-r--r--library/L3_Templates.ttcn67
1 files changed, 33 insertions, 34 deletions
diff --git a/library/L3_Templates.ttcn b/library/L3_Templates.ttcn
index 9d6d3c31..44d9e73d 100644
--- a/library/L3_Templates.ttcn
+++ b/library/L3_Templates.ttcn
@@ -2254,6 +2254,22 @@ function ts_PcoTLV(template (omit) ProtocolConfigOptionsV pco)
}
}
+function ts_TearDownIndicatorTV(in template (omit) boolean ind)
+ return template (omit) TearDownIndicatorTV {
+ if (istemplatekind(ind, "omit")) {
+ return omit;
+ } else {
+ var template (omit) TearDownIndicatorTV ret := {
+ tearDownIndicatorV := {
+ tdi_flag := bool2bit(valueof(ind)),
+ spare := '000'B
+ },
+ elementIdentifier := '1001'B
+ }
+ return ret;
+ }
+}
+
template (value) PDU_L3_MS_SGSN ts_SM_ACT_PDP_REQ(BIT3 tid, BIT4 nsapi, BIT4 sapi, QoSV qos,
PDPAddressV addr,
template (omit) octetstring apn := omit,
@@ -2348,10 +2364,11 @@ template PDU_L3_SGSN_MS tr_SM_ACT_PDP_ACCEPT(template BIT3 tid := ?, template BI
}
}
-template (value) PDU_L3_MS_SGSN ts_SM_DEACT_PDP_REQ_MO(BIT3 tid, OCT1 cause, boolean tdown := false,
+template (value) PDU_L3_MS_SGSN ts_SM_DEACT_PDP_REQ_MO(BIT3 tid, OCT1 cause,
+ template (omit) boolean tdown := omit,
template (omit) ProtocolConfigOptionsV pco := omit
) := {
- discriminator := '0000'B, /* overwritten */
+ discriminator := '1010'B,
tiOrSkip := {
transactionId := {
tio := tid,
@@ -2362,15 +2379,9 @@ template (value) PDU_L3_MS_SGSN ts_SM_DEACT_PDP_REQ_MO(BIT3 tid, OCT1 cause, boo
msgs := {
gprs_sm := {
deactivatePDPContextRequest := {
- messageType := '00000000'B, /* overwritten */
+ messageType := '01000110'B,
smCause := cause,
- tearDownIndicator := {
- tearDownIndicatorV := {
- tdi_flag := bool2bit(tdown),
- spare := '000'B
- },
- elementIdentifier := '1001'B
- },
+ tearDownIndicator := ts_TearDownIndicatorTV(tdown),
protocolConfigOpts := ts_PcoTLV(pco),
mBMSprotocolConfigOptions := omit,
t3396 := omit,
@@ -2381,10 +2392,11 @@ template (value) PDU_L3_MS_SGSN ts_SM_DEACT_PDP_REQ_MO(BIT3 tid, OCT1 cause, boo
}
}
-template (value) PDU_L3_SGSN_MS ts_SM_DEACT_PDP_REQ_MT(BIT3 tid, OCT1 cause, boolean tdown := false,
+template (value) PDU_L3_SGSN_MS ts_SM_DEACT_PDP_REQ_MT(BIT3 tid, OCT1 cause,
+ template (omit) boolean tdown := omit,
template (omit) ProtocolConfigOptionsV pco := omit
) := {
- discriminator := '0000'B, /* overwritten */
+ discriminator := '1010'B,
tiOrSkip := {
transactionId := {
tio := tid,
@@ -2395,15 +2407,9 @@ template (value) PDU_L3_SGSN_MS ts_SM_DEACT_PDP_REQ_MT(BIT3 tid, OCT1 cause, boo
msgs := {
gprs_sm := {
deactivatePDPContextRequest := {
- messageType := '00000000'B, /* overwritten */
+ messageType := '01000110'B,
smCause := cause,
- tearDownIndicator := {
- tearDownIndicatorV := {
- tdi_flag := bool2bit(tdown),
- spare := '000'B
- },
- elementIdentifier := '1001'B
- },
+ tearDownIndicator := ts_TearDownIndicatorTV(tdown),
protocolConfigOpts := ts_PcoTLV(pco),
mBMSprotocolConfigOptions := omit,
t3396 := omit,
@@ -2415,10 +2421,10 @@ template (value) PDU_L3_SGSN_MS ts_SM_DEACT_PDP_REQ_MT(BIT3 tid, OCT1 cause, boo
}
template PDU_L3_SGSN_MS tr_SM_DEACT_PDP_REQ_MT(template BIT3 tid, template OCT1 cause,
- template boolean tdown := false,
- template (omit) ProtocolConfigOptionsV pco := omit
- ) := {
- discriminator := '0000'B, /* overwritten */
+ template (omit) boolean tdown := omit,
+ template (omit) ProtocolConfigOptionsV pco := omit
+ ) := {
+ discriminator := '1010'B,
tiOrSkip := {
transactionId := {
tio := tid,
@@ -2429,16 +2435,10 @@ template PDU_L3_SGSN_MS tr_SM_DEACT_PDP_REQ_MT(template BIT3 tid, template OCT1
msgs := {
gprs_sm := {
deactivatePDPContextRequest := {
- messageType := '00000000'B, /* overwritten */
+ messageType := '01000110'B,
smCause := cause,
- tearDownIndicator := {
- tearDownIndicatorV := {
- tdi_flag := bool2bit_tmpl(tdown),
- spare := '000'B
- },
- elementIdentifier := '1001'B
- },
- protocolConfigOpts := *,
+ tearDownIndicator := ts_TearDownIndicatorTV(tdown),
+ protocolConfigOpts := ts_PcoTLV(pco),
mBMSprotocolConfigOptions := *,
t3396 := *,
wLANOffloadIndication := *,
@@ -2448,7 +2448,6 @@ template PDU_L3_SGSN_MS tr_SM_DEACT_PDP_REQ_MT(template BIT3 tid, template OCT1
}
}
-
template PDU_L3_SGSN_MS tr_SM_DEACT_PDP_ACCEPT_MT(template BIT3 tid := ?)
:= {
discriminator := '1010'B,