diff options
author | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2017-03-10 02:11:25 +0100 |
---|---|---|
committer | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2017-03-16 15:32:34 +0100 |
commit | c1ebe963f44006fe8b60304dcceeb22c5d14c2e3 (patch) | |
tree | bea32b1ed127b5da846c9f5e7bdb0ed6a1ded151 /openbsc/src/libmsc/gsm_04_08.c | |
parent | 3e82738b740830f53ac552f4c51430f1fd434684 (diff) |
more specifically conclude cm service requests
Don't end a CM Service Request "lock" too indiscriminately. Trigger only on new
transactions that start.
Change-Id: I4f64b8d91cfb1e61be4563594b2d6b23144af5bc
Diffstat (limited to 'openbsc/src/libmsc/gsm_04_08.c')
-rw-r--r-- | openbsc/src/libmsc/gsm_04_08.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/openbsc/src/libmsc/gsm_04_08.c b/openbsc/src/libmsc/gsm_04_08.c index f39785e8d..68ac3cf86 100644 --- a/openbsc/src/libmsc/gsm_04_08.c +++ b/openbsc/src/libmsc/gsm_04_08.c @@ -3464,6 +3464,7 @@ static int gsm0408_rcv_cc(struct gsm_subscriber_connection *conn, struct msgb *m } /* Assign transaction */ trans->conn = msc_conn_get(conn); + cm_service_request_concludes(conn, msg); } /* find function for current state and message */ @@ -3520,13 +3521,13 @@ static bool msg_is_initially_permitted(const struct gsm48_hdr *hdr) return false; } -static void -cm_service_request_concludes(struct gsm_subscriber_connection *conn, - struct msgb *msg) +void cm_service_request_concludes(struct gsm_subscriber_connection *conn, + struct msgb *msg) { /* If a CM Service Request was received before, this is the request the * conn was opened for. No need to wait for further messages. */ + if (!conn->received_cm_service_request) return; @@ -3580,15 +3581,6 @@ int gsm0408_dispatch(struct gsm_subscriber_connection *conn, struct msgb *msg) return silent_call_rx(conn, msg); #endif - /* Should we receive RR messages like an odd UTRAN Classmark Change, - * don't close the CM Service Request initiated conn yet. All others - * constitue a service and the conn can be closed, or something unknown - * is happening and we'd rather close the conn instead of idling around - * (we may add more specific exceptions as they become apparent). */ - if (pdisc != GSM48_PDISC_RR) { - cm_service_request_concludes(conn, msg); - } - switch (pdisc) { case GSM48_PDISC_CC: rc = gsm0408_rcv_cc(conn, msg); |