Deprecate the "rtp bind-ip" configuration directive

Instead of explicitly having to specify the local IP address for RTP
sockets in the BTS, we just use "0.0.0.0" instead, which gets
translated to INADDR_ANY.

We still accept the configuration directive in old config files, but
when we write, the line will no longer be re-written to the file.

TODO: IMHO, the IPA RSL CRCX/MDCX actually permit the BSC to specify the
IP address on the BTS side, and we probably simply ignore this at this
point.
This commit is contained in:
Harald Welte 2013-02-03 16:35:07 +01:00
parent 6a2d89f48d
commit 550d22be5b
3 changed files with 4 additions and 12 deletions

View File

@ -51,7 +51,6 @@ struct gsm_bts_role_bts {
struct llist_head agch_queue;
struct paging_state *paging_state;
char *bsc_oml_host;
char *rtp_bind_host;
unsigned int rtp_jitter_buf_ms;
struct {
uint8_t ciphers; /* flags A5/1==0x1, A5/2==0x2, A5/3==0x4 */

View File

@ -1264,7 +1264,7 @@ static int rsl_rx_ipac_XXcx(struct msgb *msg)
lchan->abis_ip.rtp_socket->rx_cb = &bts_model_rtp_rx_cb;
rc = osmo_rtp_socket_bind(lchan->abis_ip.rtp_socket,
btsb->rtp_bind_host, -1);
"0.0.0.0", -1);
if (rc < 0) {
LOGP(DRSL, LOGL_ERROR,
"%s IPAC Failed to bind RTP/RTCP sockets\n",

View File

@ -183,7 +183,6 @@ static void config_write_bts_single(struct vty *vty, struct gsm_bts *bts)
vty_out(vty, " ipa unit-id %u %u%s",
bts->ip_access.site_id, bts->ip_access.bts_id, VTY_NEWLINE);
vty_out(vty, " oml remote-ip %s%s", btsb->bsc_oml_host, VTY_NEWLINE);
vty_out(vty, " rtp bind-ip %s%s", btsb->rtp_bind_host, VTY_NEWLINE);
vty_out(vty, " rtp jitter-buffer %u%s", btsb->rtp_jitter_buf_ms,
VTY_NEWLINE);
vty_out(vty, " paging queue-size %u%s", paging_get_queue_max(btsb->paging_state),
@ -303,20 +302,14 @@ DEFUN(cfg_bts_oml_ip,
#define RTP_STR "RTP parameters\n"
DEFUN(cfg_bts_rtp_bind_ip,
DEFUN_HIDDEN(cfg_bts_rtp_bind_ip,
cfg_bts_rtp_bind_ip_cmd,
"rtp bind-ip A.B.C.D",
RTP_STR "RTP local bind IP Address\n" "RTP local bind IP Address\n")
{
struct gsm_bts *bts = vty->index;
struct gsm_bts_role_bts *btsb = bts_role_bts(bts);
vty_out(vty, "%% rtp bind-ip is now deprecated%s", VTY_NEWLINE);
if (btsb->rtp_bind_host)
talloc_free(btsb->rtp_bind_host);
btsb->rtp_bind_host = talloc_strdup(btsb, argv[0]);
return CMD_SUCCESS;
return CMD_WARNING;
}
DEFUN(cfg_bts_rtp_jitbuf,