diff options
author | Andreas Eversberg <andreas@eversberg.eu> | 2013-12-05 14:37:11 +0100 |
---|---|---|
committer | Holger Hans Peter Freyther <holger@moiji-mobile.com> | 2014-01-27 14:39:06 +0100 |
commit | dcf38e1c9623f997d9b87c1a5868862581aa05cf (patch) | |
tree | 107d4b9f9122fe805df405158ff7524a7da95acd /openbsc/src/libbsc/handover_logic.c | |
parent | 88012b6e870d100e7d97b91f44897ce2d136d486 (diff) |
Add function to update TRAU muxer after assignment or handover
E1 based BTS use TRAU muxer to decode TRAU frames. After changing
channel from one timeslot to another (due to handover or assignment),
the TRAU muxer must be updated. The call reference of the call is
disconnected from the old channel and connected to the new channel.
Diffstat (limited to 'openbsc/src/libbsc/handover_logic.c')
-rw-r--r-- | openbsc/src/libbsc/handover_logic.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/openbsc/src/libbsc/handover_logic.c b/openbsc/src/libbsc/handover_logic.c index 9cf26af9d..36a758be6 100644 --- a/openbsc/src/libbsc/handover_logic.c +++ b/openbsc/src/libbsc/handover_logic.c @@ -39,6 +39,7 @@ #include <openbsc/signal.h> #include <osmocom/core/talloc.h> #include <openbsc/transaction.h> +#include <openbsc/trau_mux.h> struct bsc_handover { struct llist_head list; @@ -264,6 +265,10 @@ static int ho_gsm48_ho_compl(struct gsm_lchan *new_lchan) osmo_timer_del(&ho->T3103); + /* switch TRAU muxer for E1 based BTS from one channel to another */ + if (is_e1_bts(new_lchan->conn->bts)) + switch_trau_mux(ho->old_lchan, new_lchan); + /* Replace the ho lchan with the primary one */ if (ho->old_lchan != new_lchan->conn->lchan) LOGP(DHO, LOGL_ERROR, "Primary lchan changed during handover.\n"); @@ -278,8 +283,6 @@ static int ho_gsm48_ho_compl(struct gsm_lchan *new_lchan) rsl_lchan_set_state(ho->old_lchan, LCHAN_S_INACTIVE); lchan_release(ho->old_lchan, 0, RSL_REL_LOCAL_END); - /* do something to re-route the actual speech frames ! */ - llist_del(&ho->list); talloc_free(ho); |