Commit Graph

14 Commits

Author SHA1 Message Date
Neels Hofmeyr 12dddab03d sdp
Change-Id: Id1b7dd406d5e8e9ae89c5f901a79e2b6135c5202
2024-02-25 03:49:31 +01:00
Neels Hofmeyr f5a7003d86 wip
Change-Id: I974a02ecf8f280177c0ad616a05bb2aabf0d54ff
2024-02-25 03:49:31 +01:00
Neels Hofmeyr 757f793a9a sdp
Change-Id: Ia0484192ba318ee712a9910f631c169060dfabd8
2024-02-25 03:49:31 +01:00
Neels Hofmeyr 189a262206 select remote's first codec
Change-Id: I21452edfce34ced393ebb83a5a8b2a746f78d9c6
2024-02-25 03:43:12 +01:00
Neels Hofmeyr dcb6ce71c2 make sdp_audio_codecs_select() safe for any codec
So far, the selected codec needs to be a member of the list. Instead,
make this API safe for any instance, member or not, by looking it up.

Remove the lookup from the only caller.
A subsequent patch adds another caller that would have needed a manual
lookup before calling sdp_audio_codecs_select().

Change-Id: Ic1b5ba46c6f4c58e518b080bcb9b5741cb70ccc3
2024-02-25 03:43:12 +01:00
Neels Hofmeyr 10d47901fd make default RAN codecs configurable in ran_infra
Instead of generating the default codecs list for a RAN for each call,
place a pre-composed list in ran_infra.c.

(1) The main aim is to allow configuring this list -- subsequent commit
Ib5655214ce48c66d095e8f1b7b7106ac3ee43ec0 will add the VTY commands to
modify the predefined lists.

(2) As a free side effect, this also allows configuring the order of
preference for specific codecs.

(3) It may also save us some iterations of the codec_map[], which may
grow a lot more variants; for example, we could add one entry for each
possible AMR mode-set...

Change-Id: If46231a53f7512dbd81790fd30462d65fe059aa3
2024-02-25 03:43:12 +01:00
Neels Hofmeyr 5a56df1db0 drop bogus support for AMR OFR and OHR variants
Looking at 3GPP TS 26.103 table 4.1, none of the AMR-Oxx variants are
supported by GERAN-GMSK nor UTRAN, so it makes no sense to include
these. There are no users of this.

Change-Id: I0cbc770fff55209676d9b6aae50011d6d5f897e2
2024-02-09 05:17:39 +01:00
Neels Hofmeyr d767c73a1f implement re-assignment to match codecs
This is the last missing piece that allows osmo-msc to make good TFO
codecs choices.

Since the codec_filter, osmo-msc properly gathers codec options and
limitations. But the MO call leg still assigns a voice channel before
getting a response from the MT call leg, and is then stuck with that.

Add the capability to adjust the MO call leg's codec in case the MT side
needs a different codec for TFO.

This is only relevant for 2G; on 3G we always have AMR/IuUP.

For inter-MSC handover, keep the behavior unchanged: offer only the
currently assigned codec to the remote side. Codec-changing HO should be
equally trivial to implement, but that is for another day.

msc_vlr_test_call's codec tests are adjusted to test the new feature in
Ib933554f826c1b4347dfa3f6c4f6fe086be8b133. For now, avoid change in
these tests by validating the first codec in SDP lists only.

Related: OS#6258
Related: osmo-ttcn3-hacks I402ed0523a2a87b83f29c5577b2c828102005d53
Change-Id: I8760feaa8598047369ef8c3ab2673013bac8ac8a
2023-12-13 01:52:22 +00:00
Oliver Smith c63c3a0cc5 transaction: move cc.codecs.result -> cc.local
Prepare for CSD where this will be used too.

Related: OS#4394
Change-Id: Iaf954be0455625faa06a64c19905b79b7045f8e4
2023-06-15 15:06:46 +02:00
Oliver Smith 593cd88535 transaction: move cc.codecs.remote -> cc.remote
Move remote out of codecs, as it will be used by CSD code as well.
Otherwise we would need to store it twice (in cc.codecs.remote and
cc.csd.remote).

Related: OS#4394
Change-Id: I5d2e078db3b3437cb6feae40d8955912d7a297e4
2023-06-15 15:06:46 +02:00
Oliver Smith a35abb761c codec_filter_init: prepare for CSD
Related: OS#4394
Change-Id: I1270b00464456abc5300fd47e6087a0ba6243d03
2023-06-15 15:06:46 +02:00
Oliver Smith 5375f78ebb codec_filter_set_ms_from_bc: prepare for CSD
In all the places where codec_filter_ functions get called, for CSD we
will need to filter the bearer services. Add a new
transaction_cc.c file for functions that either combine the
codec_filter_ function with logic for CSD and voice calls or just call
the existing codec_filter function and a new csd_filter function.

Start with moving codec_filter_set_ms_from_bc to this new file, it will
be extended with a case for CSD in a future patch.

Related: OS#4394
Change-Id: If225f2a299ce6bc9ae35a17d6f591d889f49155e
2023-06-15 14:25:24 +02:00
Vadim Yanitskiy 999a593efb copyright: fix typo: sysmocom s/s.m.f.c./s.f.m.c./ GmbH
Change-Id: I81687235fedcbbb686db7def59318e891e00ced7
2023-05-18 17:22:26 +07:00
Neels Hofmeyr 63881a3735 [codecs filter] add codec_filter.h,c
Add the infrastructure to store and filter all codec limitiations from
the different stages: MS, BSS, CN and remote call leg. Upcoming patches
will properly collect these and find an optimal codec.

No functional change, yet.

Related: SYS#5066
Change-Id: I4d90f7ca62f2307a7b93dd164aeecbf4bd98ff0a
2023-03-14 22:41:52 +00:00