aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/libtrau/trau_mux.c
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2012-01-20 20:33:37 +0100
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-03-28 17:56:08 +0100
commit9967a57587b9dcc1eeeaa710159447eb098380f3 (patch)
tree6c8669b6fcce78cd202c14de486be9305f19dada /openbsc/src/libtrau/trau_mux.c
parentcea35aecdc846edf125ac7e7d0407967d4778ccb (diff)
rtp: Add handling of BFI (Bad Frame Indicatior) of received TRAU frames
If a bad TRAU frame is received, it is forwarded to MNCC application as GSM_BAD_FRAME. The application can now handle the GAP of missing audio. (e.g. by extrapolation) If TRAU frames are forwarded via RTP, bad frames are dropped, but frame counter and timestamp of RTP sender state is incremented. Conflicts: openbsc/src/libtrau/rtp_proxy.c [hfreyther: Merge without testcase, fix typo]
Diffstat (limited to 'openbsc/src/libtrau/trau_mux.c')
-rw-r--r--openbsc/src/libtrau/trau_mux.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/openbsc/src/libtrau/trau_mux.c b/openbsc/src/libtrau/trau_mux.c
index 3831a80ad..b37c7650e 100644
--- a/openbsc/src/libtrau/trau_mux.c
+++ b/openbsc/src/libtrau/trau_mux.c
@@ -245,7 +245,10 @@ struct msgb *trau_decode_fr(uint32_t callref,
i++;
j++;
}
- frame->msg_type = GSM_TCHF_FRAME;
+ if (tf->c_bits[11]) /* BFI */
+ frame->msg_type = GSM_BAD_FRAME;
+ else
+ frame->msg_type = GSM_TCHF_FRAME;
frame->callref = callref;
msgb_put(msg, sizeof(struct gsm_data_frame) + 33);