From cb4340b8a443811a7bfa281a32937663b51c8d62 Mon Sep 17 00:00:00 2001 From: Oliver Smith Date: Fri, 6 Mar 2020 11:28:40 +0100 Subject: rsl: make IP DSCP configurable Related: OS#4438 Depends: libosmo-abis I41603db8c1286660ad57ac1c78a8fb393a2b080b Change-Id: Icdef5d40243fefdeae23f3bcf9c6702e8487928a --- src/common/rsl.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/common/rsl.c') diff --git a/src/common/rsl.c b/src/common/rsl.c index 10fb95e9..41dd2434 100644 --- a/src/common/rsl.c +++ b/src/common/rsl.c @@ -2009,8 +2009,15 @@ static int bind_rtp(struct gsm_bts *bts, struct osmo_rtp_socket *rs, const char bts->rtp_port_range_next += 2; - if (rc == 0) - return 0; + if (rc != 0) + continue; + + if (bts->rtp_ip_dscp != -1) { + if (osmo_rtp_socket_set_dscp(rs, bts->rtp_ip_dscp)) + LOGP(DRSL, LOGL_ERROR, "failed to set DSCP=%i: %s\n", + bts->rtp_ip_dscp, strerror(errno)); + } + return 0; } return -1; -- cgit v1.2.3