aboutsummaryrefslogtreecommitdiffstats
path: root/src/common/bts.c
diff options
context:
space:
mode:
authorPhilipp Maier <pmaier@sysmocom.de>2018-05-22 17:35:49 +0200
committerPhilipp Maier <pmaier@sysmocom.de>2018-05-25 15:41:35 +0200
commitf1e2d08022cf1cc7682ae5b618476ad7acb4f53a (patch)
tree2a2c245414edeca4e7f3a6fe838777d43397f941 /src/common/bts.c
parentae3da5f8c3761567c69c2bb8866ac6a5a51eeb7f (diff)
rtp: make port range configurable, assign correct port numbers
The current implementation does not allow the user to specify a port range in which the BTS is allowed to allocate a local RTP port. Also the ports the BTS picks do not match the policy described in RFC3550. An RTP Port must be at an even port number and the matching RTCP port must be at the following (odd) port number. The BTS currently picks random port numbers for both. - Add a VTY command to specify a port range in which the BTS may assign local ports. - Pick ports as described in RFC3550. Change-Id: Id75f1dfaf898ed8750d28b1c4840e188f4cfdc87 Related: OS#2825 OS#2635
Diffstat (limited to 'src/common/bts.c')
-rw-r--r--src/common/bts.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/common/bts.c b/src/common/bts.c
index 74630cc3..54e5480a 100644
--- a/src/common/bts.c
+++ b/src/common/bts.c
@@ -135,6 +135,9 @@ int bts_init(struct gsm_bts *bts)
bts->paging_state = paging_init(bts, 200, 0);
bts->ul_power_target = -75; /* dBm default */
bts->rtp_jitter_adaptive = false;
+ bts->rtp_port_range_start = 16384;
+ bts->rtp_port_range_end = 17407;
+ bts->rtp_port_range_next = bts->rtp_port_range_start;
/* configurable via OML */
bts->load.ccch.load_ind_period = 112;