aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2011-06-04 15:12:57 +0200
committerDaniel Willmann <daniel@totalueberwachung.de>2011-11-04 12:27:07 +0100
commit613ae1a56aecb95bc978996ca36fc16be8cdb68c (patch)
tree8e8eecc78bd11ec15277d9b5405aa6185eadbd8c
parenta388797c81d8a66ba28298232c2af987a3ef453d (diff)
bsc: Move the bsc_filter to use the osmo_bsc_sccp_con
-rw-r--r--openbsc/src/osmo-bsc/osmo_bsc_bssap.c2
-rw-r--r--openbsc/src/osmo-bsc/osmo_bsc_filter.c13
2 files changed, 8 insertions, 7 deletions
diff --git a/openbsc/src/osmo-bsc/osmo_bsc_bssap.c b/openbsc/src/osmo-bsc/osmo_bsc_bssap.c
index cda2bbec8..25a99d737 100644
--- a/openbsc/src/osmo-bsc/osmo_bsc_bssap.c
+++ b/openbsc/src/osmo-bsc/osmo_bsc_bssap.c
@@ -365,7 +365,7 @@ static int bssmap_handle_assignm_req(struct osmo_bsc_sccp_con *conn,
* the correct value.
*/
full_rate = 0;
- msc = &network->bsc_data->msc;
+ msc = conn->msc;
for (supported = 0;
chan_mode == GSM48_CMODE_SIGN && supported < msc->audio_length;
++supported) {
diff --git a/openbsc/src/osmo-bsc/osmo_bsc_filter.c b/openbsc/src/osmo-bsc/osmo_bsc_filter.c
index fce38ce81..9d6909caa 100644
--- a/openbsc/src/osmo-bsc/osmo_bsc_filter.c
+++ b/openbsc/src/osmo-bsc/osmo_bsc_filter.c
@@ -122,13 +122,13 @@ int bsc_scan_bts_msg(struct gsm_subscriber_connection *conn, struct msgb *msg)
static void send_welcome_ussd(struct gsm_subscriber_connection *conn)
{
- struct gsm_network *net;
- net = conn->bts->network;
+ struct osmo_bsc_sccp_con *bsc;
- if (!net->bsc_data->msc.ussd_welcome_txt)
+ bsc = conn->sccp_con;
+ if (!bsc || !bsc->msc->ussd_welcome_txt);
return;
- gsm0480_send_ussdNotify(conn, 1, net->bsc_data->msc.ussd_welcome_txt);
+ gsm0480_send_ussdNotify(conn, 1, bsc->msc->ussd_welcome_txt);
gsm0480_send_releaseComplete(conn);
}
@@ -137,6 +137,7 @@ static void send_welcome_ussd(struct gsm_subscriber_connection *conn)
*/
int bsc_scan_msc_msg(struct gsm_subscriber_connection *conn, struct msgb *msg)
{
+ struct osmo_msc_data *msc;
struct gsm_network *net;
struct gsm48_loc_area_id *lai;
struct gsm48_hdr *gh;
@@ -150,10 +151,10 @@ int bsc_scan_msc_msg(struct gsm_subscriber_connection *conn, struct msgb *msg)
gh = (struct gsm48_hdr *) msgb_l3(msg);
mtype = gh->msg_type & 0xbf;
net = conn->bts->network;
+ msc = conn->sccp_con->msc;
if (mtype == GSM48_MT_MM_LOC_UPD_ACCEPT) {
- if (net->bsc_data->msc.core_ncc != -1 ||
- net->bsc_data->msc.core_mcc != -1) {
+ if (msc->core_ncc != -1 || msc->core_mcc != -1) {
if (msgb_l3len(msg) >= sizeof(*gh) + sizeof(*lai)) {
lai = (struct gsm48_loc_area_id *) &gh->data[0];
gsm48_generate_lai(lai, net->country_code,