Attention is currently required from: falconia.
pespin has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email )
Change subject: bring twjit into libosmo-netif
......................................................................
Patch Set 5:
(1 comment)
File src/twjit.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/39280/comment/ca883c9f_1e2fa7d… :
PS2, Line 504: rtph = osmo_rtp_get_hdr(msg);
> this smooth packet flow will be delivered to the fixed timing application perfectly in order, without any disruptions - and I argue that this behavior is the best
In here you are assuming that with an M bit set and no gap in the timestamp sequence means the data just be placed in sequence, which doesn't need to be necessarily the case. IMHO it makes more sense to apply handover since the newer flow after the M bit is the current one, which should take precedence over the old one. Otherwise it's like keep playing soft noise or music while there's already talk waiting to be played.
> With my current algorithm, the duration of the gap delivered to the fixed timing application will be exactly what the RTP sender indicated in its timestamps
No, it won't, because iiuc, due to the M bit, the timestamps before and after it are non-related. The fact that they may have some gap or not may be totally circumstantial.
So to me you are treating the case where the new supposedly randomly taken tiemstamp (due to M bit) is in the 160-sequence different than the other 159 cases.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: Ia3be5834571ca18b68939abbcf1ce3a879156658
Gerrit-Change-Number: 39280
Gerrit-PatchSet: 5
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: jolly <andreas(a)eversberg.eu>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: falconia <falcon(a)freecalypso.org>
Gerrit-Comment-Date: Tue, 19 Aug 2025 14:17:47 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: falconia <falcon(a)freecalypso.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: falconia, pespin.
jolly has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email )
Change subject: bring twjit into libosmo-netif
......................................................................
Patch Set 5:
(1 comment)
File src/twjit.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/39280/comment/489ebdbb_3dbbe7b… :
PS5, Line 486: msgb_free(new_msg);
Is there a twjit instance for every payload type or one for the complete RTP connection?
telephone-event payload may (and will) have equal timestamps as the audio payload.
There are codecs that split frames over several RTP packets. The sequence number increases, but the timestamp does not. (video codecs)
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: Ia3be5834571ca18b68939abbcf1ce3a879156658
Gerrit-Change-Number: 39280
Gerrit-PatchSet: 5
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: jolly <andreas(a)eversberg.eu>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: falconia <falcon(a)freecalypso.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 19 Aug 2025 13:56:26 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Attention is currently required from: pespin.
falconia has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email )
Change subject: bring twjit into libosmo-netif
......................................................................
Patch Set 5:
(1 comment)
File src/twjit.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/39280/comment/62e74621_c69d26c… :
PS2, Line 504: rtph = osmo_rtp_get_hdr(msg);
> Thanks. After having read your document: […]
I still disagree. To see why, let us consider a scenario in which you (presumably) believe checking M bit would make a difference. This purported scenario would have to have these two properties:
* SSRC stays the same, or else twjit would consider it a handover;
* All timestamp increments are integral multiples of 160, for the same reason;
* Sequence number does not matter at all, as twjit does not look at it except for staff-oriented counters and RTCP-mandated analytics - it does not affect any of twjit's actual decisions.
With the above prerequisites established, the next question is: gap or no gap? Consider the no-gap case first: there is a perfectly smooth, uninterrupted flow of RTP packets, but one of them has M bit set. With current code, this smooth packet flow will be delivered to the fixed timing application perfectly in order, without any disruptions - and I argue that this behavior is the best. Your proposal of treating M bit as handover would cause twjit state transition to HANDOVER, which would result either in some packets before the handover event being dropped if the new flow becomes ready (flow start criteria) soon enough, or in a gap (not present in the incoming stream) being fed to the output if the old flow underruns before the new one is ready. How would such behavior be any better than what I have currently?
Now consider M bit preceded by a gap: some packets omitted, then an RTP packet with M bit set. Here the question becomes: underrun or no underrun? If the gap is long enough for twjit to experience an underrun before the flow resumes, then it makes no difference whether the flow-resuming packet has M bit set or not: twjit is starting from EMPTY state in this case. Now consider the no-underrun case: the configured buffer depth is high enough, and the gap short enough, to where the flow-resuming packet arrives before the buffer underruns. With my current algorithm, the duration of the gap delivered to the fixed timing application will be exactly what the RTP sender indicated in its timestamps; with your proposed modification, the gap would be unpredictably lengthened or shortened based on how long it takes for the post-handover flow to reach ready state. How is your way any better?
In summary, I still fail to see *even one* scenario in which your proposed modification to my core algorithm would make an improvement.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/39280?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: Ia3be5834571ca18b68939abbcf1ce3a879156658
Gerrit-Change-Number: 39280
Gerrit-PatchSet: 5
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 18 Aug 2025 17:58:50 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: falconia <falcon(a)freecalypso.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: falconia.
pespin has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-netif/+/39281?usp=email )
Change subject: bring twrtp into libosmo-netif
......................................................................
Patch Set 5:
(1 comment)
File src/twrtp_base.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/39281/comment/0915c024_0707acd… :
PS1, Line 132: * another variant of this API with that alternative behavior.
> I see what you are asking for now. […]
ack, I think we are aligned with what I mean now :)
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/39281?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: Ib63215aaf13ef8ab8f2e0c8d310164cd5c8824eb
Gerrit-Change-Number: 39281
Gerrit-PatchSet: 5
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: falconia <falcon(a)freecalypso.org>
Gerrit-Comment-Date: Mon, 18 Aug 2025 16:55:56 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: falconia <falcon(a)freecalypso.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: pespin.
falconia has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-netif/+/39281?usp=email )
Change subject: bring twrtp into libosmo-netif
......................................................................
Patch Set 5:
(1 comment)
File src/twrtp_base.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/39281/comment/4d6e95a1_8c237d4… :
PS1, Line 132: * another variant of this API with that alternative behavior.
> See 3GPP TS 25.414 clause 5.1.3.4. RTCP is optional in IuUP. […]
I see what you are asking for now. In order to make it consistent, we would need to not only allow absent `rtcp_fd` in the low-level API `osmo_twrtp_supply_fds()`, but also add a Boolean argument to the higher-level API `osmo_twrtp_bind_local()`, enabling or disabling creation and binding of RTCP socket. Before I implement it in the next patch iteration, please confirm that this is what you want.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/39281?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: Ib63215aaf13ef8ab8f2e0c8d310164cd5c8824eb
Gerrit-Change-Number: 39281
Gerrit-PatchSet: 5
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 18 Aug 2025 16:44:56 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: falconia <falcon(a)freecalypso.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>