summaryrefslogtreecommitdiffstats
path: root/openbsc/src
diff options
context:
space:
mode:
Diffstat (limited to 'openbsc/src')
-rw-r--r--openbsc/src/libmsc/a_iface.c14
-rw-r--r--openbsc/src/libmsc/gsm_04_11.c4
-rw-r--r--openbsc/src/libmsc/gsm_04_80.c10
-rw-r--r--openbsc/src/libmsc/msc_ifaces.c6
4 files changed, 15 insertions, 19 deletions
diff --git a/openbsc/src/libmsc/a_iface.c b/openbsc/src/libmsc/a_iface.c
index faf2adada..ae9f5baa1 100644
--- a/openbsc/src/libmsc/a_iface.c
+++ b/openbsc/src/libmsc/a_iface.c
@@ -25,14 +25,12 @@
#include <openbsc/debug.h>
#include <openbsc/gsm_data.h>
+#include <openbsc/msc_ifaces.h>
-int gsm0808_submit_dtap(struct gsm_subscriber_connection *conn,
- struct msgb *msg, int link_id, int allow_sacch)
+int a_tx(struct msgb *msg)
{
- LOGP(DMSC, LOGL_ERROR, "gsm0808_submit_dtap(): message to be sent to"
- " BSC, but A interface not yet implemented.\n%s\n",
- osmo_hexdump(msg->data, msg->len)
- );
+ LOGP(DMSC, LOGL_ERROR, "message to be sent to BSC, but A-interface"
+ " not implemented.\n%s\n", osmo_hexdump(msg->data, msg->len));
return -1;
}
@@ -58,7 +56,7 @@ int gsm48_tx_mm_serv_ack(struct gsm_subscriber_connection *conn)
DEBUGP(DMM, "-> CM SERVICE ACK\n");
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
/* 9.2.6 CM service reject */
@@ -75,5 +73,5 @@ int gsm48_tx_mm_serv_rej(struct gsm_subscriber_connection *conn,
DEBUGP(DMM, "-> CM SERVICE Reject cause: %d\n", value);
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
diff --git a/openbsc/src/libmsc/gsm_04_11.c b/openbsc/src/libmsc/gsm_04_11.c
index 9b75fd105..796f1056e 100644
--- a/openbsc/src/libmsc/gsm_04_11.c
+++ b/openbsc/src/libmsc/gsm_04_11.c
@@ -53,7 +53,7 @@
#include <openbsc/paging.h>
#include <openbsc/bsc_rll.h>
#include <openbsc/chan_alloc.h>
-#include <openbsc/bsc_api.h>
+#include <openbsc/msc_ifaces.h>
#ifdef BUILD_SMPP
#include "smpp_smsc.h"
@@ -124,7 +124,7 @@ static int gsm411_sendmsg(struct gsm_subscriber_connection *conn, struct msgb *m
{
DEBUGP(DLSMS, "GSM4.11 TX %s\n", osmo_hexdump(msg->data, msg->len));
msg->l3h = msg->data;
- return gsm0808_submit_dtap(conn, msg, UM_SAPI_SMS, 1);
+ return msc_tx_dtap(conn, msg);
}
/* Prefix msg with a 04.08/04.11 CP header */
diff --git a/openbsc/src/libmsc/gsm_04_80.c b/openbsc/src/libmsc/gsm_04_80.c
index f1e1f273f..13961a656 100644
--- a/openbsc/src/libmsc/gsm_04_80.c
+++ b/openbsc/src/libmsc/gsm_04_80.c
@@ -32,7 +32,7 @@
#include <openbsc/gsm_data.h>
#include <openbsc/gsm_04_08.h>
#include <openbsc/gsm_04_80.h>
-#include <openbsc/bsc_api.h>
+#include <openbsc/msc_ifaces.h>
#include <osmocom/gsm/gsm0480.h>
#include <osmocom/gsm/gsm_utils.h>
@@ -106,7 +106,7 @@ int gsm0480_send_ussd_response(struct gsm_subscriber_connection *conn,
| (1<<7); /* TI direction = 1 */
gh->msg_type = GSM0480_MTYPE_RELEASE_COMPLETE;
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
int gsm0480_send_ussd_reject(struct gsm_subscriber_connection *conn,
@@ -135,7 +135,7 @@ int gsm0480_send_ussd_reject(struct gsm_subscriber_connection *conn,
gh->proto_discr |= req->transaction_id | (1<<7); /* TI direction = 1 */
gh->msg_type = GSM0480_MTYPE_RELEASE_COMPLETE;
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
int gsm0480_send_ussdNotify(struct gsm_subscriber_connection *conn, int level, const char *text)
@@ -143,7 +143,7 @@ int gsm0480_send_ussdNotify(struct gsm_subscriber_connection *conn, int level, c
struct msgb *msg = gsm0480_gen_ussdNotify(level, text);
if (!msg)
return -1;
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
int gsm0480_send_releaseComplete(struct gsm_subscriber_connection *conn)
@@ -151,5 +151,5 @@ int gsm0480_send_releaseComplete(struct gsm_subscriber_connection *conn)
struct msgb *msg = gsm0480_gen_releaseComplete();
if (!msg)
return -1;
- return gsm0808_submit_dtap(conn, msg, 0, 0);
+ return msc_tx_dtap(conn, msg);
}
diff --git a/openbsc/src/libmsc/msc_ifaces.c b/openbsc/src/libmsc/msc_ifaces.c
index 453d92144..99f040e6a 100644
--- a/openbsc/src/libmsc/msc_ifaces.c
+++ b/openbsc/src/libmsc/msc_ifaces.c
@@ -28,10 +28,8 @@ static int msc_tx(struct gsm_subscriber_connection *conn, struct msgb *msg)
{
switch (conn->via_iface) {
case IFACE_A:
- LOGP(DMSC, LOGL_ERROR,
- "attempt to send message via A-interface, which is not yet implemented.\n");
- /* TODO: msg->dst = <A-iface token>; a_tx(msg); */
- return -1;
+ msg->dst = conn;
+ return a_tx(msg);
case IFACE_IU:
msg->dst = conn->iu.ue_ctx;