[MERGED] osmo-ttcn3-hacks[master]: improve documentation of templates used in GGSN_Tests

2018-04-01 Thread Harald Welte
Harald Welte has submitted this change and it was merged.

Change subject: improve documentation of templates used in GGSN_Tests
..


improve documentation of templates used in GGSN_Tests

Various improvements to the comments documenting packet templates
used in GGSN_Tests: fix IPv4 vs. IPv6 confusion, clearly indicate
whether templates are used for sending or for receiving/matching
packets, and add a missing comment.

Found while studying code to prepare for issue OS#2519.

Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Related: OS#2519
---
M ggsn_tests/GGSN_Tests.ttcn
1 file changed, 8 insertions(+), 7 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, but someone else must approve
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/ggsn_tests/GGSN_Tests.ttcn b/ggsn_tests/GGSN_Tests.ttcn
index f320c20..2b7de96 100644
--- a/ggsn_tests/GGSN_Tests.ttcn
+++ b/ggsn_tests/GGSN_Tests.ttcn
@@ -227,7 +227,7 @@
/* IPv6 neighbor solicitation fe80::2 -> ff02::1:ff00:2 from 
02:88:b5:1f:25:59 */
const octetstring c_neigh_solicit:= 
'60203afffe82ff020001ff0287009f96fe8201010288b51f2559'O;
 
-   /* template for an ICMPv6 echo request */
+   /* template for sending an ICMPv4 echo request */
template PDU_ICMP ts_ICMPv4_ERQ := {
echo := {
type_field := 8,
@@ -239,7 +239,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for receiving/matching an ICMPv4 echo request */
template PDU_ICMP tr_ICMPv4_ERQ := {
echo := {
type_field := 8,
@@ -251,7 +251,7 @@
}
}
 
-   /* template for an ICMPv4 echo reply */
+   /* template for receiving/matching an ICMPv4 echo reply */
template PDU_ICMP tr_ICMPv4_ERP(template octetstring data := *) := {
echo_reply := {
type_field := 0,
@@ -312,7 +312,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for sending an ICMPv6 echo request */
template PDU_ICMPv6 ts_ICMPv6_ERQ := {
echoRequest := {
typeField := 128,
@@ -324,7 +324,7 @@
}
}
 
-   /* template for an ICMPv6 router solicitation */
+   /* template for sending an ICMPv6 router solicitation */
template PDU_ICMPv6 ts_ICMPv6_RS := {
routerSolicitation := {
typeField := 133,
@@ -336,7 +336,7 @@
}
}
 
-   /* template for an ICMPv6 router advertisement */
+   /* template for sending an ICMPv6 router advertisement */
template PDU_ICMPv6 ts_ICMPv6_RA(OCT16 prefix, INT1 prefix_len) := {
routerAdvertisement := {
typeField := 134,
@@ -355,6 +355,7 @@
}
}
 
+   /* template for sending an ICMPv6 neighbor solicitation */
template PDU_ICMPv6 ts_ICMPv6_NS(OCT16 target_addr) := {
neighborSolicitation := {
typeField := 135,
@@ -414,7 +415,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for receiving/matching an ICMPv6 echo request */
template PDU_ICMPv6 tr_ICMPv6_ERQ := {
echoRequest := {
typeField := 128,

-- 
To view, visit https://gerrit.osmocom.org/7598
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Gerrit-PatchSet: 2
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Pau Espin Pedrol 


osmo-ttcn3-hacks[master]: improve documentation of templates used in GGSN_Tests

2018-04-01 Thread Harald Welte

Patch Set 1: Code-Review+2

-- 
To view, visit https://gerrit.osmocom.org/7598
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-HasComments: No


osmo-ttcn3-hacks[master]: improve documentation of templates used in GGSN_Tests

2018-03-30 Thread Pau Espin Pedrol

Patch Set 1: Code-Review+1

I think it's already clear due to the "ts/tr" in the naming, but of course it's 
even better if documented as you did :)

-- 
To view, visit https://gerrit.osmocom.org/7598
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-HasComments: No


[PATCH] osmo-ttcn3-hacks[master]: improve documentation of templates used in GGSN_Tests

2018-03-30 Thread Stefan Sperling

Review at  https://gerrit.osmocom.org/7598

improve documentation of templates used in GGSN_Tests

Various improvements to the comments documenting packet templates
used in GGSN_Tests: fix IPv4 vs. IPv6 confusion, clearly indicate
whether templates are used for sending or for receiving/matching
packets, and add a missing comment.

Found while studying code to prepare for issue OS#2519.

Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Related: OS#2519
---
M ggsn_tests/GGSN_Tests.ttcn
1 file changed, 8 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/98/7598/1

diff --git a/ggsn_tests/GGSN_Tests.ttcn b/ggsn_tests/GGSN_Tests.ttcn
index f320c20..2b7de96 100644
--- a/ggsn_tests/GGSN_Tests.ttcn
+++ b/ggsn_tests/GGSN_Tests.ttcn
@@ -227,7 +227,7 @@
/* IPv6 neighbor solicitation fe80::2 -> ff02::1:ff00:2 from 
02:88:b5:1f:25:59 */
const octetstring c_neigh_solicit:= 
'60203afffe82ff020001ff0287009f96fe8201010288b51f2559'O;
 
-   /* template for an ICMPv6 echo request */
+   /* template for sending an ICMPv4 echo request */
template PDU_ICMP ts_ICMPv4_ERQ := {
echo := {
type_field := 8,
@@ -239,7 +239,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for receiving/matching an ICMPv4 echo request */
template PDU_ICMP tr_ICMPv4_ERQ := {
echo := {
type_field := 8,
@@ -251,7 +251,7 @@
}
}
 
-   /* template for an ICMPv4 echo reply */
+   /* template for receiving/matching an ICMPv4 echo reply */
template PDU_ICMP tr_ICMPv4_ERP(template octetstring data := *) := {
echo_reply := {
type_field := 0,
@@ -312,7 +312,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for sending an ICMPv6 echo request */
template PDU_ICMPv6 ts_ICMPv6_ERQ := {
echoRequest := {
typeField := 128,
@@ -324,7 +324,7 @@
}
}
 
-   /* template for an ICMPv6 router solicitation */
+   /* template for sending an ICMPv6 router solicitation */
template PDU_ICMPv6 ts_ICMPv6_RS := {
routerSolicitation := {
typeField := 133,
@@ -336,7 +336,7 @@
}
}
 
-   /* template for an ICMPv6 router advertisement */
+   /* template for sending an ICMPv6 router advertisement */
template PDU_ICMPv6 ts_ICMPv6_RA(OCT16 prefix, INT1 prefix_len) := {
routerAdvertisement := {
typeField := 134,
@@ -355,6 +355,7 @@
}
}
 
+   /* template for sending an ICMPv6 neighbor solicitation */
template PDU_ICMPv6 ts_ICMPv6_NS(OCT16 target_addr) := {
neighborSolicitation := {
typeField := 135,
@@ -414,7 +415,7 @@
}
}
 
-   /* template for an ICMPv6 echo request */
+   /* template for receiving/matching an ICMPv6 echo request */
template PDU_ICMPv6 tr_ICMPv6_ERQ := {
echoRequest := {
typeField := 128,

-- 
To view, visit https://gerrit.osmocom.org/7598
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3bfc21a5ba74e0505457e4874f93501ad7c68b7b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Stefan Sperling