aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/include
diff options
context:
space:
mode:
authorJacob Erlbeck <jerlbeck@sysmocom.de>2013-12-03 14:43:34 +0100
committerJacob Erlbeck <jerlbeck@sysmocom.de>2013-12-10 11:11:42 +0100
commitdb2d431697609d473de433b7028f81ce499a02c0 (patch)
tree65830327458c4763f30589a60c462c2d68f89c6a /openbsc/include
parent55ba140da126c78013fe1a6055d750ee10b60ecf (diff)
mgcp/rtp: Add RTP header patch mode configuration
This adds datastructures and a VTY frontend to configure the different type of RTP header patching: SSRC and timestamp. Note that timestamp patching is not yet implemented. Sponsored-by: On-Waves ehf
Diffstat (limited to 'openbsc/include')
-rw-r--r--openbsc/include/openbsc/mgcp.h4
-rw-r--r--openbsc/include/openbsc/mgcp_internal.h10
2 files changed, 11 insertions, 3 deletions
diff --git a/openbsc/include/openbsc/mgcp.h b/openbsc/include/openbsc/mgcp.h
index 4e22e0f5e..8ab52ce1a 100644
--- a/openbsc/include/openbsc/mgcp.h
+++ b/openbsc/include/openbsc/mgcp.h
@@ -118,6 +118,10 @@ struct mgcp_trunk_config {
int omit_rtcp;
+ /* RTP patching */
+ int force_constant_ssrc; /* 0: don't, 1: once */
+ int force_constant_timing;
+
/* spec handling */
int force_realloc;
diff --git a/openbsc/include/openbsc/mgcp_internal.h b/openbsc/include/openbsc/mgcp_internal.h
index 0b52c1c06..02e193df2 100644
--- a/openbsc/include/openbsc/mgcp_internal.h
+++ b/openbsc/include/openbsc/mgcp_internal.h
@@ -83,6 +83,10 @@ struct mgcp_rtp_end {
int frames_per_packet;
char *fmtp_extra;
+ /* RTP patching */
+ int force_constant_ssrc;
+ int force_constant_timing;
+
/*
* Each end has a socket...
*/
@@ -142,9 +146,6 @@ struct mgcp_endpoint {
struct mgcp_rtp_state net_state;
struct mgcp_rtp_state bts_state;
- /* SSRC/seq/ts patching for loop */
- int allow_patch;
-
/* fields for re-transmission */
char *last_trans;
char *last_response;
@@ -176,6 +177,9 @@ static inline int endp_back_channel(int endpoint)
struct mgcp_trunk_config *mgcp_trunk_alloc(struct mgcp_config *cfg, int index);
struct mgcp_trunk_config *mgcp_trunk_num(struct mgcp_config *cfg, int index);
+void mgcp_rtp_end_config(struct mgcp_endpoint *endp, int expect_ssrc_change,
+ struct mgcp_rtp_end *rtp);
+
void mgcp_state_calc_loss(struct mgcp_rtp_state *s, struct mgcp_rtp_end *,
uint32_t *expected, int *loss);
uint32_t mgcp_state_calc_jitter(struct mgcp_rtp_state *);