diff options
author | Andreas Eversberg <jolly@eversberg.eu> | 2023-06-21 13:30:58 +0200 |
---|---|---|
committer | laforge <laforge@osmocom.org> | 2023-07-21 11:16:16 +0000 |
commit | 23b53e544f26dde49621f0f6d659e380644f84a2 (patch) | |
tree | a9c8944d31e997732b8d11adaee4e5cff975db22 | |
parent | 57b36e58cb90b98bbe4fff9e695a5a03ab471e2f (diff) |
ASCI: Receive messages from MSC-A role related to VGCS/VBS
Voice group call and voice broadcast call messages as well as assignment
result are forwarded to VGCS/VBS call control.
Change-Id: Ie68eedb8fcb064a55cd71b58630d7a8c8b5f29ad
Related: OS#4854
-rw-r--r-- | src/libmsc/msc_a.c | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/src/libmsc/msc_a.c b/src/libmsc/msc_a.c index 9f2420e40..0d8a747e3 100644 --- a/src/libmsc/msc_a.c +++ b/src/libmsc/msc_a.c @@ -1386,6 +1386,10 @@ int msc_a_up_l3(struct msc_a *msc_a, struct msgb *msg) #endif switch (pdisc) { + case GSM48_PDISC_GROUP_CC: + case GSM48_PDISC_BCAST_CC: + rc = gsm44068_rcv_bcc_gcc(msc_a, NULL, msg); + break; case GSM48_PDISC_CC: rc = gsm0408_rcv_cc(msc_a, msg); break; @@ -1422,11 +1426,23 @@ int msc_a_up_l3(struct msc_a *msc_a, struct msgb *msg) static void msc_a_up_call_assignment_complete(struct msc_a *msc_a, const struct ran_msg *ac) { - struct gsm_trans *cc_trans = msc_a->cc.active_trans; + struct gsm_trans *cc_trans = msc_a->cc.active_trans, *gcc_trans; struct rtp_stream *rtps_to_ran = msc_a->cc.call_leg ? msc_a->cc.call_leg->rtp[RTP_TO_RAN] : NULL; const struct gsm0808_speech_codec *codec_if_known = ac->assignment_complete.codec_present ? &ac->assignment_complete.codec : NULL; + /* For a voice group call, handling is performed by VGCS FSM */ + gcc_trans = trans_find_by_type(msc_a, TRANS_GCC); + if (gcc_trans) { + vgcs_vbs_caller_assign_cpl(gcc_trans); + return; + } + gcc_trans = trans_find_by_type(msc_a, TRANS_BCC); + if (gcc_trans) { + vgcs_vbs_caller_assign_cpl(gcc_trans); + return; + } + if (!rtps_to_ran) { LOG_MSC_A(msc_a, LOGL_ERROR, "Rx Assignment Complete, but no RTP stream is set up\n"); return; @@ -1513,6 +1529,18 @@ static void msc_a_up_call_assignment_failure(struct msc_a *msc_a, const struct r return; } + /* For a voice group call, release is performed by VGCS FSM */ + trans = trans_find_by_type(msc_a, TRANS_GCC); + if (trans) { + vgcs_vbs_caller_assign_fail(trans); + return; + } + trans = trans_find_by_type(msc_a, TRANS_BCC); + if (trans) { + vgcs_vbs_caller_assign_fail(trans); + return; + } + /* Otherwise, a silent call might be active */ trans = trans_find_by_type(msc_a, TRANS_SILENT_CALL); if (trans) { |