Attention is currently required from: laforge, pespin.
fixeria has posted comments on this change by fixeria. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email )
Change subject: library: add generic Mutex API for parallel components
......................................................................
Patch Set 2:
(1 comment)
File library/Mutex.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206/comment/156e3a1b_8b52… :
PS2, Line 19: port MutexPT LOCK; /* port for LOCKing the mutex */
> Ah ok so you are using the port queue based on the the sender to decide/filter whether to operate/wait for the lock operator.
Exactly. I am additionally including a Mutex reference in each message, which for now is used to make sure that a wrong component cannot unlock the Mutex that was locked by another component. This is not really needed, since we can just remember component reference of the Mutex locker. But we may develop this idea further, enabling components to have more than one Mutex identified by a reference.
> I'd have done that with 1 port and then maintaining a queue of vc_conn lock operations internally in the component, but fine your way too then.
Can you explain your idea a bit more? Not that I am planning to rewrite and debug this again, since it's already a lot of effort spent on trying to scale existing TCs rather than writing new ones. It's just my curiosity.
> Ah no erase what I said above. The mutex you are implementing here is no reentrant. If a component calls LOCK operation twice, it will deadlock/timeout.
Yes, the component will fail and terminate due to timeout. But why would you want to lock the Mutex twice? Is this a normal scenario? I could fix this by adding a boolean flag to the `MutexCT`, so that `f_Mutex_lock()` would set it and then return immediately if it's already set. Or fail immediately, if we consider this abnormal.
> By implementing it they way I mention you then get a reentrant Mutex.
> But I guess your implementation is good enough for what we need here for now.
As I said, I am interested to hear/see what other options we have here and generally open for improvements. But for now this is a poor-man's Mutex that does its job, so I am happy with it.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Id71f43bd5fc78d4bb4417d6c01fcff8112ea6032
Gerrit-Change-Number: 38206
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 20 Sep 2024 13:58:15 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
laforge has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/38229?usp=email )
Change subject: iuup.c: Add more relevant spec references to the file
......................................................................
iuup.c: Add more relevant spec references to the file
Those are specs which are usually of interested for somebody opening the
iuup.c and iuup.h files in order to work on Tx/Rx/forward of IuUP frames
eg. on top of RTP.
Change-Id: I0cf70e84def2162c3c8621cdbbd8632b25276d70
---
M src/gsm/iuup.c
1 file changed, 5 insertions(+), 1 deletion(-)
Approvals:
Jenkins Builder: Verified
laforge: Looks good to me, approved
diff --git a/src/gsm/iuup.c b/src/gsm/iuup.c
index 16a6f5e..4991213 100644
--- a/src/gsm/iuup.c
+++ b/src/gsm/iuup.c
@@ -1,5 +1,9 @@
/*! \file iu_up.c
- * IuUP (Iu User Plane) according to 3GPP TS 25.415 */
+ * IuUP (Iu User Plane) according to 3GPP TS 25.415
+ * See also 3GPP TS 25.414 regarding data transport.
+ * See also 3GPP TS 29.414 and 3GPP TS 29.415 regarding Nb counterparts
+ * of the above specs.
+ */
/*
* (C) 2017 by Harald Welte <laforge(a)gnumonks.org>
*
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/38229?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I0cf70e84def2162c3c8621cdbbd8632b25276d70
Gerrit-Change-Number: 38229
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Attention is currently required from: pespin.
laforge has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/libosmocore/+/38229?usp=email )
Change subject: iuup.c: Add more relevant spec references to the file
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/38229?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I0cf70e84def2162c3c8621cdbbd8632b25276d70
Gerrit-Change-Number: 38229
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 20 Sep 2024 13:50:15 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/38231?usp=email )
Change subject: pySim-shell: recognize ADP pins longer than 8 digits as hexadecimal
......................................................................
pySim-shell: recognize ADP pins longer than 8 digits as hexadecimal
When a hexadecimal formatted ADM pin is retrieved via the
card_key_provider, it still requires the --pin-is-hex parameter so
that sanitize_pin_adm knows the correct format.
This unfortunately ruins the card_key_provider feature for all cards
that use hexadecimal pins, because the --pin-is-hex would also be
required in scripts, which makes a script either useable for cards
with hexadecimal ADM or for for cards with ASCII ADM.
To minimize the problem, let's recognize all ADM pins longer than 8
digits as hexadecimal in case --pin-is-hex is not set.
Related: OS#4348
Change-Id: Iad9398365d448946c499ce89e3cfb2c3af5d525e
---
M pySim-shell.py
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/31/38231/1
diff --git a/pySim-shell.py b/pySim-shell.py
index d3f0d87..8c260aa 100755
--- a/pySim-shell.py
+++ b/pySim-shell.py
@@ -819,7 +819,7 @@
adm_type = opts.adm_type or 'ADM1'
# try to find an ADM-PIN if none is specified
result = card_key_provider_get_field(adm_type, key='ICCID', value=iccid)
- if opts.pin_is_hex:
+ if opts.pin_is_hex or (result and len(result) > 8):
pin_adm = sanitize_pin_adm(None, result)
else:
pin_adm = sanitize_pin_adm(result)
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/38231?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: Iad9398365d448946c499ce89e3cfb2c3af5d525e
Gerrit-Change-Number: 38231
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Attention is currently required from: fixeria, laforge.
fixeria has posted comments on this change by fixeria. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email )
Change subject: library: add generic Mutex API for parallel components
......................................................................
Patch Set 2:
(1 comment)
Commit Message:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206/comment/99af334a_6ece… :
PS2, Line 14: and there
: is no way for the PFCPEM to correlate which session belongs to which eNB.
> are we 100% sure this is the case?
I could not find an obvious solution that would help with identifying PFCP sessions unambiguously on the wire, so I came up with this Mutex based solution (next patches in this patchset).
> Can we not somehow make osmo-s1gw include some kind of IE that allows us to correlate which UE (Iu context, whatever) has caused that PFCP request?
In theory, the S1GW could include a tuple of `{MME-UE-S1AP-ID, ENB-UE-S1AP-ID, e-RAB-ID}`, which would uniquely identify each PFCP session, even at the establishment phase. I was considering this at the beginning and the question I had is **what kind of IE**? I could not find suitable PFCP IEs for that and I was not sure if adding Osmocom specific IEs to simplify the job for the testsuite is worth it.
> This would not only be useful here in the TTCN3 tests, but also any later debugging. Would be great if a PFCP message could be associated with the Iu connection when looking at traces in wireshark etc.
>
> If we cannot find a good PFCP IE to include such identity information in, 3GPP TS 29.244 Section 5.9 states we may add vendor-specific IEs anywhere and any implementation not understanding them shall just ignore them: [...]
While I agree that it would also be useful for debugging, I've already put a significant effort into getting this implemented, debugged, and finally working. I hope we can get this merged for now and consider adding Osmocom specific IEs as a further improvement? Also, we should probably move this discussion to the respective patch and make this one WIP for now.
> In terms of 3GPP standard IEs, we could include the IMSI of the UE in the "User ID" IE (29.244 Section 8.2.101) for the PFCP session establish request. This would at least allow us to support "one concurrent session establishment per UE". That should be fine for your current use case?
IMSI is not easily accessible for the S1GW, since it's usually part of the inner NAS PDUs. Digging into NAS in the S1GW (and likely having to keep some context around) sounds like an overkill to me. Some S1AP PDUs, like the `INITIAL CONTEXT SETUP` carry masked IMEISV (not IMSI), which is optional and unlikely can be considered a unique identifier, since it's the serial number part that is being masked.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Id71f43bd5fc78d4bb4417d6c01fcff8112ea6032
Gerrit-Change-Number: 38206
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 20 Sep 2024 13:45:40 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Attention is currently required from: fixeria.
pespin has posted comments on this change by fixeria. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email )
Change subject: library: add generic Mutex API for parallel components
......................................................................
Patch Set 2:
(1 comment)
File library/Mutex.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206/comment/83343dd3_1683… :
PS2, Line 19: port MutexPT LOCK; /* port for LOCKing the mutex */
> Ah ok so you are using the port queue based on the the sender to decide/filter whether to operate/wa […]
Ah no erase what I said above. The mutex you are implementing here is no reentrant.
If a component calls LOCK operation twice, it will deadlock/timeout.
By implementing it they way I mention you then get a reentrant Mutex.
But I guess your implementation is good enough for what we need here for now.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38206?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Id71f43bd5fc78d4bb4417d6c01fcff8112ea6032
Gerrit-Change-Number: 38206
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 20 Sep 2024 13:41:25 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>