Attention is currently required from: fixeria, pespin.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35356?usp=email )
Change subject: library/GTPv2_Templates: Fix seq nr not set in ts_GTP2C_DeleteSessionResp
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35356?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I8409eb35fc2f0bda6c5e11ae5c3d7628503bb2cd
Gerrit-Change-Number: 35356
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 13 Dec 2023 21:34:42 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35358?usp=email )
Change subject: library/GTPv2_Emulation: Patch SeqNr only on outbound initial messages
......................................................................
library/GTPv2_Emulation: Patch SeqNr only on outbound initial messages
Change-Id: I0f13074ccee2bf2d00d2dc2af491b9effc142f22
---
M library/GTPv2_Emulation.ttcn
1 file changed, 86 insertions(+), 8 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/58/35358/1
diff --git a/library/GTPv2_Emulation.ttcn b/library/GTPv2_Emulation.ttcn
index 736dd03..0b2cb4f 100644
--- a/library/GTPv2_Emulation.ttcn
+++ b/library/GTPv2_Emulation.ttcn
@@ -340,6 +340,73 @@
return omit;
}
+private function f_gtp2c_is_initial_msg(PDU_GTPCv2 msg) return boolean
+{
+ if (ischosen(msg.gtpcv2_pdu.echoRequest) or
+ ischosen(msg.gtpcv2_pdu.versionNotSupported) or
+ ischosen(msg.gtpcv2_pdu.createSessionRequest) or
+ ischosen(msg.gtpcv2_pdu.createBearerRequest) or
+ ischosen(msg.gtpcv2_pdu.bearerResourceCommand) or
+ ischosen(msg.gtpcv2_pdu.bearerResourceFailureIndication) or
+ ischosen(msg.gtpcv2_pdu.modifyBearerRequest) or
+ ischosen(msg.gtpcv2_pdu.deleteSessionRequest) or
+ ischosen(msg.gtpcv2_pdu.deleteBearerRequest) or
+ ischosen(msg.gtpcv2_pdu.downlinkDataNotification) or
+ ischosen(msg.gtpcv2_pdu.downlinkDataNotificationAcknowledgement) or
+ ischosen(msg.gtpcv2_pdu.downlinkDataNotificationFailureIndication) or
+ ischosen(msg.gtpcv2_pdu.deleteIndirectDataForwardingTunnelRequest) or
+ ischosen(msg.gtpcv2_pdu.modifyBearerCommand) or
+ ischosen(msg.gtpcv2_pdu.modifyBearerFailureIndication) or
+ ischosen(msg.gtpcv2_pdu.updateBearerRequest) or
+ ischosen(msg.gtpcv2_pdu.deleteBearerCommand) or
+ ischosen(msg.gtpcv2_pdu.createIndirectDataForwardingTunnelRequest) or
+ ischosen(msg.gtpcv2_pdu.releaseAccessBearersRequest) or
+ ischosen(msg.gtpcv2_pdu.stopPagingIndication) or
+ ischosen(msg.gtpcv2_pdu.modifyAccessBearersRequest) or
+ ischosen(msg.gtpcv2_pdu.remoteUEReportNotification) or
+ ischosen(msg.gtpcv2_pdu.remoteUEReportAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.forwardRelocationRequest) or
+ ischosen(msg.gtpcv2_pdu.forwardRelocationCompleteNotification) or
+ ischosen(msg.gtpcv2_pdu.forwardRelocationCompleteAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.contextRequest) or
+ ischosen(msg.gtpcv2_pdu.contextAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.identificationRequest) or
+ ischosen(msg.gtpcv2_pdu.forwardAccessContextNotification) or
+ ischosen(msg.gtpcv2_pdu.forwardAccessContextAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.detachNotification) or
+ ischosen(msg.gtpcv2_pdu.detachAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.changeNotificationRequest) or
+ ischosen(msg.gtpcv2_pdu.relocationCancelRequest) or
+ ischosen(msg.gtpcv2_pdu.configurationTransferTunnel) or
+ ischosen(msg.gtpcv2_pdu.rAN_InformationRelay) or
+ ischosen(msg.gtpcv2_pdu.suspendNotification) or
+ ischosen(msg.gtpcv2_pdu.suspendAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.resumeNotification) or
+ ischosen(msg.gtpcv2_pdu.resumeAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.cSPagingIndication) or
+ ischosen(msg.gtpcv2_pdu.createForwardingTunnelRequest) or
+ ischosen(msg.gtpcv2_pdu.deletePDN_ConnectionSetRequest) or
+ ischosen(msg.gtpcv2_pdu.traceSessionActivation) or
+ ischosen(msg.gtpcv2_pdu.traceSessionDeactivation) or
+ ischosen(msg.gtpcv2_pdu.updatePDN_ConnectionSetRequest) or
+ ischosen(msg.gtpcv2_pdu.pGW_RestartNotification) or
+ ischosen(msg.gtpcv2_pdu.pGW_RestartNotificationAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.pGW_DownlinkTriggeringNotification) or
+ ischosen(msg.gtpcv2_pdu.pGW_DownlinkTriggeringAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.alertMMENotification) or
+ ischosen(msg.gtpcv2_pdu.alertMMEAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.uEActivityNotification) or
+ ischosen(msg.gtpcv2_pdu.uEActivityAcknowledge) or
+ ischosen(msg.gtpcv2_pdu.mBMSSessionStartRequest) or
+ ischosen(msg.gtpcv2_pdu.mBMSSessionUpdateRequest) or
+ ischosen(msg.gtpcv2_pdu.mBMSSessionStopRequest) or
+ ischosen(msg.gtpcv2_pdu.iSR_StatusIndication) or
+ ischosen(msg.gtpcv2_pdu.uE_RegistrationQueryRequest)) {
+ return true;
+ }
+ return false;
+}
+
private template (value) SctpTuple ts_SCTP(template (omit) integer ppid := omit) := {
sinfo_stream := omit,
sinfo_ppid := ppid,
@@ -507,10 +574,11 @@
}
[] TEID0.receive(PDU_GTPCv2:?) -> value g2c sender vc_conn {
- /* patch in the next sequence number */
- /* FIXME: do this only for outbound requests */
- g2c.sequenceNumber := int2oct(g_c_seq_nr, 3);
- g_c_seq_nr := g_c_seq_nr + 1;
+ /* patch in the next sequence number on outbound Initial message */
+ if (f_gtp2c_is_initial_msg(g2c)) {
+ g2c.sequenceNumber := int2oct(g_c_seq_nr, 3);
+ g_c_seq_nr := g_c_seq_nr + 1;
+ }
/* build Gtp2cUnitdata */
g2c_ud := { peer := g_peer, gtpc := g2c };
GTP2C.send(g2c_ud);
@@ -520,10 +588,11 @@
}
[] CLIENT.receive(PDU_GTPCv2:?) -> value g2c sender vc_conn {
- /* patch in the next sequence number */
- /* FIXME: do this only for outbound requests */
- g2c.sequenceNumber := int2oct(g_c_seq_nr, 3);
- g_c_seq_nr := g_c_seq_nr + 1;
+ /* patch in the next sequence number on outbound Initial message */
+ if (f_gtp2c_is_initial_msg(g2c)) {
+ g2c.sequenceNumber := int2oct(g_c_seq_nr, 3);
+ g_c_seq_nr := g_c_seq_nr + 1;
+ }
/* build Gtp2cUnitdata */
g2c_ud := { peer := g_peer, gtpc := g2c };
GTP2C.send(g2c_ud);
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35358?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I0f13074ccee2bf2d00d2dc2af491b9effc142f22
Gerrit-Change-Number: 35358
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: neels.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-iuh/+/35354?usp=email )
Change subject: iu_client: Handle empty CR and InitialUE Message in DATA.ind
......................................................................
Patch Set 2:
This change is ready for review.
--
To view, visit https://gerrit.osmocom.org/c/osmo-iuh/+/35354?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-iuh
Gerrit-Branch: master
Gerrit-Change-Id: I749ede737b9ac15bca37bbb16f3988b0db1125c1
Gerrit-Change-Number: 35354
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 13 Dec 2023 17:04:24 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-iuh/+/35354?usp=email )
Change subject: iu_client: Handle empty CR and InitialUE Message in DATA.ind
......................................................................
Patch Set 1:
(6 comments)
File src/iu_client.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/fd14000f_ecaae644
PS1, Line 180: static void ue_conn_sccp_addr_add(uint32_t conn_id, const struct osmo_sccp_addr *calling_addr) {
open brace '{' following function definitions go on the next line
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/97e6f0cc_25602fd3
PS1, Line 189: static const struct osmo_sccp_addr *ue_conn_sccp_addr_find(uint32_t conn_id) {
open brace '{' following function definitions go on the next line
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/74971f2e_620ebf20
PS1, Line 192: if (entry->conn_id == conn_id) {
braces {} are not necessary for single statement blocks
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/1dacde76_ef20c1c5
PS1, Line 199: static void ue_conn_sccp_addr_del(uint32_t conn_id) {
open brace '{' following function definitions go on the next line
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/affd1729_5e710e86
PS1, Line 931: "N-DATA.ind for unknown conn_id (%u)\n", conn_id);
code indent should use tabs where possible
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-13099):
https://gerrit.osmocom.org/c/osmo-iuh/+/35354/comment/b846dfaf_cd407be3
PS1, Line 931: "N-DATA.ind for unknown conn_id (%u)\n", conn_id);
please, no space before tabs
--
To view, visit https://gerrit.osmocom.org/c/osmo-iuh/+/35354?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-iuh
Gerrit-Branch: master
Gerrit-Change-Id: I749ede737b9ac15bca37bbb16f3988b0db1125c1
Gerrit-Change-Number: 35354
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: Jenkins Builder
Gerrit-Comment-Date: Wed, 13 Dec 2023 16:42:15 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: dexter, laforge, neels.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35212?usp=email )
Change subject: ecu: force alignment of member data in struct osmo_ecu_state
......................................................................
Patch Set 5:
(1 comment)
Commit Message:
https://gerrit.osmocom.org/c/libosmocore/+/35212/comment/42cf836f_15bccd65
PS5, Line 7: ecu: force alignment of member data in struct osmo_ecu_state
you probably need to update the whole commit description since the approach changed.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35212?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I28672856e8e8f47e04ffe09ee3e07b577108cdc7
Gerrit-Change-Number: 35212
Gerrit-PatchSet: 5
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 13 Dec 2023 13:53:57 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: dexter, laforge, neels.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35212?usp=email )
Change subject: ecu: force alignment of member data in struct osmo_ecu_state
......................................................................
Patch Set 4: Code-Review+1
(3 comments)
Patchset:
PS4:
I don't see any good reason not to use container_of here instead of casting.
File src/codec/ecu_fr.c:
https://gerrit.osmocom.org/c/libosmocore/+/35212/comment/18f6223c_7d3d57c8
PS4, Line 92: struct osmo_ecu_state ecu_state;
Add a comment that ecu_state should be the first in the struct.
If you used container_of, this wouldn't be required.
https://gerrit.osmocom.org/c/libosmocore/+/35212/comment/6e097f90_5147b26e
PS4, Line 294: return (struct osmo_ecu_state*) fr;
while the cast is fine, the container_of would probably be safer and would allow this struct to be anywhere, with no real cost (a few arithmetic operations).
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35212?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I28672856e8e8f47e04ffe09ee3e07b577108cdc7
Gerrit-Change-Number: 35212
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 13 Dec 2023 13:53:17 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment