pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/33269 )
Change subject: pcu: Rework test TC_ul_tbf_reestablish_with_pkt_resource_req_n3105_max to base it on T3168
......................................................................
pcu: Rework test TC_ul_tbf_reestablish_with_pkt_resource_req_n3105_max to base it on T3168
N3105 is used for DL TBFs only (as tested by TC_n3105_max_t3195). The
test TC_ul_tbf_reestablish_with_pkt_resource_req_n3105_max is hence
wrongly written and should be based on T3168. Since recently, osmo-pcu
also moved to using T3168 in the scenario triggered by this test, hence
move to using it.
Related: osmo-pcu.git Change-Id I87dff68dedd06b60501e7586d20faf02bb1f0c93
Change-Id: Ibdfa9879cc56f5e2090cee0d3d70ee5df7c90454
---
M pcu/PCU_Tests.ttcn
1 file changed, 44 insertions(+), 47 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/69/33269/1
diff --git a/pcu/PCU_Tests.ttcn b/pcu/PCU_Tests.ttcn
index f859b9b..9388f8f 100644
--- a/pcu/PCU_Tests.ttcn
+++ b/pcu/PCU_Tests.ttcn
@@ -3373,7 +3373,7 @@
* ending, by means of sending a Packet Resource Request on ul slot provided by
* last Pkt Ul ACK's RRBP. new Pkt Ul Ass is never confirmed by the MS in this test.
* See 3GPP TS 44.060 sec 9.3.2.4.2 "Non-extended uplink TBF mode" */
-testcase TC_ul_tbf_reestablish_with_pkt_resource_req_n3105_max() runs on RAW_PCU_Test_CT {
+testcase TC_ul_tbf_reestablish_with_pkt_resource_req_t3168() runs on RAW_PCU_Test_CT {
var PCUIF_info_ind info_ind;
var RlcmacDlBlock dl_block;
var octetstring data := f_rnd_octstring(10);
@@ -3383,9 +3383,10 @@
var BTS_PDTCH_Block data_msg;
var template RlcmacDlBlock acknack_tmpl;
var GprsMS ms;
- const integer N3105_MAX := 2;
- var integer N3105 := 0;
- timer T_3195 := 1.0 + 0.5; /* 0.5: extra offset since we cannot match exactly */
+ var integer cnt_rrbp := 0;
+ var integer cnt_dummy_after_timeout := 0;
+ /* Maximum T3168 value = 8 * 500 ms = 4s => * 4 retrans = 16s */
+ timer T_3168 := 16.0 + 0.5; /* 0.5: extra offset since we cannot match exactly */
/* Initialize NS/BSSGP side */
f_init_bssgp();
@@ -3395,9 +3396,7 @@
/* Initialize the PCU interface abstraction */
info_ind := valueof(ts_PCUIF_INFO_default(c_PCUIF_Flags_noMCS));
- /* Speedup test: */
- info_ind.n3105 := N3105_MAX;
- info_ind.t3195 := 1;
+ /* TODO: Speedup test by sending a PCU_IF_SAPI_BCCH SI13 with T3168=0 (500ms) */
f_init_raw(testcasename(), info_ind);
/* Establish BSSGP connection to the PCU */
@@ -3423,6 +3422,7 @@
/* TODO: verify TBF_EST and FinalACK are both '1' above */
/* Send PACKET RESOURCE REQUEST to request a new UL TBF */
+ T_3168.start;
f_ms_tx_ul_block(ms, ts_RLC_UL_CTRL_ACK(ts_RlcMacUlCtrl_PKT_RES_REQ(ms.tlli, omit)), sched_fn);
/* Now Keep ignoring the Pkt Ul Ass on PACCH: */
@@ -3433,12 +3433,18 @@
arfcn := f_trxnr2arfcn(valueof(nr.trx_nr)),
block_nr := nr.blk_nr));
alt {
- [not T_3195.running] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
+ [] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
tr_PCUIF_DATA(nr.trx_nr, nr.ts_nr, sapi := PCU_IF_SAPI_PDTCH),
tr_RLCMAC_UL_PACKET_ASS)) -> value data_msg {
+ /* We should not be receiving PKT UL ASS anymore after T3168 timeout */
+ if (not T_3168.running) {
+ setverdict(fail, log2str("Unexpected PKT UL ASS after T3168 timeout: ", data_msg));
+ f_shutdown(__BFILE__, __LINE__);
+ }
+
if (f_dl_block_rrbp_valid(data_msg.dl_block)) {
- log("Ignoring RRBP N3105 ", N3105);
- N3105 := N3105 + 1;
+ log("Ignoring RRBP ", cnt_rrbp);
+ cnt_rrbp := cnt_rrbp + 1;
}
nr := ts_TsTrxBtsNum;
BTS.send(ts_PCUIF_RTS_REQ(nr.bts_nr, nr.trx_nr, nr.ts_nr,
@@ -3447,15 +3453,9 @@
block_nr := nr.blk_nr));
repeat;
}
- /* At this point in time (N3105_MAX reached), PCU already moved TBF to
- * RELEASE state so no data for it is tx'ed, hence the dummy blocks:
- */
- [N3105 == N3105_MAX] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
+ [] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
tr_PCUIF_DATA(nr.trx_nr, nr.ts_nr, sapi := PCU_IF_SAPI_PDTCH),
tr_RLCMAC_DL_DUMMY_CTRL)) -> value data_msg {
- if (not T_3195.running) {
- T_3195.start;
- }
nr := ts_TsTrxBtsNum;
BTS.send(ts_PCUIF_RTS_REQ(nr.bts_nr, nr.trx_nr, nr.ts_nr,
sapi := PCU_IF_SAPI_PDTCH, fn := 0,
@@ -3463,44 +3463,25 @@
block_nr := nr.blk_nr));
repeat;
}
- [N3105 == N3105_MAX] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
+ [] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
tr_PCUIF_DATA(nr.trx_nr, nr.ts_nr, sapi := PCU_IF_SAPI_PDTCH),
omit)) -> value data_msg {
- /* We may already receive idle blocks before our own TTCN3 timer
- * triggers due to the TBF being released. Keep going until our T_3195 triggers. */
- nr := ts_TsTrxBtsNum;
- BTS.send(ts_PCUIF_RTS_REQ(nr.bts_nr, nr.trx_nr, nr.ts_nr,
- sapi := PCU_IF_SAPI_PDTCH, fn := 0,
- arfcn := f_trxnr2arfcn(valueof(nr.trx_nr)),
- block_nr := nr.blk_nr));
- repeat;
+
+ /* T3168 expired and we are not receiving blocks anymore, meaning PCU released the TBF. */
+ break;
}
- /* We receive Dummy blocks in between Pkt Ul Ass while PCU waits for us to ack it */
- [not T_3195.running] BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
- tr_PCUIF_DATA(nr.trx_nr, nr.ts_nr, sapi := PCU_IF_SAPI_PDTCH),
- tr_RLCMAC_DL_DUMMY_CTRL)) -> value data_msg {
- log("Ignoring Dummy block FN ", data_msg.raw.fn);
- nr := ts_TsTrxBtsNum;
- BTS.send(ts_PCUIF_RTS_REQ(nr.bts_nr, nr.trx_nr, nr.ts_nr,
- sapi := PCU_IF_SAPI_PDTCH, fn := 0,
- arfcn := f_trxnr2arfcn(valueof(nr.trx_nr)),
- block_nr := nr.blk_nr));
- repeat;
- }
- [T_3195.running] T_3195.timeout {
- log("T_3195 timeout");
- /* Done in alt, wait for pending RTS initiated previously in
- * above case before continuing (expect nothing to be sent since there's no active TBF): */
- BTS.receive(tr_PCUIF_DATA_PDTCH(nr.bts_nr,
- tr_PCUIF_DATA(nr.trx_nr, nr.ts_nr, sapi := PCU_IF_SAPI_PDTCH),
- omit));
- }
[] BTS.receive {
setverdict(fail, "Unexpected BTS message");
f_shutdown(__BFILE__, __LINE__);
}
}
+ /* Check that we received at least a few PKT UL ASS before T3168 expiration */
+ if (cnt_rrbp <= 3) {
+ setverdict(fail, log2str("Received only ", cnt_rrbp, " before T3168 timeout!"));
+ f_shutdown(__BFILE__, __LINE__);
+ }
+
f_shutdown(__BFILE__, __LINE__, final := true);
}
@@ -7145,7 +7126,7 @@
execute( TC_dl_multislot_tbf_ms_class_from_2phase() );
execute( TC_ul_multislot_tbf_ms_class_from_2phase() );
execute( TC_ul_tbf_reestablish_with_pkt_resource_req() );
- execute( TC_ul_tbf_reestablish_with_pkt_resource_req_n3105_max() );
+ execute( TC_ul_tbf_reestablish_with_pkt_resource_req_t3168() );
execute( TC_ul_tbf_reestablish_with_pkt_dl_ack_nack() );
execute( TC_ul_tbf_reestablish_with_pkt_dl_ack_nack_egprs() );
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/33269
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: Ibdfa9879cc56f5e2090cee0d3d70ee5df7c90454
Gerrit-Change-Number: 33269
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: daniel.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33253 )
Change subject: stream: Factor out reconnection handling
......................................................................
Patch Set 3: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33253
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
Gerrit-Change-Number: 33253
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 14:17:10 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: arehbein, pespin, daniel.
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33194 )
Change subject: examples: Use new stream API in {ipa-,}stream-{client,server}
......................................................................
Patch Set 10:
(2 comments)
File examples/stream-client.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8202):
https://gerrit.osmocom.org/c/libosmo-netif/+/33194/comment/1e6d989e_70b6de33
PS10, Line 53: static int read_cb(struct osmo_stream_cli *conn, struct msgb* msg)
"foo* bar" should be "foo *bar"
File examples/stream-server.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8202):
https://gerrit.osmocom.org/c/libosmo-netif/+/33194/comment/7962b6cb_c59cd7d7
PS10, Line 45: int read_cb(struct osmo_stream_srv *conn, struct msgb* msg)
"foo* bar" should be "foo *bar"
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33194
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I97a9979199c816686b32080534627f6f033e009e
Gerrit-Change-Number: 33194
Gerrit-PatchSet: 10
Gerrit-Owner: arehbein <arehbein(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 14:07:34 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: pespin.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33253 )
Change subject: stream: Factor out reconnection handling
......................................................................
Patch Set 3:
(1 comment)
File src/stream.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/33253/comment/0e690448_deb0f3c6
PS1, Line 472: osmo_fd_write_disable(&cli->ofd);
> Disregard that, I moved it and special-case it to the cli->mode in the commit adding osmo_io support […]
Done
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33253
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
Gerrit-Change-Number: 33253
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 14:07:04 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmo-netif/+/33253
to look at the new patch set (#3).
Change subject: stream: Factor out reconnection handling
......................................................................
stream: Factor out reconnection handling
Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
---
M src/stream.c
1 file changed, 54 insertions(+), 33 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/53/33253/3
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33253
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
Gerrit-Change-Number: 33253
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: arehbein, laforge, pespin.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33193 )
Change subject: Add osmo_io support to osmo_stream_cli and osmo_stream_srv
......................................................................
Patch Set 12:
(1 comment)
Patchset:
PS10:
> So I think the only relevant thing to wrap here is whether we want to have the 2 callback function p […]
Your proposal is growing on me, but it would still be nice to hear from others.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33193
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I2f52c7107c392b6f4b0bf2a84f8c873c084a200c
Gerrit-Change-Number: 33193
Gerrit-PatchSet: 12
Gerrit-Owner: arehbein <arehbein(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 14:07:04 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin, daniel.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33253 )
Change subject: stream: Factor out reconnection handling
......................................................................
Patch Set 2:
(1 comment)
File src/stream.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/33253/comment/48682011_396d89a9
PS1, Line 472: osmo_fd_write_disable(&cli->ofd);
> Please look at osmo_iofd_free() and osmo_iofd_close() […]
Disregard that, I moved it and special-case it to the cli->mode in the commit adding osmo_io support.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33253
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
Gerrit-Change-Number: 33253
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 13:53:17 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33253 )
Change subject: stream: Factor out reconnection handling
......................................................................
Patch Set 2:
(1 comment)
File src/stream.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8200):
https://gerrit.osmocom.org/c/libosmo-netif/+/33253/comment/c7a3e886_93efc187
PS2, Line 470: switch(cli->state) {
space required before the open parenthesis '('
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33253
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I418377eabd465ee4ffce9b4440e96287c7734924
Gerrit-Change-Number: 33253
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 13:52:14 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: arehbein, pespin, daniel.
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/33194 )
Change subject: examples: Use new stream API in {ipa-,}stream-{client,server}
......................................................................
Patch Set 9:
(2 comments)
File examples/stream-client.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8199):
https://gerrit.osmocom.org/c/libosmo-netif/+/33194/comment/07976043_c925b900
PS9, Line 53: static int read_cb(struct osmo_stream_cli *conn, struct msgb* msg)
"foo* bar" should be "foo *bar"
File examples/stream-server.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8199):
https://gerrit.osmocom.org/c/libosmo-netif/+/33194/comment/b7112542_f22b556c
PS9, Line 45: int read_cb(struct osmo_stream_srv *conn, struct msgb* msg)
"foo* bar" should be "foo *bar"
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/33194
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I97a9979199c816686b32080534627f6f033e009e
Gerrit-Change-Number: 33194
Gerrit-PatchSet: 9
Gerrit-Owner: arehbein <arehbein(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 12 Jun 2023 13:52:12 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment