summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2016-05-31 14:43:25 +0200
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2016-06-17 21:49:47 +0200
commitbae291bdafdfe180f92abd042374c07974df5fac (patch)
treeae91788f806b4266901753ddc7c39e7b468da609
parentd30a49498902ec25fc16a73c05bdc1ce16684de0 (diff)
trigger pdch defrag on do_lchan_free()
-rw-r--r--openbsc/src/libbsc/abis_rsl.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/openbsc/src/libbsc/abis_rsl.c b/openbsc/src/libbsc/abis_rsl.c
index fc5686283..e7719f9df 100644
--- a/openbsc/src/libbsc/abis_rsl.c
+++ b/openbsc/src/libbsc/abis_rsl.c
@@ -44,6 +44,7 @@
#include <osmocom/abis/e1_input.h>
#include <osmocom/gsm/rsl.h>
#include <osmocom/core/talloc.h>
+#include <openbsc/pdch_defrag.h>
#define RSL_ALLOC_SIZE 1024
#define RSL_ALLOC_HEADROOM 128
@@ -75,6 +76,8 @@ static void do_lchan_free(struct gsm_lchan *lchan)
lchan->ts->trx->bts->network->T3111 + 2, 0);
} else {
rsl_lchan_set_state(lchan, LCHAN_S_NONE);
+ /* defragment TCH/F+PDCH shared channels */
+ do_pdch_defrag(lchan->ts->trx->bts);
}
lchan_free(lchan);
}
@@ -644,6 +647,8 @@ static void error_timeout_cb(void *data)
/* go back to the none state */
LOGP(DRSL, LOGL_INFO, "%s is back in operation.\n", gsm_lchan_name(lchan));
rsl_lchan_set_state(lchan, LCHAN_S_NONE);
+ /* defragment TCH/F+PDCH shared channels */
+ do_pdch_defrag(lchan->ts->trx->bts);
}
static int rsl_rx_rf_chan_rel_ack(struct gsm_lchan *lchan);