From 77008464be36bd7e2d953a4b0d63f96f72774b58 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Wed, 16 Jun 2010 14:10:45 +0800 Subject: [PATCH] bsc_api: Move BSC API between MSC and RSL code... The lowlevel BSC paging API is a simple wrapper around the RSL command. The BTS will automatically repeat these messages but if we end up with two MSC inputs we will need to count these messages somewhere... --- openbsc/include/openbsc/bsc_api.h | 2 ++ openbsc/src/bsc_api.c | 6 ++++++ openbsc/src/paging.c | 3 +-- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/openbsc/include/openbsc/bsc_api.h b/openbsc/include/openbsc/bsc_api.h index 05a5e4601..7747adab3 100644 --- a/openbsc/include/openbsc/bsc_api.h +++ b/openbsc/include/openbsc/bsc_api.h @@ -22,5 +22,7 @@ struct bsc_api { int bsc_api_init(struct gsm_network *network, struct bsc_api *api); int gsm0808_submit_dtap(struct gsm_subscriber_connection *conn, struct msgb *msg, int link_id); +int gsm0808_page(struct gsm_bts *bts, unsigned int page_group, + unsigned int mi_len, uint8_t *mi, int chan_type); #endif diff --git a/openbsc/src/bsc_api.c b/openbsc/src/bsc_api.c index 25b8b66c1..28fc324a3 100644 --- a/openbsc/src/bsc_api.c +++ b/openbsc/src/bsc_api.c @@ -59,6 +59,12 @@ int gsm0808_submit_dtap(struct gsm_subscriber_connection *conn, } } +int gsm0808_page(struct gsm_bts *bts, unsigned int page_group, unsigned int mi_len, + uint8_t *mi, int chan_type) +{ + return rsl_paging_cmd(bts, page_group, mi_len, mi, chan_type); +} + /* dequeue messages to layer 4 */ int bsc_upqueue(struct gsm_network *net) { diff --git a/openbsc/src/paging.c b/openbsc/src/paging.c index 12ed90341..ca3767864 100644 --- a/openbsc/src/paging.c +++ b/openbsc/src/paging.c @@ -92,8 +92,7 @@ static void page_ms(struct gsm_paging_request *request) mi_len = gsm48_generate_mid_from_tmsi(mi, request->subscr->tmsi); page_group = calculate_group(request->bts, request->subscr); - rsl_paging_cmd(request->bts, page_group, mi_len, mi, - request->chan_type); + gsm0808_page(request->bts, page_group, mi_len, mi, request->chan_type); } /*