Age | Commit message (Collapse) | Author | Files | Lines |
|
Add data structures and checks for System information Type 10.
Related: OS#5783
Change-Id: I3a5da543f083f31e873c67b5ec1b5a439187d8f3
|
|
Change-Id: I25f46bf3893bb68203414300587756cf2fdb04f7
|
|
Previous SI10 patch added function without exposing it via public header.
Let's fix this.
Fixes: 600d4eeab71665c0aec0a11a226d231f109534ca
Change-Id: Ia7530e9c8a21f6f99f3aac7baea5cbb38763c4f3
|
|
The data structre is held private so that it can be easily extended in
the future.
Change-Id: I6f8324da9ba49b9249682e2ec5b45297f18dd8c2
|
|
This module provides several operations on network devices
(interfaces), like monitoring changes, setting addresses, routes, link
state, etc.
It also supports managing network interfaces on several different netns
concurrently.
These functionalitites will be used by the tun module included in a
follow-up patch.
Change-Id: I7a00c0445a89e088676a4897061b65196d9197f1
|
|
Related: OS#5783
Change-Id: Ifbd0aabe826298fa4715eb4eb2ff8363e765933d
|
|
Related: OS#5783
Change-Id: I583a170070c192c6c47fae41ce923a7439561b4f
|
|
Write a new API and implementation to manage network namespace related
operations.
This will be used by the upcoming tundev module.
Change-Id: I0f2fba2fa42250a07211a7b7f479498f27c529da
|
|
There are some parts of libosmogsm which are not really GSM specific,
but rather ISDN bits that were inherited by GSM. This includes the
I.460 multiplex as well as the core LAPD protocol.
Let's move those bits to its own libosmoisdn library, before we add
more ISDN specific bits to the wrong place.
Backwards-compatibility is created by making libosmogsm depend on
libosmoisdn, and by providing wrapper include files for source
compatibility.
Change-Id: Ib1a6c762322fd5047be3188b1df22408ef06aa50
|
|
When someone is modifying a given library there's no need to be looking
at a common file contains tons of lines from different libraries.
Furthermore, this removes the need of "nobase" autofoo prefix, hence
following the usual directive of having one Makefile per directory.
Change-Id: I785891c2f89114bf8303c799094b637d3d25ac71
|
|
Implementation is imported from osmo-ggsn.git
97f60e3dca581797007524e0006ca9fafad59713 in46a_netmasklen() and adapter
to work with an osmo_sockaddr.
This will be used by osmocom-bb's "modem" app.
Change-Id: I75e75e251c6776801fffdde745aebedf21c68799
|
|
C/C++ only implements a so called "truncated modulo" function. Lets also
add a floored and an euclidian modulo function to be more complete.
The functions will be used to generalize the following Change:
I5fb2b0ada8d409730ac22963741fb4ab0026abdd
Change-Id: If61cd54f43643325c45f64531c57fe4c5802a9cf
|
|
Related: OS#5809
Change-Id: Ibd05d3bc2736256aa45e9e7ec15a98bd14a10454
|
|
Change-Id: Ide9110b984d3302aec6b439c563eb10e2dcdec9e
|
|
So far ctrl interface did not allow to specify port to bind to.
Let's fix this and make it consistent with the way vty bind works.
N. B: the functions which ignore port configured via vty are marked as deprecated,
the sw which uses them should be ported to either newly added ctrl_init_default()
or simplified ctrl_interface_setup()
The similar change for vty interface will be addressed via separate patch series.
Related: OS#5809
Change-Id: I0fd87fd41fd3ac975273968d24f477daa3cd3aa9
|
|
The problem with most of the existing gsm0808_* functions in this file
is that they assert() too much, assuming that their callers always pass
perfectly valid input parameters. But this is impossible on practice,
as there can be bugs in complex projects using them, liks osmo-bsc.
It was reported by a customer that a heavily loaded osmo-bsc crashed a
few times, dropping more than 100 sites without network coverage for
a few minutes. As was revealed during the investigaion, it crashed
due to a failing assert at the end of enc_speech_codec():
OSMO_ASSERT(sc->cfg == 0);
The problem is that somehow osmo-bsc is passing an unexpected sc->cfg
value to gsm0808_create_ass_compl2(), in particular 0x02, while the
given sc->type value (GSM0808_SCT_HR1) implies that there cannot be
any configuration bits on the wire.
The reason why and under which circumstances this can be happening
is not clear yet, but what we agreed on so far is that the library
API should be enforcing correctness of the input parameters in a
less agressive way, rather than aborting the process without
letting it any chance to recover.
Modify the original gsm0808_enc_speech_codec[_list]() functions, so
that a negative value is returned in case of an error. Rename them
and add backwards compatibility wrappers, because it's public API.
A separate patch making use of the new API follows next.
Change-Id: I199ffa0ba4a64813238519178155dfc767aa3975
Related: SYS#6229
|
|
We've started to encapsulate a varieth of ISDN related formats
as sub-types to GSMTAP_TYPE_E1T1 for quite some time. Let's add
some more formats, such as V5EF, V.110, V.120, X.75 and H.221
For the HDLC based V5EF, V.110, V.120 and X.75 the payload format is
clear. For V.110 and H.221 we will need to specify how the actual
payload looks like.
Change-Id: I8dee0f730cf91d6f9133d5c57f653e669ec8d598
|
|
Change-Id: Ib11bfe57f546a5618f70152b9b75115808e54bf6
|
|
It's handy for OsmoPCU as well as upcoming LAPD T200 code.
Related: OS#4074
Change-Id: I641f1a1bf1e86ced8ffe89e88bc48afb79823393
|
|
The newly-introdiced pragma to disable strict-prototypes checking works
in C, but creates a -Werror=pragmas error in C++ code:
In file included from osmo-trx.cpp:45:
/build/deps/install/stow/libosmocore/include/osmocom/vty/logging.h:10:32: error: option
‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [-Werror=pragmas]
#pragma GCC diagnostic ignored "-Wstrict-prototypes"
So let's also suppress those errors for that one line of code...
Change-Id: I85596cf4538d7a8c522f4bce1620a2d19e2a910e
|
|
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its
parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However,
its declaration in C file didn't contain "(void)", which meant the
number of parameters is undefined and thus compiler doesn't complain.
However, in recent Change-Id I84fd99442d0cc400fa562fa33623c142649230e2
we changed the declaration to '(void)' to allow building with
-Wstrict-prototypes. This caused downstream build-failures of osmo-mgw (1.4.0)
and osmo-e1-recorder (master).
So let's make one very small-scoped exception here.
Change-Id: Iadb54848b67db937b640dc2102dddb6e708a6a9f
|
|
Unfortunately "-std=c99" is not sufficient to make gcc ignore code that
uses constructs of earlier C standards, which were abandoned in C99.
See https://lwn.net/ml/fedora-devel/Y1kvF35WozzGBpc8@redhat.com/ for
some related discussion.
Change-Id: I84fd99442d0cc400fa562fa33623c142649230e2
|
|
Those are similar to existing *msgb_alloc*() functions but allows
to change the size of destination msgb provided it fits the
data from source msgb.
Change-Id: I36d4c16241d19f0f73c325be4d0e0bdef6813615
Signed-off-by: Max <msuraev@sysmocom.de>
|
|
Change-Id: I106b7586bfe8ee03c052b6f8b33da4c466e05abd
|
|
osmo-isdntap is a ISDN protocol + call tracing utility currently under
development, see https://gitea.osmocom.org/retronetworking/osmo-isdntap
Change-Id: I25ca4565e326ee9b0b32eeabc4a76756e2fde4ac
|
|
Change-Id: Ibecfcccd3eabd81979b2296a2dbca1ffbbec8f1c
|
|
The macro msgb_sms() is basically an alias for msgb_l4(). Lets use
msgb_l4() in msgb_l4len() instead of msgb_sms().
Change-Id: I90d4f5c07fbaadd9e022752a2c64c4855f0b4227
|
|
When any of l1h, l2h, l2h or l4h is set to NULL (which is the default
for newly allocated message buffers). Then the msgb_lXhlen() functions
will return the address value of msgb->tail. This can lead to unexpected
results at a later point. We should have an OSMO_ASSERT to catch the
problem early.
Change-Id: I1795c559f190713ebbabfbabf3453ab77da46a49
Related: OS#5645
|
|
Change-Id: I2810a889fc14052d0e0be6a2b500ad4e5088ffa9
|
|
Change-Id: Iab2ee2854be8027ee5978e06a83248b530a39bf7
|
|
This makes it possible to pass expressions to the abovementioned
macros without any side-effects. Strictly speaking, this is only
necessary for argument 'b' of GSM_TDMA_FN_SUB, but let's also add
them to GSM_TDMA_FN_SUM for consistency.
Change-Id: I7f26156813139bbb7774e1eb342c91bc84fdad38
|
|
Change-Id: Iecc1754caae401aca28444d3e3d0cca04b398f26
|
|
Change-Id: I76dc3b08a63cfd78c9f7657fb58c2ddfa9b4b7e2
|
|
Change-Id: I1864a6beeeedc301c6dc7e2e0c52a3f94b2fef01
|
|
While at it, drop 8-1 in favour of 7. I don't think it is really more
understandable for readers to see some subtraction there...
Change-Id: I8b21eba9b9aa952f86abe7a6d4cdb1d1a61d9deb
|
|
This reverts commit a4063efa7deb6632c228037c47effca22ad0f781.
Reason for revert: It is not possible to guess the IP address
family from uninitialized memory. This function simply glorifies
random noise into an IPv6 address. It makes no sense to have it.
Change-Id: Ifadd614604cf9d0c2ed1a405493c1c3fcb37ae23
|
|
This reverts commit e145e28a91eeca65d34d7b82caa2190fa89492b4.
Reason for revert:
The function osmo_sockaddr_strs_to_str() should not be part of the
osmo_sockaddr_str API. The implementation of this should live in
the function multiaddr_snprintf() added in patch
Icef53fe4b6e51563d97a1bc48001d67679b3b6e9
and should not use dynamic allocation.
Change-Id: I263dfd68313b896c5b474025fbca13c22ce41cdc
|
|
This will come in handy for working with multihomes sockets like SCTP.
Related: OS#5581
Change-Id: Ic0d7c08f669994e37a2314555ecac85d28c42c89
|
|
Sometimes we receive generic "struct sockaddr" with unspecified (AF_UNSPEC)
address family. It's handy to try to guess
the proper address (there're just 2 variants ATM in most practical applications).
Use the added function to relax input checks in osmo_sockaddr_str_from_in*()
Related: OS#5581
Change-Id: I1c90c56ce832f53b65e0d18d3cea94621c02a69a
|
|
This is similar to what we already do between BSC<->MSC to pass Osmux
CID (GSM0808_IE_OSMO_OSMUX_CID).
We now want to support Osmux between BSC and Osmocom BTS, hence add an
extension IE which will be used in ipaccess CRCX messages to tell the
BTS to use Osmux.
Change-Id: I580fe99c01bc0a844d877994ec6cd954310e265d
|
|
This feature is used by the BTS to signal to the BSC that it supports
using Osmux instead of RTP on the BTS<->BSC(MGW) data plane.
Related: SYS#5987
Change-Id: Ie79bfb6d0a7a8fe2842d2596b3244e7b74a0d5b6
|
|
I was warned by gcc about comparing a pointer with an integer when using
TLVP_PRESENT with something like:
bool expect = ...;
if (expect != TLV_PRESENT(...))
That's indeed dangerous because TLV_PRESENT is considered to return a
boolean, as opposite to TLV_VAL.
Change-Id: I45cc2745c695e30c37b10f592903ec3775a55492
|
|
Change-Id: Ief318882def539b35ef15c85566f69220e7edbfe
|
|
Change-Id: Iee52f38c1040b7f7ee37aaa58cfdb0cb6cf33f4d
|
|
This new category is going to be used by CSN.1 codec in libosmo-csn1.
Change-Id: Ie8c0effb764547a0f9cc8c6825e11a6617501e95
|
|
Change-Id: I98cde213deb5a3bf39eb9f5e5451f40223632844
|
|
Change-Id: I3a5bb9b2c77b8e4a984631d199fc073183691c31
|
|
Change-Id: I35592bb4fff2e7b442d0e0cd537b66687862baf2
|
|
The new functions accept an additional mode_id poiner, which is
currently set for the following frames: AFS_ONSET, AHS_ONSET,
AHS_SID_FIRST_P2 with N * 16 - M bit pattern.
Also, the new API accepts soft-bits instead of hard-bits.
Converting bits from soft to hard is now performed internally.
Change-Id: Ibcac395f800bb64150c97fcdaca3523ecfc5fcee
Related: OS#5570
|
|
Change-Id: I10a2d2a872fd6fdae8b4af94995300af3144b551
|