[PATCH] osmo-bts[master]: l1sap: if lchan is in loopback, don't accept incoming RTP

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Sat Jun 24 10:57:15 UTC 2017


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

l1sap: if lchan is in loopback, don't accept incoming RTP

When the lchan is in loopback mode, we loop back all uplink blocks into
downlink blocks.  We do not processs any RTP frames for that lchan
anymore.  Rather, we discard those RTP frames to avoid mixing
looped-back samples with those received from remote.

Change-Id: I29ef4963e9c491c94c413cbc10436a2388c04d9b
---
M src/common/l1sap.c
1 file changed, 5 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/35/3035/1

diff --git a/src/common/l1sap.c b/src/common/l1sap.c
index d7e3fb3..0ab84e5 100644
--- a/src/common/l1sap.c
+++ b/src/common/l1sap.c
@@ -1168,6 +1168,11 @@
 	struct msgb *msg;
 	struct osmo_phsap_prim *l1sap;
 
+	/* if we're in loopback mode, we don't accept frames from the
+	 * RTP socket anymore */
+	if (lchan->loopback)
+		return;
+
 	msg = l1sap_msgb_alloc(rtp_pl_len);
 	if (!msg)
 		return;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I29ef4963e9c491c94c413cbc10436a2388c04d9b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>



More information about the gerrit-log mailing list