fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/27835 )
Change subject: osmo-bts-trx: tx_tchh_fn(): make handling of FACCH/H cleaner
......................................................................
osmo-bts-trx: tx_tchh_fn(): make handling of FACCH/H cleaner
If set, chan_state->dl_ongoing_facch indicates that we're sending
the 2 (out of 6) middle bursts of FACCH/H. In this case there is
no room for encoding an additional frame, because both even and
odd numbered bits are occupied by a previously encoded FACCH/H.
Right after calling tch_dl_dequeue():
* do not check the dequeued message against NULL,
* do not compare the message length to GSM_MACBLOCK_LEN,
* immediately free() it and jump to the sending part.
Change-Id: Ib923b8f5cc1063e9fc18acd2bdd003fd09f4b70f
Related: SYS#5919, OS#4823
---
M src/osmo-bts-trx/sched_lchan_tchh.c
1 file changed, 9 insertions(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/35/27835/1
diff --git a/src/osmo-bts-trx/sched_lchan_tchh.c b/src/osmo-bts-trx/sched_lchan_tchh.c
index 6402476..5866788 100644
--- a/src/osmo-bts-trx/sched_lchan_tchh.c
+++ b/src/osmo-bts-trx/sched_lchan_tchh.c
@@ -390,8 +390,15 @@
/* dequeue a message to be transmitted */
msg = tch_dl_dequeue(l1ts, br);
+ /* if we're sending 2 middle bursts of FACCH/H */
+ if (chan_state->dl_ongoing_facch) {
+ msgb_free(msg); /* steal 2nd speech frame */
+ chan_state->dl_ongoing_facch = 0;
+ goto send_burst;
+ }
+
/* no message at all, send a dummy L2 frame on FACCH */
- if (msg == NULL && !chan_state->dl_ongoing_facch) {
+ if (msg == NULL) {
static const uint8_t dummy[GSM_MACBLOCK_LEN] = {
0x03, 0x03, 0x01, /* TODO: use randomized padding */
0x2b, 0x2b, 0x2b, 0x2b, 0x2b, 0x2b, 0x2b, 0x2b, 0x2b, 0x2b,
@@ -408,9 +415,7 @@
gsm0503_tch_hr_encode(*bursts_p, msg->l2h, msgb_l2len(msg));
chan_state->dl_ongoing_facch = 1; /* first of two TCH frames */
chan_state->dl_facch_bursts = 6;
- } else if (chan_state->dl_ongoing_facch) /* second of two TCH frames */
- chan_state->dl_ongoing_facch = 0; /* we are done with FACCH */
- else if (tch_mode == GSM48_CMODE_SPEECH_AMR)
+ } else if (tch_mode == GSM48_CMODE_SPEECH_AMR)
/* the first FN 4,13,21 or 5,14,22 defines that CMI is included
* in frame, the first FN 0,8,17 or 1,9,18 defines that CMR is
* included in frame. */
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/27835
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: Ib923b8f5cc1063e9fc18acd2bdd003fd09f4b70f
Gerrit-Change-Number: 27835
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: fixeria.
Hello Jenkins Builder, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-bts/+/27804
to look at the new patch set (#2).
Change subject: osmo-bts-trx: prioritize FACCH in s/tx_tch_common()/tch_dl_dequeue()/s
......................................................................
osmo-bts-trx: prioritize FACCH in s/tx_tch_common()/tch_dl_dequeue()/s
Unlike SACCH, FACCH has no dedicated slots on the multiframe layout.
It's multiplexed together with TCH (speech or data) frames basically
by replacing (stealing) them. This is common for both TCH/F and
TCH/H, with the only difference that FACCH/H steals two TCH frames
(not just one) due to a longer interleaving period.
Let's implement the multiplexing in the common function, which is
used to dequeue to be transmitted frames - this slightly reduces
code duplication. Use a new name, so that it's clear what it does.
Change-Id: I9822b1a17185d5487f0f6d3ed0203e806c053d7d
Related: SYS#5919, OS#4823
---
M src/osmo-bts-trx/sched_lchan_tchf.c
M src/osmo-bts-trx/sched_lchan_tchh.c
2 files changed, 41 insertions(+), 41 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/04/27804/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/27804
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I9822b1a17185d5487f0f6d3ed0203e806c053d7d
Gerrit-Change-Number: 27804
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: fixeria.
Hello Jenkins Builder, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-bts/+/27805
to look at the new patch set (#2).
Change subject: osmo-bts-trx: fix scheduling of dummy FACCH/H and FACCH/F
......................................................................
osmo-bts-trx: fix scheduling of dummy FACCH/H and FACCH/F
* dl_ongoing_facch must be set for correct FACCH/H scheduling;
* dl_facch_bursts must be set for FACCH overpower to work.
Change-Id: Ief12eb67ad80de3b71f5226858dc2e0c8ae76948
Related: SYS#5919, OS#4823
---
M src/osmo-bts-trx/sched_lchan_tchf.c
M src/osmo-bts-trx/sched_lchan_tchh.c
2 files changed, 3 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/05/27805/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/27805
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: Ief12eb67ad80de3b71f5226858dc2e0c8ae76948
Gerrit-Change-Number: 27805
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: fixeria.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-dev/+/27832 )
Change subject: gen_makefile.py: use '$(nproc)' for '--jobs' by default
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/27832
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-dev
Gerrit-Branch: master
Gerrit-Change-Id: I769f032ebf197bac34468683526acf6614e74692
Gerrit-Change-Number: 27832
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 19 Apr 2022 18:30:26 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: fixeria.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-dev/+/27831 )
Change subject: osmo-add-gerrit-hooks.sh: do not use ssh host alias 'go'
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/27831
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-dev
Gerrit-Branch: master
Gerrit-Change-Id: I55c1501de61fe6b63be12b8e138742bd4b8baf64
Gerrit-Change-Number: 27831
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 19 Apr 2022 18:30:16 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-e1d/+/27834 )
Change subject: octoi: Simple RX priming / pre-filling
......................................................................
octoi: Simple RX priming / pre-filling
This was not an issue with the original FIFO code, which dynamically
substituted frames and always created the minimal required backlog.
The RIFO can by principle not operate this way, so we really have to
prime / pre-fill it with a number of TDM frames. That initial fill
level has to be sufficient to cover RTT jitter of the OCTOI link as
well as clock drift between (GPS synced) receiver and transmitter.
Signed-off-by: Sylvain Munaut <tnt(a)246tNt.com>
Change-Id: I3a4b3846d3dbd1c99989e994ad95e609f2757219
---
M src/octoi/e1oip.c
M src/octoi/e1oip.h
M src/octoi/octoi.c
3 files changed, 9 insertions(+), 1 deletion(-)
Approvals:
Jenkins Builder: Verified
laforge: Looks good to me, approved
diff --git a/src/octoi/e1oip.c b/src/octoi/e1oip.c
index 5dd3bbf..6a5a240 100644
--- a/src/octoi/e1oip.c
+++ b/src/octoi/e1oip.c
@@ -286,7 +286,7 @@
e1oip_line_set_name(iline, peer->name);
iline->cfg.batching_factor = 32;
- iline->cfg.prefill_frame_count = 400; /* 50ms */
+ iline->cfg.prefill_frame_count = 200; /* 25ms */
e1oip_line_reset(iline);
@@ -305,6 +305,7 @@
frame_rifo_init(&iline->e1t.rifo);
memset(&iline->e1t.last_frame, 0xff, sizeof(iline->e1t.last_frame));
iline->e1t.next_fn32 = 0;
+ iline->e1t.primed_rx_tdm = false;
}
void e1oip_line_destroy(struct e1oip_line *iline)
diff --git a/src/octoi/e1oip.h b/src/octoi/e1oip.h
index 70e1bbb..1a184d2 100644
--- a/src/octoi/e1oip.h
+++ b/src/octoi/e1oip.h
@@ -53,6 +53,7 @@
struct frame_rifo rifo;
uint8_t last_frame[BYTES_PER_FRAME]; /* last frame on the E1 side */
uint32_t next_fn32; /* next expected frame number */
+ bool primed_rx_tdm; /* Was RX RIFO primed */
} e1t;
/* TODO: statistics (RTT, frame loss, std deviation, alarms */
diff --git a/src/octoi/octoi.c b/src/octoi/octoi.c
index d2960ac..8585f0d 100644
--- a/src/octoi/octoi.c
+++ b/src/octoi/octoi.c
@@ -118,6 +118,12 @@
if (!peer->tdm_permitted)
return;
+ if (!iline->e1t.primed_rx_tdm) {
+ if (frame_rifo_frames(&iline->e1t.rifo) > iline->cfg.prefill_frame_count)
+ iline->e1t.primed_rx_tdm = true;
+ return;
+ }
+
for (int i = 0; i < fts; i++) {
uint8_t *cur = buf + BYTES_PER_FRAME*i;
rc = frame_rifo_out(&iline->e1t.rifo, cur);
--
To view, visit https://gerrit.osmocom.org/c/osmo-e1d/+/27834
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-e1d
Gerrit-Branch: master
Gerrit-Change-Id: I3a4b3846d3dbd1c99989e994ad95e609f2757219
Gerrit-Change-Number: 27834
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: tnt <tnt(a)246tNt.com>
Gerrit-MessageType: merged