summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2021-02-03 16:17:08 +0100
committerAlexander Couzens <lynxis@fe80.eu>2021-02-09 15:49:15 +0100
commit98ee6f650754af6d5a6ad74ea52fbe908d117137 (patch)
treededb543b3ea1728f22f5ac4bccab12ac12eb0594
parent109e755161661314926850b8776ffa44b825fce5 (diff)
pcu: move generic RAW_NS_CT function to library/RAW_NS
Allow the NS tests to use the SNS functions. Change-Id: I6c404475f39dd00023eb11e98da93ee423604039
-rw-r--r--library/RAW_NS.ttcnpp184
-rw-r--r--pcu/PCU_Tests_SNS.ttcn184
2 files changed, 184 insertions, 184 deletions
diff --git a/library/RAW_NS.ttcnpp b/library/RAW_NS.ttcnpp
index 2aaa770e..298ef1ee 100644
--- a/library/RAW_NS.ttcnpp
+++ b/library/RAW_NS.ttcnpp
@@ -266,4 +266,188 @@ public altstep as_rx_ns_block_ack(boolean oneshot := false, integer idx := 0, te
}
}
+/**********************************************************************************
+ * IP Sub-Network Service (SNS)
+ **********************************************************************************/
+
+/* perform inbound SNS-SIZE procedure */
+function f_incoming_sns_size(template (omit) NsCause cause := omit, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_incoming_sns_size(idx=", idx, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
+
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ /* expect one single SNS-SIZE with RESET flag; 4x v4 EP; no v6 EP */
+ rx := f_ns_exp(tr_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 8,
+ num_v4 := 4, num_v6 := omit), idx);
+ } else {
+ /* expect one single SNS-SIZE with RESET flag; no v4 EP; 4x v6 EP */
+ rx := f_ns_exp(tr_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 8,
+ num_v4 := omit, num_v6 := 4), idx);
+ }
+ NSCP[idx].send(ts_SNS_SIZE_ACK(g_nsconfig.nsei, cause));
+}
+
+/* perform outbound SNS-SIZE procedure */
+function f_outgoing_sns_size(template (omit) NsCause cause := omit, integer idx:= 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_size(idx=", idx, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
+
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ NSCP[idx].send(ts_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 1,
+ num_v4 := 1, num_v6 := omit)
+ );
+ } else {
+ NSCP[idx].send(ts_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 1,
+ num_v4 := omit, num_v6 := 1)
+ );
+ }
+ /* expect one single SNS-SIZE with RESET flag; 4x v4 EP; no v6 EP */
+ rx := f_ns_exp(tr_SNS_SIZE_ACK(g_nsconfig.nsei, cause), idx);
+}
+
+/* perform inbound SNS-CONFIG procedure */
+function f_incoming_sns_config(template (omit) NsCause cause := omit, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_incoming_sns_config(idx=", idx, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
+
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template IP4_Elements v4_elem := { tr_SNS_IPv4(nsvc_cfg.provider.ip.remote_ip,
+ nsvc_cfg.provider.ip.remote_udp_port) };
+ rx := f_ns_exp(tr_SNS_CONFIG(g_nsconfig.nsei, end_flag := true, v4 := v4_elem), idx);
+ } else {
+ var template IP6_Elements v6_elem := { tr_SNS_IPv6(nsvc_cfg.provider.ip.remote_ip,
+ nsvc_cfg.provider.ip.remote_udp_port) };
+ rx := f_ns_exp(tr_SNS_CONFIG(g_nsconfig.nsei, end_flag := true, v6 := v6_elem), idx);
+ }
+ NSCP[idx].send(ts_SNS_CONFIG_ACK(g_nsconfig.nsei, cause));
+}
+
+/* perform outbound SNS-CONFIG procedure */
+function f_outgoing_sns_config(template (omit) NsCause cause := omit, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_config(idx=", idx, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
+
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port) }
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port) }
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
+ }
+ rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
+}
+
+/* perform outbound SNS-CONFIG procedure (separate endpoints: 1 for control, 1 for user */
+function f_outgoing_sns_config_1c1u(template (omit) NsCause cause := omit, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_config_1c1u(idx=", idx, ")");
+ var PDU_NS rx;
+
+ if (g_nsconfig.nsvc[0].provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(g_nsconfig.nsvc[0].provider.ip.local_ip,
+ g_nsconfig.nsvc[0].provider.ip.local_udp_port, 1, 0),
+ ts_SNS_IPv4(g_nsconfig.nsvc[1].provider.ip.local_ip,
+ g_nsconfig.nsvc[1].provider.ip.local_udp_port, 0, 1) };
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(g_nsconfig.nsvc[0].provider.ip.local_ip,
+ g_nsconfig.nsvc[0].provider.ip.local_udp_port, 1, 0),
+ ts_SNS_IPv6(g_nsconfig.nsvc[1].provider.ip.local_ip,
+ g_nsconfig.nsvc[1].provider.ip.local_udp_port, 0, 1) };
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
+ }
+ rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
+}
+
+/* perform outbound SNS-CONFIG procedure (separate endpoints: 1 for control, 1 for user */
+function f_outgoing_sns_config_1c1u_separate(template (omit) NsCause cause := omit, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_config_1c1u_separate(idx=", idx, ")");
+ var PDU_NS rx;
+ if (g_nsconfig.nsvc[0].provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(g_nsconfig.nsvc[1].provider.ip.local_ip,
+ g_nsconfig.nsvc[1].provider.ip.local_udp_port, 1, 0),
+ ts_SNS_IPv4(g_nsconfig.nsvc[2].provider.ip.local_ip,
+ g_nsconfig.nsvc[2].provider.ip.local_udp_port, 0, 1) };
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(g_nsconfig.nsvc[1].provider.ip.local_ip,
+ g_nsconfig.nsvc[1].provider.ip.local_udp_port, 1, 0),
+ ts_SNS_IPv6(g_nsconfig.nsvc[2].provider.ip.local_ip,
+ g_nsconfig.nsvc[2].provider.ip.local_udp_port, 0, 1) };
+ NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
+ }
+ rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
+}
+
+function f_outgoing_sns_add(integer idx_add, uint8_t w_sig := 1, uint8_t w_user := 1, integer idx := 0, template (omit) NsCause cause := omit)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_add(idx_add=", idx_add, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_add];
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_ADD(g_nsconfig.nsei, 23, v4));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 23, cause, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_ADD(g_nsconfig.nsei, 23, omit, v6));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 23, cause, omit, v6));
+ }
+}
+
+function f_outgoing_sns_del(integer idx_del, uint8_t w_sig := 1, uint8_t w_user := 1, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_del(idx_del=", idx_del, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_del];
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_DEL(g_nsconfig.nsei, 24, omit, v4));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 24, omit, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_DEL(g_nsconfig.nsei, 24, omit, omit, v6));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 24, omit, omit, v6));
+ }
+}
+
+function f_outgoing_sns_chg_weight(integer idx_chg, uint8_t w_sig, uint8_t w_user, integer idx := 0)
+runs on RAW_NS_CT {
+ log("f_outgoing_sns_chg_weight(idx_chg=", idx_chg, ")");
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_chg];
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_CHG_WEIGHT(g_nsconfig.nsei, 25, v4));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 25, omit, v4));
+ } else {
+ var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
+ nsvc_cfg.provider.ip.local_udp_port,
+ w_sig, w_user) };
+ NSCP[idx].send(ts_SNS_CHG_WEIGHT(g_nsconfig.nsei, 25, omit, v6));
+ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 25, omit, omit, v6));
+ }
+}
+
}
diff --git a/pcu/PCU_Tests_SNS.ttcn b/pcu/PCU_Tests_SNS.ttcn
index 4fca26ef..c4f6b6e0 100644
--- a/pcu/PCU_Tests_SNS.ttcn
+++ b/pcu/PCU_Tests_SNS.ttcn
@@ -22,190 +22,6 @@ import from RAW_NS all;
* Modern Gb/IP bring-up test cases using IP Sub-Network Service (SNS)
**********************************************************************************/
-/* perform inbound SNS-SIZE procedure */
-function f_incoming_sns_size(template (omit) NsCause cause := omit, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_incoming_sns_size(idx=", idx, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
-
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- /* expect one single SNS-SIZE with RESET flag; 4x v4 EP; no v6 EP */
- rx := f_ns_exp(tr_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 8,
- num_v4 := 4, num_v6 := omit), idx);
- } else {
- /* expect one single SNS-SIZE with RESET flag; no v4 EP; 4x v6 EP */
- rx := f_ns_exp(tr_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 8,
- num_v4 := omit, num_v6 := 4), idx);
- }
- NSCP[idx].send(ts_SNS_SIZE_ACK(g_nsconfig.nsei, cause));
-}
-
-/* perform outbound SNS-SIZE procedure */
-function f_outgoing_sns_size(template (omit) NsCause cause := omit, integer idx:= 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_size(idx=", idx, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
-
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- NSCP[idx].send(ts_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 1,
- num_v4 := 1, num_v6 := omit)
- );
- } else {
- NSCP[idx].send(ts_SNS_SIZE(g_nsconfig.nsei, rst_flag := true, max_nsvcs := 1,
- num_v4 := omit, num_v6 := 1)
- );
- }
- /* expect one single SNS-SIZE with RESET flag; 4x v4 EP; no v6 EP */
- rx := f_ns_exp(tr_SNS_SIZE_ACK(g_nsconfig.nsei, cause), idx);
-}
-
-/* perform inbound SNS-CONFIG procedure */
-function f_incoming_sns_config(template (omit) NsCause cause := omit, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_incoming_sns_config(idx=", idx, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
-
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- var template IP4_Elements v4_elem := { tr_SNS_IPv4(nsvc_cfg.provider.ip.remote_ip,
- nsvc_cfg.provider.ip.remote_udp_port) };
- rx := f_ns_exp(tr_SNS_CONFIG(g_nsconfig.nsei, end_flag := true, v4 := v4_elem), idx);
- } else {
- var template IP6_Elements v6_elem := { tr_SNS_IPv6(nsvc_cfg.provider.ip.remote_ip,
- nsvc_cfg.provider.ip.remote_udp_port) };
- rx := f_ns_exp(tr_SNS_CONFIG(g_nsconfig.nsei, end_flag := true, v6 := v6_elem), idx);
- }
- NSCP[idx].send(ts_SNS_CONFIG_ACK(g_nsconfig.nsei, cause));
-}
-
-/* perform outbound SNS-CONFIG procedure */
-function f_outgoing_sns_config(template (omit) NsCause cause := omit, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_config(idx=", idx, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx];
-
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port) }
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port) }
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
- }
- rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
-}
-
-/* perform outbound SNS-CONFIG procedure (separate endpoints: 1 for control, 1 for user */
-function f_outgoing_sns_config_1c1u(template (omit) NsCause cause := omit, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_config_1c1u(idx=", idx, ")");
- var PDU_NS rx;
-
- if (mp_nsconfig.nsvc[0].provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(g_nsconfig.nsvc[0].provider.ip.local_ip,
- g_nsconfig.nsvc[0].provider.ip.local_udp_port, 1, 0),
- ts_SNS_IPv4(g_nsconfig.nsvc[1].provider.ip.local_ip,
- g_nsconfig.nsvc[1].provider.ip.local_udp_port, 0, 1) };
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(g_nsconfig.nsvc[0].provider.ip.local_ip,
- g_nsconfig.nsvc[0].provider.ip.local_udp_port, 1, 0),
- ts_SNS_IPv6(g_nsconfig.nsvc[1].provider.ip.local_ip,
- g_nsconfig.nsvc[1].provider.ip.local_udp_port, 0, 1) };
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
- }
- rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
-}
-
-/* perform outbound SNS-CONFIG procedure (separate endpoints: 1 for control, 1 for user */
-function f_outgoing_sns_config_1c1u_separate(template (omit) NsCause cause := omit, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_config_1c1u_separate(idx=", idx, ")");
- var PDU_NS rx;
- if (mp_nsconfig.nsvc[0].provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(g_nsconfig.nsvc[1].provider.ip.local_ip,
- g_nsconfig.nsvc[1].provider.ip.local_udp_port, 1, 0),
- ts_SNS_IPv4(g_nsconfig.nsvc[2].provider.ip.local_ip,
- g_nsconfig.nsvc[2].provider.ip.local_udp_port, 0, 1) };
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(g_nsconfig.nsvc[1].provider.ip.local_ip,
- g_nsconfig.nsvc[1].provider.ip.local_udp_port, 1, 0),
- ts_SNS_IPv6(g_nsconfig.nsvc[2].provider.ip.local_ip,
- g_nsconfig.nsvc[2].provider.ip.local_udp_port, 0, 1) };
- NSCP[idx].send(ts_SNS_CONFIG(g_nsconfig.nsei, true, omit, v6));
- }
- rx := f_ns_exp(tr_SNS_CONFIG_ACK(g_nsconfig.nsei, cause), idx);
-}
-
-function f_outgoing_sns_add(integer idx_add, uint8_t w_sig := 1, uint8_t w_user := 1, integer idx := 0, template (omit) NsCause cause := omit)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_add(idx_add=", idx_add, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_add];
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_ADD(g_nsconfig.nsei, 23, v4));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 23, cause, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_ADD(g_nsconfig.nsei, 23, omit, v6));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 23, cause, omit, v6));
- }
-}
-
-function f_outgoing_sns_del(integer idx_del, uint8_t w_sig := 1, uint8_t w_user := 1, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_del(idx_del=", idx_del, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_del];
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_DEL(g_nsconfig.nsei, 24, omit, v4));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 24, omit, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_DEL(g_nsconfig.nsei, 24, omit, omit, v6));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 24, omit, omit, v6));
- }
-}
-
-function f_outgoing_sns_chg_weight(integer idx_chg, uint8_t w_sig, uint8_t w_user, integer idx := 0)
-runs on RAW_NS_CT {
- log("f_outgoing_sns_chg_weight(idx_chg=", idx_chg, ")");
- var PDU_NS rx;
- var NSVCConfiguration nsvc_cfg := g_nsconfig.nsvc[idx_chg];
- if (nsvc_cfg.provider.ip.address_family == AF_INET) {
- var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_CHG_WEIGHT(g_nsconfig.nsei, 25, v4));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 25, omit, v4));
- } else {
- var template (omit) IP6_Elements v6 := { ts_SNS_IPv6(nsvc_cfg.provider.ip.local_ip,
- nsvc_cfg.provider.ip.local_udp_port,
- w_sig, w_user) };
- NSCP[idx].send(ts_SNS_CHG_WEIGHT(g_nsconfig.nsei, 25, omit, v6));
- rx := f_ns_exp(tr_SNS_ACK(g_nsconfig.nsei, 25, omit, omit, v6));
- }
-}
-
-
-
-
-
/* PCU-originated SNS-SIZE: successful case */
testcase TC_sns_po_size_success() runs on RAW_Test_CT {
f_init_ns_codec(mp_nsconfig);