pespin has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/37527?usp=email )
Change subject: asterisk: extensions.conf: Allow extra MO call from SIP UA which HOLDed previous call
......................................................................
asterisk: extensions.conf: Allow extra MO call from SIP UA which HOLDed previous call
We need to keep track of the SIP UA using the IMS endpoint, so that when
the IMS call is set on HOLD we can identidy that the same SIP UA can
still initiate new calls on the IMS endpoint.
Related: SYS#7003
Change-Id: Idad9e613669466f3aac8b1c7b43f8d9b6e0494e6
---
M ttcn3-asterisk-ims-ue-test/asterisk/extensions.conf
1 file changed, 59 insertions(+), 9 deletions(-)
Approvals:
Jenkins Builder: Verified
jolly: Looks good to me, but someone else must approve
pespin: Looks good to me, approved
diff --git a/ttcn3-asterisk-ims-ue-test/asterisk/extensions.conf b/ttcn3-asterisk-ims-ue-test/asterisk/extensions.conf
index fdfae23..e2ec574 100644
--- a/ttcn3-asterisk-ims-ue-test/asterisk/extensions.conf
+++ b/ttcn3-asterisk-ims-ue-test/asterisk/extensions.conf
@@ -1,3 +1,11 @@
+[globals]
+; local SIP UA Channels (PJSIP/50X-*) using the IMS endpoint are put in this group.
+; This group is used as a semaphore/mutex by using COUNT_GROUP() on it.
+IMS_GROUP=ims_group
+; Stores channel name of local SIP UA (PJSIP/50X-*) using the IMS service (in a call)
+; This is used to figure out which local SIP UA can create extra calls due to having its other IMS calls on HOLD.
+IMS_PEER=none
+
[get-valid-endpoints-500]
; usage: no arguments, returns DIALGROUP object of registered and valid 050x endpoints
exten => s,1,Verbose(5, Entering get-valid-endpoints gosub.)
@@ -19,6 +27,7 @@
[from-phone]
+; Local SIP UA calls 500, broadcast to all other available local SIP UAs:
exten => 0500,1,Verbose(5,${EXTEN}: Call all registered pjsips from ${CALLERID(num)})
same => n,Gosub(get-valid-endpoints-500,s,1())
same => n,Set(DIALGROUP(CALL_EVERYONE_LIST)=${GOSUB_RETVAL})
@@ -26,16 +35,26 @@
same => n,Dial(${DIALGROUP(CALL_EVERYONE_LIST)})
same => n,Hangup(16)
+; Local SIP UA calls 50X, call the target local SIP UA:
exten => _050X,1,Verbose(5,${EXTEN}: Call pjsip endpoint from ${CALLERID(num)})
same => n,Dial(PJSIP/${EXTEN})
same => n,Hangup(16)
-exten => _.!,1,Verbose(5,${EXTEN}: Call external number from ${CALLERID(num)})
- same => n,Set(GROUP()=IMSgroup)
- same => n,GotoIf($[${GROUP_COUNT(IMSgroup)} > 1]?999)
+; MO Call SIP UA -> IMS:
+exten => _X.!,1,Verbose(5,${EXTEN}: Call external number from ${CALLERID(num)}, IMS DEVICE_STATE=${DEVICE_STATE(PJSIP/volte_ims)}, IMS_PEER=${GLOBAL(IMS_PEER)})
+ ; Allow only 1 MO call towards IMS, or extra ones if the same SIP UA has put previous call(s) on HOLD:
+ same => n,Set(GROUP()=${GLOBAL(IMS_GROUP)})
+ same => n,Set(ALLOW_EXTRA_CALL=$[ $["${DEVICE_STATE(PJSIP/volte_ims)}" == "ONHOLD"] & $["${GLOBAL(IMS_PEER)}" == "PJSIP/${CALLERID(num)}"] ])
+ same => n,GotoIf($[ $[ ${GROUP_COUNT(${GLOBAL(IMS_GROUP)})} > 1] & !${ALLOW_EXTRA_CALL} ]?999)
+ same => n,Set(GLOBAL(IMS_PEER)=PJSIP/${CALLERID(num)})
same => n,Dial(PJSIP/${EXTEN}@volte_ims)
+ ; Channel is removed from GROUP() automatically when it is destroyed after the call finishes.
+ ; It's fine leaving IMS_PEER set since anyway it's only checked in the case where there's a call in place (GROUP_COUNT()>1),
+ ; so it will be set properly whenever an initial call enters the exclusion zone guarded by GROUP_COUNT().
same => n,Hangup(16)
- same => 999,Verbose(1,${EXTEN}: VoLTE client already busy (${GROUP_COUNT(IMSgroup)}) rejecting call from SIP UA ${CALLERID(num)})
+
+ ; Reject path:
+ same => 999,Verbose(1,${EXTEN}: VoLTE client already busy (${GROUP_COUNT(${GLOBAL(IMS_GROUP)})}, ${GLOBAL(IMS_PEER)}) rejecting call from SIP UA ${CALLERID(num)})
same => n,Set(DIALSTATUS=CHANUNAVAIL)
@@ -57,16 +76,33 @@
same => n,ExecIf($[${ENDPOINT_4_EXPR} != 0]?Set(DIALGROUP(CALL_VALID_LIST,add)=PJSIP/0504))
same => n,Return(${DIALGROUP(CALL_VALID_LIST)})
+[volte-ims-call-established]
+; no arguments, SUB to set global variable IMS_PEER to the Channel name of the SIP UA (501-504) using the IMS endpoint
+; This SUB (Dial(U())) runs under the Channel context of the SIP UA who answered the MT call.
+exten => s,1,Verbose(5, PJSIP/${CALLERID(num)}: Entering volte-ims-call-established gosub.)
+ same => n,Set(GLOBAL(IMS_PEER)=PJSIP/${CALLERID(num)})
+ same => n,Return()
[volte_ims]
-exten => _.!,1,Verbose(5,${EXTEN}: Call internal number from ${CALLERID(num)})
- same => n,Set(GROUP()=IMSgroup)
- same => n,GotoIf($[${GROUP_COUNT(IMSgroup)} > 1]?999)
+; MT Call IMS -> SIP UA:
+exten => _X.!,1,Verbose(5,${EXTEN}: Call internal number from ${CALLERID(num)}, IMS DEVICE_STATE=${DEVICE_STATE(PJSIP/volte_ims)}, IMS_PEER=${GLOBAL(IMS_PEER)})
+ ; If IMS endpoint is already in use, reject it (999):
+ same => n,Set(GROUP()=${GLOBAL(IMS_GROUP)})
+ same => n,GotoIf($[${GROUP_COUNT(${GLOBAL(IMS_GROUP)})} > 1]?999)
+ ; Figure out SIP UAs to ring:
same => n,Gosub(get-valid-endpoints-from-volte-ims,s,1())
same => n,Set(DIALGROUP(CALL_EVERYONE_LIST)=${GOSUB_RETVAL})
+ ; Process call establishment:
same => n,WaitForPrecondition(10,2000)
- same => n,Dial(${DIALGROUP(CALL_EVERYONE_LIST)})
+ ; OUTBOUND_GROUP var tells Dial() app to set the GROUP() of the newly created channel (501-504) instead of the calling channel (volte_ims).
+ ; This way IMS_GROUP always contains channels PJSIP/50X:
+ same => n,Set(OUTBOUND_GROUP=${GLOBAL(IMS_GROUP)})
+ ; Once a SIP UA answers the call, volte-ims-call-established takes care of updating IMS_PEER with the new PJSIP/50X channel name:
+ same => n,Dial(${DIALGROUP(CALL_EVERYONE_LIST)},,U(volte-ims-call-established))
+ ; Channel is removed from GROUP() automatically when it is destroyed after the call finishes.
same => n,Hangup(16)
- same => 999,Verbose(1,${EXTEN}: VoLTE client already busy (${GROUP_COUNT(IMSgroup)}) rejecting call from IMS ${CALLERID(num)})
+
+ ; Reject path:
+ same => 999,Verbose(1,${EXTEN}: VoLTE client already busy (${GROUP_COUNT(${GLOBAL(IMS_GROUP)})}, ${GLOBAL(IMS_PEER)}) rejecting call from IMS ${CALLERID(num)})
same => n,Set(DIALSTATUS=BUSY)
--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/37527?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: Idad9e613669466f3aac8b1c7b43f8d9b6e0494e6
Gerrit-Change-Number: 37527
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
jolly has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/37528?usp=email )
Change subject: Fix ASCI access burst detection with osmo-bts-trx
......................................................................
Fix ASCI access burst detection with osmo-bts-trx
The access burst detection must be enabled on channel activation, if the
handover is activated or if the channel is used for group / broadcast
call.
Related: OS#6467
Change-Id: I467a11662a580e33932ae142dcf605f4c0672daf
---
M src/osmo-bts-trx/l1_if.c
1 file changed, 16 insertions(+), 1 deletion(-)
Approvals:
pespin: Looks good to me, but someone else must approve
Jenkins Builder: Verified
fixeria: Looks good to me, approved
diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index 54f5bd2..13df7f7 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -472,7 +472,8 @@
lchan->tch.amr_mr.mode[2].mode,
lchan->tch.amr_mr.mode[3].mode,
amr_get_initial_mode(lchan),
- (lchan->ho.active == HANDOVER_ENABLED));
+ (lchan->ho.active == HANDOVER_ENABLED) ||
+ rsl_chan_rt_is_asci(lchan->rsl_chan_rt));
/* set lchan active */
lchan_set_state(lchan, LCHAN_S_ACTIVE);
/* set initial ciphering */
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/37528?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I467a11662a580e33932ae142dcf605f4c0672daf
Gerrit-Change-Number: 37528
Gerrit-PatchSet: 1
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
Attention is currently required from: fixeria, pespin.
jolly has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519?usp=email )
Change subject: Fix BTS_Tests_ASCI.TC_vbs_notification, add missing SI1
......................................................................
Patch Set 1:
(4 comments)
File bts/BTS_Tests.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519/comment/89a77f60_4f43…
PS1, Line 442: function f_rsl_bcch_fill_raw(RSL_IE_SysinfoType rsl_si_type, octetstring si_enc)
> this one can be friend.
Done
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519/comment/2a1ab912_d572…
PS1, Line 448: friend function f_rsl_bcch_fill(RSL_IE_SysinfoType rsl_si_type, template (value) SystemInformation si_dec)
> why is this changed?
I did not cleanup the patch before submitting.
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519/comment/2ec6b872_124f…
PS1, Line 4925: function f_TC_si_sched(float duration := 8.0) runs on test_CT {
> why is this changed?
I did not cleanup the patch before submitting.
File bts/BTS_Tests_ASCI.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519/comment/d9ba8313_f1d6…
PS1, Line 47: friend function f_init_nch_position() runs on test_CT {
> this one can be private.
Done
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I65dc55da78bc53a1265124e6b6f6bb9a1650206e
Gerrit-Change-Number: 37519
Gerrit-PatchSet: 1
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Thu, 18 Jul 2024 08:44:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: fixeria, jolly.
Hello Jenkins Builder, fixeria,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Code-Review-1 by fixeria, Verified+1 by Jenkins Builder
Change subject: Fix BTS_Tests_ASCI.TC_vbs_notification, add missing SI1
......................................................................
Fix BTS_Tests_ASCI.TC_vbs_notification, add missing SI1
Because System Information Type 1 was missing, the BTS could not assign
time slots to NCH. Without NCH, notification is not possible.
Related: OS#6467
Change-Id: I65dc55da78bc53a1265124e6b6f6bb9a1650206e
---
M bts/BTS_Tests.ttcn
M bts/BTS_Tests_ASCI.ttcn
2 files changed, 21 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/19/37519/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37519?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I65dc55da78bc53a1265124e6b6f6bb9a1650206e
Gerrit-Change-Number: 37519
Gerrit-PatchSet: 2
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: jolly <andreas(a)eversberg.eu>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset