aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/chan_alloc.c
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-06-22 12:37:41 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-06-22 12:40:30 +0800
commitd7cb8aa275101cb7b59d2f40fed5d8b8041987ff (patch)
treeb5f1aef3cf24a3f84fd1f3d00626b61cb1a1f437 /openbsc/src/chan_alloc.c
parent38454904cbeb1881f63a3507fc48dde6e0cdcd3f (diff)
abis_rsl: Send the IMMEDIATE Assignment after the Channel Ack.
The Channel Activate might be sent to a different TRX than the Immediate Assignment. So we need to make sure that the channel is activated before we send the immediate assignment for the RACH. Another reason for that is according to GSM 08.58 we should take the frame number from the activate and use it for the starting time inside the immediate assignment message. We obviously do not do this yet. The code assumes that the BTS will either respond with a CHAN ACK or a CHAN NACK if not the lchan will remain in the request state. Conflicts: openbsc/include/openbsc/gsm_data.h openbsc/src/abis_rsl.c openbsc/src/chan_alloc.c
Diffstat (limited to 'openbsc/src/chan_alloc.c')
-rw-r--r--openbsc/src/chan_alloc.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/openbsc/src/chan_alloc.c b/openbsc/src/chan_alloc.c
index 1a189fb3c..2886c9a38 100644
--- a/openbsc/src/chan_alloc.c
+++ b/openbsc/src/chan_alloc.c
@@ -34,6 +34,8 @@
#include <openbsc/debug.h>
#include <openbsc/signal.h>
+#include <osmocore/talloc.h>
+
static int ts_is_usable(struct gsm_bts_trx_ts *ts)
{
/* FIXME: How does this behave for BS-11 ? */
@@ -330,6 +332,12 @@ void lchan_free(struct gsm_lchan *lchan)
}
for (i = 0; i < ARRAY_SIZE(lchan->neigh_meas); i++)
lchan->neigh_meas[i].arfcn = 0;
+
+ if (lchan->rqd_ref) {
+ talloc_free(lchan->rqd_ref);
+ lchan->rqd_ref = NULL;
+ lchan->rqd_ta = 0;
+ }
lchan->conn.silent_call = 0;
sig.lchan = lchan;