[PATCH] osmo-msc[master]: libmsc/ussd: implement basic USSD session management

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Vadim Yanitskiy gerrit-no-reply at lists.osmocom.org
Mon Apr 9 19:15:20 UTC 2018


Review at  https://gerrit.osmocom.org/7699

libmsc/ussd: implement basic USSD session management

During some long period, including the OpenBSC time, the USSD
processing code was (and still is) pretty trivial, so there
was no transaction management, nor connection reference
counting.

Meanwhile, according to GSM TS 04.10, section 2.2.6 "Multiple
supplementary service invocations", call independent SS/USSD
transactions can exist in parallel with other CM-Layer and MM
transactions. Several call independent SS/USSD transactions
can be used simultaneously.

Thus, a single USSD session is identified by:

  - MM / CM connection (pointer address),
  - Transaction ID (see TS GSM 04.08).

This change introduces a new structure, named 'ussd_session',
that corresponds to a single SS/USSD-session, and allows a
subscriber to have a few concurrent sessions in parallel.

Also, this facilitates the further implementation of network
originated SS/USSD-sessions, and the development of external
USSD interface.

Change-Id: I21c6777cb88f1f4f80f75dcd39734e952bd4e8b0
---
M include/osmocom/msc/ussd.h
M src/libmsc/transaction.c
M src/libmsc/ussd.c
M tests/msc_vlr/msc_vlr_test_authen_reuse.err
M tests/msc_vlr/msc_vlr_test_gsm_authen.err
M tests/msc_vlr/msc_vlr_test_gsm_ciph.err
M tests/msc_vlr/msc_vlr_test_no_authen.err
M tests/msc_vlr/msc_vlr_test_reject_concurrency.err
M tests/msc_vlr/msc_vlr_test_umts_authen.err
9 files changed, 486 insertions(+), 134 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/99/7699/1

diff --git a/include/osmocom/msc/ussd.h b/include/osmocom/msc/ussd.h
index 6c821b1..b4144ab 100644
--- a/include/osmocom/msc/ussd.h
+++ b/include/osmocom/msc/ussd.h
@@ -12,6 +12,40 @@
 /* Forward declarations to avoid mutual include */
 struct gsm_subscriber_connection;
 struct gsm_network;
+struct gsm_trans;
+
+struct ussd_session {
+	/**
+	 * GSM TS 04.10, section 2.2.6 "Multiple supplementary service
+	 * invocations" says: Call independent SS transactions can exist
+	 * in parallel with other CM-Layer and MM transactions. Several
+	 * call independent SS transactions can be used simultaneously.
+	 *
+	 * So, a single USSD session is identified by:
+	 *
+	 *   - MM / CM connection (pointer address),
+	 *   - Transaction ID (see TS GSM 04.08).
+	 *
+	 * Multiple operations may be sent on the same transaction
+	 * (see session), and are identified by Invoke ID.
+	 */
+	struct gsm_subscriber_connection *conn;
+	struct gsm_trans *trans;
+
+	/* A link to the global sessions list */
+	struct llist_head list;
+	/* An unique session ID */
+	uint32_t sid;
+};
+
+uint32_t ussd_session_id_gen(void);
+struct ussd_session *ussd_session_alloc(struct gsm_network *net);
+void ussd_session_free(struct ussd_session *session);
+
+struct ussd_session *ussd_session_get_by_sid(uint32_t sid);
+struct ussd_session *ussd_session_get(
+	struct gsm_subscriber_connection *conn,
+	struct gsm_trans *trans);
 
 int ussd_init(struct gsm_network *net);
 void ussd_shutdown(struct gsm_network *net);
diff --git a/src/libmsc/transaction.c b/src/libmsc/transaction.c
index 5b033dc..f3da003 100644
--- a/src/libmsc/transaction.c
+++ b/src/libmsc/transaction.c
@@ -137,6 +137,9 @@
 		_gsm411_sms_trans_free(trans);
 		conn_usage_token = MSC_CONN_USE_TRANS_SMS;
 		break;
+	case GSM48_PDISC_NC_SS:
+		conn_usage_token = MSC_CONN_USE_TRANS_USSD;
+		break;
 	}
 
 	if (trans->paging_request) {
diff --git a/src/libmsc/ussd.c b/src/libmsc/ussd.c
index 22d1ba8..7f72a65 100644
--- a/src/libmsc/ussd.c
+++ b/src/libmsc/ussd.c
@@ -3,6 +3,7 @@
 /* (C) 2008-2009 by Harald Welte <laforge at gnumonks.org>
  * (C) 2008, 2009 by Holger Hans Peter Freyther <zecke at selfish.org>
  * (C) 2009 by Mike Haben <michael.haben at btinternet.com>
+ * (C) 2018 by Vadim Yanitskiy <axilirator at gmail.com>
  *
  * All Rights Reserved
  *
@@ -29,6 +30,9 @@
 #include <string.h>
 #include <errno.h>
 
+#include <osmocom/core/linuxlist.h>
+#include <osmocom/core/talloc.h>
+
 #include <osmocom/msc/gsm_04_80.h>
 #include <osmocom/msc/gsm_subscriber.h>
 #include <osmocom/msc/debug.h>
@@ -36,9 +40,102 @@
 #include <osmocom/msc/vlr.h>
 #include <osmocom/msc/ussd.h>
 #include <osmocom/msc/gsm_04_08.h>
+#include <osmocom/msc/transaction.h>
 
-static int (*ussd_handler)(struct gsm_subscriber_connection *conn,
+static int (*ussd_handler)(struct ussd_session *session,
 	const struct ss_request *req) = NULL;
+
+/* Global sessions list */
+static LLIST_HEAD(ussd_active_sessions);
+
+uint32_t ussd_session_id_gen(void)
+{
+	static uint32_t sid_src = 0;
+	return sid_src++;
+}
+
+struct ussd_session *ussd_session_alloc(struct gsm_network *net)
+{
+	struct ussd_session *session;
+
+	DEBUGP(DMM, "Allocate a new USSD session\n");
+
+	/* Allocate a new session */
+	session = talloc_zero(net, struct ussd_session);
+	if (!session)
+		return NULL;
+
+	/* Generate unique session ID */
+	session->sid = ussd_session_id_gen();
+	talloc_set_name(session, "ussd_session_%u", session->sid);
+
+	/* Add to the session list */
+	llist_add_tail(&session->list, &ussd_active_sessions);
+
+	return session;
+}
+
+struct ussd_session *ussd_session_get_by_sid(uint32_t sid)
+{
+	struct ussd_session *session;
+
+	/* Iterate over all existing sessions */
+	llist_for_each_entry(session, &ussd_active_sessions, list) {
+		/* Compare session ID */
+		if (session->sid != sid)
+			continue;
+
+		DEBUGP(DMM, "Found a USSD session (sid=%u)\n", session->sid);
+		return session;
+	}
+
+	return NULL;
+}
+
+struct ussd_session *ussd_session_get(
+	struct gsm_subscriber_connection *conn,
+	struct gsm_trans *trans)
+{
+	struct ussd_session *session;
+
+	/* Prevent NULL-pointer dereference */
+	OSMO_ASSERT(conn);
+	OSMO_ASSERT(trans);
+
+	/* Iterate over all existing sessions */
+	llist_for_each_entry(session, &ussd_active_sessions, list) {
+		/* MM / CM connection */
+		if (session->conn != conn)
+			continue;
+
+		/* Transaction ID */
+		if (session->trans != trans)
+			continue;
+
+		DEBUGP(DMM, "Found a USSD session for subscriber %s "
+			"(trans_id=%x, sid=%u)\n", vlr_subscr_name(conn->vsub),
+			session->trans->transaction_id, session->sid);
+		return session;
+	}
+
+	return NULL;
+}
+
+void ussd_session_free(struct ussd_session *session)
+{
+	DEBUGP(DMM, "Deallocate an USSD session\n");
+
+	/* Prevent NULL-pointer dereference */
+	OSMO_ASSERT(session);
+
+	/* Free transaction if any */
+	if (session->trans)
+		trans_free(session->trans);
+
+	/* Unlink and free */
+	llist_del(&session->list);
+	talloc_free(session);
+}
 
 /* Declarations of USSD strings to be recognised */
 const char USSD_TEXT_OWN_NUMBER[] = "*#100#";
@@ -58,7 +155,7 @@
 	return gsm0480_send_ussd_response(conn, response_string, req);
 }
 
-static int ussd_handler_internal(struct gsm_subscriber_connection *conn,
+static int ussd_handler_internal(struct ussd_session *session,
 	const struct ss_request *req)
 {
 	int rc;
@@ -67,50 +164,63 @@
 	if (req->ussd_text[0] == '\0' || req->ussd_text[0] == 0xFF) {
 		if (req->ss_code > 0) {
 			/* Assume interrogateSS or modification of it and reject */
-			rc = gsm0480_send_ussd_reject(conn, req);
+			rc = gsm0480_send_ussd_reject(session->conn, req);
 			return rc;
 		}
 		/* Still assuming a Release-Complete and returning */
 		return 0;
 	}
 
-	msc_subscr_conn_communicating(conn);
 	if (!strcmp(USSD_TEXT_OWN_NUMBER, (const char *)req->ussd_text)) {
 		DEBUGP(DMM, "USSD: Own number requested\n");
-		rc = send_own_number(conn, req);
+		rc = send_own_number(session->conn, req);
 	} else {
 		DEBUGP(DMM, "Unhandled USSD %s\n", req->ussd_text);
-		rc = gsm0480_send_ussd_reject(conn, req);
+		rc = gsm0480_send_ussd_reject(session->conn, req);
 	}
+
+	/* No need to keep session anymore */
+	ussd_session_free(session);
 
 	return rc;
 }
 
-static int ussd_handler_dummy(struct gsm_subscriber_connection *conn,
+static int ussd_handler_dummy(struct ussd_session *session,
 	const struct ss_request *req)
 {
+	int rc;
+
 	DEBUGP(DMM, "USSD support disabled, rejecting request\n");
 
 	/* FIXME: use a proper problem code */
-	return gsm0480_send_ussd_reject(conn, req);
+	rc = gsm0480_send_ussd_reject(session->conn, req);
+
+	/* No need to keep session anymore */
+	ussd_session_free(session);
+
+	return rc;
 }
 
 /* Entrypoint - handler function common to all mobile-originated USSDs */
 int handle_rcv_ussd(struct gsm_subscriber_connection *conn, struct msgb *msg)
 {
-	int rc;
+	struct gsm48_hdr *gh = msgb_l3(msg);
+	struct ussd_session *session;
+	struct gsm_trans *trans;
 	struct ss_request req;
-	struct gsm48_hdr *gh;
+	uint8_t pdisc, tid;
+	int rc;
 
-	/* TODO: Use subscriber_connection ref-counting if we ever want
-	 * to keep the connection alive due ot ongoing USSD exchange.
-	 * As we answer everytying synchronously so far, there's no need
-	 * yet */
+	pdisc = gsm48_hdr_pdisc(gh);
+	tid = gsm48_hdr_trans_id_flip_ti(gh);
+	trans = trans_find_by_id(conn, pdisc, tid);
 
-	cm_service_request_concludes(conn, msg);
+	DEBUGP(DMM, "Received SS/USSD data (trans_id=%x)\n", tid);
+
+	/* Make sure we have subscriber data */
+	OSMO_ASSERT(conn->vsub);
 
 	memset(&req, 0, sizeof(req));
-	gh = msgb_l3(msg);
 	rc = gsm0480_decode_ss_request(gh, msgb_l3len(msg), &req);
 	if (!rc) {
 		LOGP(DMM, LOGL_ERROR, "SS/USSD message parsing error, "
@@ -120,8 +230,45 @@
 		return -EPROTO;
 	}
 
+	/* Allocate a new transaction if required */
+	if (!trans) {
+		DEBUGP(DMM, " -> (new transaction)\n");
+
+		trans = trans_alloc(conn->network, conn->vsub, pdisc, tid, 0);
+		if (!trans) {
+			LOGP(DMM, LOGL_ERROR, " -> No memory for trans\n");
+			/* FIXME: send some error message */
+			return -ENOMEM;
+		}
+
+		trans->conn = msc_subscr_conn_get(conn, MSC_CONN_USE_TRANS_USSD);
+		cm_service_request_concludes(conn, msg);
+	}
+
+	/* Attempt to find a session for this connection */
+	session = ussd_session_get(conn, trans);
+	if (!session) {
+		/* Allocate a new session */
+		session = ussd_session_alloc(conn->network);
+		if (!session) {
+			LOGP(DMM, LOGL_ERROR, " -> No memory for session\n");
+			/* FIXME: send some error message */
+			return -ENOMEM;
+		}
+
+		/* Associate the current session data */
+		session->trans = trans;
+		session->conn = conn;
+	}
+
 	OSMO_ASSERT(ussd_handler);
-	return ussd_handler(conn, &req);
+	rc = ussd_handler(session, &req);
+	if (rc)
+		return rc;
+
+	msc_subscr_conn_communicating(conn);
+
+	return 0;
 }
 
 int ussd_init(struct gsm_network *net)
@@ -142,9 +289,16 @@
 
 void ussd_shutdown(struct gsm_network *net)
 {
+	struct ussd_session *session, *session_next;
+
 	/**
-	 * Do nothing for now
 	 * TODO: close connection with external USSD gateway
-	 * TODO: close all active USSD connections
 	 */
+
+	/* Close all active USSD connections */
+	llist_for_each_entry_safe(session, session_next,
+			&ussd_active_sessions, list) {
+		/* Unlink and free */
+		ussd_session_free(session);
+	}
 }
diff --git a/tests/msc_vlr/msc_vlr_test_authen_reuse.err b/tests/msc_vlr/msc_vlr_test_authen_reuse.err
index e96fce8..c397974 100644
--- a/tests/msc_vlr/msc_vlr_test_authen_reuse.err
+++ b/tests/msc_vlr/msc_vlr_test_authen_reuse.err
@@ -258,17 +258,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -379,17 +386,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -708,17 +722,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -839,17 +860,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1146,17 +1174,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1253,17 +1288,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1360,17 +1402,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1689,17 +1738,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1806,17 +1862,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -1923,17 +1986,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -2244,17 +2314,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -2587,17 +2664,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
diff --git a/tests/msc_vlr/msc_vlr_test_gsm_authen.err b/tests/msc_vlr/msc_vlr_test_gsm_authen.err
index 35bda27..469d93a 100644
--- a/tests/msc_vlr/msc_vlr_test_gsm_authen.err
+++ b/tests/msc_vlr/msc_vlr_test_gsm_authen.err
@@ -251,17 +251,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000004620)
@@ -736,17 +743,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(50462976){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(50462976)
@@ -1805,17 +1819,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
diff --git a/tests/msc_vlr/msc_vlr_test_gsm_ciph.err b/tests/msc_vlr/msc_vlr_test_gsm_ciph.err
index 632f13e..322f775 100644
--- a/tests/msc_vlr/msc_vlr_test_gsm_ciph.err
+++ b/tests/msc_vlr/msc_vlr_test_gsm_ciph.err
@@ -277,17 +277,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000004620)
@@ -811,17 +818,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(50462976){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(50462976)
@@ -1979,17 +1993,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
diff --git a/tests/msc_vlr/msc_vlr_test_no_authen.err b/tests/msc_vlr/msc_vlr_test_no_authen.err
index be2d537..fdba38f 100644
--- a/tests/msc_vlr/msc_vlr_test_no_authen.err
+++ b/tests/msc_vlr/msc_vlr_test_no_authen.err
@@ -165,17 +165,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000004620)
@@ -526,17 +533,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(50462976){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(50462976){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(50462976){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(50462976){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(50462976)
diff --git a/tests/msc_vlr/msc_vlr_test_reject_concurrency.err b/tests/msc_vlr/msc_vlr_test_reject_concurrency.err
index bd7b47c..abcf50c 100644
--- a/tests/msc_vlr/msc_vlr_test_reject_concurrency.err
+++ b/tests/msc_vlr/msc_vlr_test_reject_concurrency.err
@@ -1096,17 +1096,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:46071: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:46071 callref 0) New transaction
+DREF VLR subscr MSISDN:46071 usage increases to: 3
+DREF MSISDN:46071: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:46071: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:46071: MSISDN = 46071
 DMSC msc_tx 43 bytes to MSISDN:46071 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d27310cd06bbc51a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:46071 usage decreases to: 2
+DREF MSISDN:46071: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000004620){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000004620){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000004620)
diff --git a/tests/msc_vlr/msc_vlr_test_umts_authen.err b/tests/msc_vlr/msc_vlr_test_umts_authen.err
index ddfbb11..b3cdc60 100644
--- a/tests/msc_vlr/msc_vlr_test_umts_authen.err
+++ b/tests/msc_vlr/msc_vlr_test_umts_authen.err
@@ -264,17 +264,24 @@
   MSC <--RAN_GERAN_A-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_GERAN_A
 - DTAP --RAN_GERAN_A--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)
@@ -749,17 +756,24 @@
   MSC <--RAN_UTRAN_IU-- MS: NCSS:0x3b
 DREF MSISDN:42342: MSC conn use + dtap == 2 (0x6)
 DRLL Dispatching 04.08 message NCSS:0x3b (0xb:0x3b)
+DMM Received SS/USSD data (trans_id=8)
+DMM  -> (new transaction)
+DCC (ti 08 sub MSISDN:42342 callref 0) New transaction
+DREF VLR subscr MSISDN:42342 usage increases to: 3
+DREF MSISDN:42342: MSC conn use + trans_ussd == 3 (0x26)
 DMM MSISDN:42342: rx msg NCSS:0x3b: received_cm_service_request changes to false
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_COMMUNICATING
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_COMMUNICATING
+DMM Allocate a new USSD session
 DMM USSD: Own number requested
 DMM MSISDN:42342: MSISDN = 42342
 DMSC msc_tx 43 bytes to MSISDN:42342 via RAN_UTRAN_IU
 - DTAP --RAN_UTRAN_IU--> MS: NCSS:0x2a: 8b2a1c27a225020100302002013b301b04010f0416d9775d0e2ae3e965f73cfd7683d273104d36a3c91a0d
 - DTAP matches expected message
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: subscr_conn_fsm_release_when_unused: releasing conn
-DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_COMMUNICATING}: state_chg to SUBSCR_CONN_S_RELEASED
+DMM Deallocate an USSD session
+DREF VLR subscr MSISDN:42342 usage decreases to: 2
+DREF MSISDN:42342: MSC conn use - trans_ussd == 2 (0x6)
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: Received Event SUBSCR_CONN_E_RELEASE_WHEN_UNUSED
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: subscr_conn_fsm_release_when_unused: releasing conn
+DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_ACCEPTED}: state_chg to SUBSCR_CONN_S_RELEASED
 DMM Subscr_Conn(901700000010650){SUBSCR_CONN_S_RELEASED}: Terminating (cause = OSMO_FSM_TERM_REGULAR)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Terminating (cause = OSMO_FSM_TERM_PARENT)
 DVLR Process_Access_Request_VLR(901700000010650){PR_ARQ_S_DONE}: Removing from parent Subscr_Conn(901700000010650)

-- 
To view, visit https://gerrit.osmocom.org/7699
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I21c6777cb88f1f4f80f75dcd39734e952bd4e8b0
Gerrit-PatchSet: 1
Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com>



More information about the gerrit-log mailing list