aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/libmsc/osmo_msc.c
diff options
context:
space:
mode:
Diffstat (limited to 'openbsc/src/libmsc/osmo_msc.c')
-rw-r--r--openbsc/src/libmsc/osmo_msc.c30
1 files changed, 4 insertions, 26 deletions
diff --git a/openbsc/src/libmsc/osmo_msc.c b/openbsc/src/libmsc/osmo_msc.c
index 604c100db..0e91512d7 100644
--- a/openbsc/src/libmsc/osmo_msc.c
+++ b/openbsc/src/libmsc/osmo_msc.c
@@ -26,6 +26,7 @@
#include <openbsc/transaction.h>
#include <openbsc/db.h>
+#include <openbsc/msc_api.h>
#include <openbsc/gsm_04_11.h>
static void msc_sapi_n_reject(struct gsm_subscriber_connection *conn, int dlci)
@@ -42,28 +43,6 @@ static int msc_clear_request(struct gsm_subscriber_connection *conn, uint32_t ca
return 1;
}
-static int msc_compl_l3(struct gsm_subscriber_connection *conn, struct msgb *msg,
- uint16_t chosen_channel)
-{
- gsm0408_new_conn(conn);
- gsm0408_dispatch(conn, msg);
-
- /*
- * If this is a silent call we want the channel to remain open as long as
- * possible and this is why we accept this connection regardless of any
- * pending transaction or ongoing operation.
- */
- if (conn->silent_call)
- return BSC_API_CONN_POL_ACCEPT;
- if (conn->loc_operation || conn->sec_operation || conn->anch_operation)
- return BSC_API_CONN_POL_ACCEPT;
- if (trans_has_conn(conn))
- return BSC_API_CONN_POL_ACCEPT;
-
- LOGP(DRR, LOGL_INFO, "MSC Complete L3: Rejecting connection.\n");
- return BSC_API_CONN_POL_REJECT;
-}
-
static void msc_dtap(struct gsm_subscriber_connection *conn, uint8_t link_id, struct msgb *msg)
{
gsm0408_dispatch(conn, msg);
@@ -143,7 +122,7 @@ struct bsc_api *msc_bsc_api() {
return &msc_handler;
}
-/* lchan release handling */
+/* conn release handling */
void msc_release_connection(struct gsm_subscriber_connection *conn)
{
/* skip when we are in release, e.g. due an error */
@@ -169,9 +148,8 @@ void msc_release_connection(struct gsm_subscriber_connection *conn)
* to restarting the timer. Set the new expiration time.
*/
if (conn->expire_timer_stopped)
- subscr_update_expire_lu(conn->subscr, conn->bts);
+ subscr_update_expire_lu(conn->network, conn->subscr);
conn->in_release = 1;
- gsm0808_clear(conn);
- subscr_con_free(conn);
+ msc_subscr_con_free(conn);
}