| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
The debug output of lapd core has no references to the dl objects,
since we have multiple links, seeing which action is for which
object is impossible. This commit adds pointer references (dl=%p)
to each log line.
Change-Id: I3024d1cbd58631e2abac4ce5822528e2e6e15fda
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
GSUP transmits AUTS for UMTS authentication procedures, and OAP uses the same
procedures to authenticate. osmo-gen-vec is a utility program that passes AUTS
to our osmo_auth_gen_vec_auts() API.
According to 3GPP 33.102 6.3.3, AUTS = SQN^AK || MAC-S, which are 6 || 8 == 14
bytes. This is confirmed by 24.008 9.2.3a where the TLV has 16 bytes, TL = 2
and AUTS being the V = 14.
It is not harmful for milenage_gen_vec_auts() to pass two more AUTS bytes. But
writing 16 bytes to a GSUP struct is a potential problem when passing in a 14
byte long AUTS buffer to the GSUP API, which then reads past the AUTS buffer.
The API implies the length, so far to be 16, so passing in a 14 byte buffer to
GSUP would require copying to a larger buffer first.
Fix this by using a length of 14 for AUTS everywhere instead.
This constitues an ABI breakage, we may handle it as a "fix before an official
release", otherwise we need a version bump.
The OAP protocol document has also been updated, needs an update in the
osmo-gsm-manuals as well.
Change-Id: If25b173d9ec57ea4c504d860954912b7d82af455
|
|
|
|
|
|
|
| |
Using this function, one can obtain a human-readable string identifying
the host and port names of the socket.
Change-Id: Ib5de5c7b9effe1b0a363e4473a7be7fa38ca6ef3
|
|
|
|
|
|
|
| |
Add special cause for alerts produced by external processes.
Change-Id: Idd7ee085321f8172c72ecfdba320186049f4d988
Related: OS#1615
|
|
|
|
|
|
|
|
|
|
|
|
| |
A DSO should link to the libraries that it is using. Linking to
libtalloc will resolve these warnings:
Change-Id: I4c8d5e80e194b9d9b4fa2424c4a22377ecee9c7a
dpkg-shlibdeps: warning: symbol _talloc_zero used by debian/libosmosim0/usr/lib/i386-linux-gnu/libosmosim.so.0.0.0 found in none of the libraries
dpkg-shlibdeps: warning: symbol _talloc_free used by debian/libosmosim0/usr/lib/i386-linux-gnu/libosmosim.so.0.0.0 found in none of the libraries
dpkg-shlibdeps: warning: symbol talloc_strndup used by debian/libosmosim0/usr/lib/i386-linux-gnu/libosmosim.so.0.0.0 found in none of the libraries
dpkg-shlibdeps: warning: symbol talloc_strdup used by debian/libosmosim0/usr/lib/i386-linux-gnu/libosmosim.so.0.0.0 found in none of the libraries
dpkg-shlibdeps: warning: symbol _talloc_memdup used by debian/libosmosim0/usr/lib/i386-linux-gnu/libosmosim.so.0.0.0 found in none of the libraries
|
|
|
|
| |
Change-Id: I69f2891a2bea6f87f079b6778aa01ee27a25001b
|
|
|
|
|
|
|
| |
We don't have file-based I/O nor ethernet devices with mac addresses
when building for OsmocomBB.
Change-Id: I01a9e6d8dbe885dbeac2769b84931a4d44f7a3a5
|
|
|
|
| |
Change-Id: If56b521429af497ddd5a47170eb2c085b1fb78ba
|
|
|
|
|
|
|
| |
osmo_strlcpy() was excluded from the group because the closing brace was above
it.
Change-Id: I6701261f5854342ac4cd4f2da62e49eb40362938
|
|
|
|
|
| |
Change-Id: I71413fbe703e459782a235e5b1d8487265de3780
Related: OS#1615
|
|
|
|
|
|
|
| |
Mark abis_nm_debugp_foh() function superseded by macro with the same
name as deprecated.
Change-Id: I2d3ea2b56aff6b687f72f832360b8cb8a24164e9
|
|
|
|
|
|
|
| |
Stating that it 'truncates src' is misleading. Also clarify whether siz
includes the space needed for the terminating NUL.
Change-Id: I01c1a94408b471f7f54576178a60938bf9ee3261
|
|
|
|
|
|
| |
In EMBEDDED builds we don't have a system-wide talloc
Change-Id: Icc526016bda45b36e584afee8669996752d6d89c
|
|
|
|
|
|
|
|
| |
Using --disable-ctrl, one can disable the building of libosmoctrl.
The 'embedded' target will also automaticall disable ctrl.
Change-Id: I6912396338c5b23ae860fef2a55854d6df9a579d
|
|
|
|
|
|
| |
oap_test.c
Change-Id: Id524327b3f44e22e3aa44c5e8e4965b084cb326a
|
|
|
|
|
|
|
|
| |
The TbfTest in osmo-pcu calls gprs_ns_vty_init() repeatedly, which aborts
because of duplicate VTY elements. Fix this by skipping the VTY init if
it already happened.
Change-Id: I05c7f25a4e873ae76b206819180b8b043b60103e
|
|
|
|
|
|
|
|
|
| |
It accept fixed number of arguments including va_list instead of variable
number of arguments in abis_nm_fail_evt_rep() - similar to vprintff() vs
printf().
Related: OS#1615
Change-Id: Ib293dec1c2de9b664584a8456c782ea7b6dd8555
|
|
|
|
|
|
| |
Log error cause and state names in case of SABM errors.
Change-Id: I2c7fa276e03f8b14ba41cc1fb6e19d0aae77d127
|
|
|
|
|
|
|
| |
Max's note: adjusted test output.
Change-Id: I46477c631bf86345cb757f31d7f2e2935b12adcc
Related: OS#1801
|
|
|
|
|
|
|
|
| |
Add string representation of Probable Cause Type from 3GPP TS 12.21 §
9.4.43.
Change-Id: I9fe14ed3b5398f59dd06a509e4d419e074cc20a7
Related: OS#1615
|
|
|
|
| |
Change-Id: I89212e4f149f019099115a85bab353c04170df90
|
|
|
|
|
|
|
| |
This addresses a FIXME in the fsm.c code: osmo_fsm_register() should
fail in case a FSM with the given name already exists.
Change-Id: I5fd882939859c79581eba70c14cbafd64560b583
|
|
|
|
|
|
|
|
|
| |
When the caller installs two identical commands at a given VTY node, the
result is that neither of the two commands can ever be executed: The VTY
would always complain about "Ambiguous command.". Let's fail fast at
program start when two identical commands are intalled.
Change-Id: I85ff4640ebb3d8b75a6a9ab5d2f668edb5b7189e
|
|
|
|
|
|
|
|
| |
Add 3GPP TS 12.21 § 8.8.2 Failure Event Report function which pack given
vararg string and parameters into msgb.
Change-Id: I58c198d8ea588432c62520928b08f0b2a7035e93
Related: OS#1615
|
|
|
|
|
|
|
|
| |
Add human-readable descriptions to event causes from 3GPP TS 12.21 §
9.4.43.
Change-Id: Id173c978616c98b7831fbafb5401064257f1cf73
Related: OS#1615
|
|
|
|
|
|
|
|
|
| |
Function bitvec_rl_curbit added to get number of uninterrupted
bits run in vector starting from the current bit till max number
of bits.
Test case is added to check bitvec_rl_curbit.
Change-Id: Iae153d3639ea6b891c1fc10d7801a435c9492e26
|
|
|
|
|
|
| |
Add functions to copy and merge parsed TLV structures from OsmoBTS.
Change-Id: Ieaaaed19da9c069fe451faa53d24c5b84d7d5615
|
|
|
|
|
| |
Change-Id: I9c3bc15662949654e7bba6aad5488c69ee7d0c45
Related: OS#1615
|
|
|
|
|
|
|
|
| |
Drop perror() calls from GSMTAP code: it's application job to do the
proper logging - library code should not write to stdout/stderr
directly.
Change-Id: Ifa149e65d76c6e64fda2946725c16672233aff2e
|
|
|
|
|
|
|
| |
This resolves
gprs_cipher_core.c:118:37: runtime error: left shift of 1 by 31 places cannot be represented in type 'int'
Change-Id: Ib1866595030ad9d11c886621ce69632462befa3a
|
|
|
|
|
|
|
|
|
|
|
|
| |
During FSM instance termination, fetch the parent pointer every time just
before using it, in case the child termination or cleanup callback wish to
change anything about the parent, e.g. to prevent event dispatch.
This patch was created to try and fix a problem that was in the end solved
differently. There is no actual need or use case for this at the moment, but it
generally makes sense to get the parent pointer as late as possible.
Change-Id: I999d7f29ba10281d4005c5163130bb2d80148362
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
osmo_fsm_inst_term() has code for safe child removal, publish that part as
osmo_fsm_inst_term_children(); also use from osmo_fsm_inst_term().
As with osmo_fsm_inst_term(), add osmo_fsm_inst_term_children() macro to pass
the caller's source file and line to new _osmo_fsm_inst_term_children().
Rationale: in openbsc's VLR, I want to discard child FSMs when certain events
are handled. I could keep a pointer to each one, or simply iterate all
children, making the code a lot simpler in some places.
(Unfortunately, the patch may be displayed subobtimally. This really only moves
the children-loop to a new function, replaces it with a call to
_osmo_fsm_inst_term_children(fi, OSMO_FSM_TERM_PARENT, NULL, file, line) and
drops two local iterator variables. No other code changes are made, even though
the diff may show large removal + addition chunks)
Change-Id: I8dac1206259cbd251660f793ad023aaa1dc705a2
|
|
|
|
|
|
|
|
|
|
|
| |
LOGPFSM and LOGPFSML are in the header file, put the *SRC variants also there
so users of the osmo_fsm_inst API may conveniently create own functions that
log the caller's source file and line.
Very useful if many action functions call the same event dispatching function,
like foo_fsm_done(), and one needs to know which of the callers to debug.
Change-Id: I39447b1d15237b28f88d8c5f08d82c764679dc80
|
|
|
|
| |
Change-Id: I1970773440865f1415004bcf0164603468acf90b
|
|
|
|
| |
Change-Id: I6af0d43ab0082e45df676c1d69b26310b59a8031
|
|
|
|
|
|
|
| |
if stdin/stdout/stderr are all closed by our environment, it may very
well be that opening a serial port returns fd == 0.
Change-Id: Ifd9670260883a35da0629369e0d49e467d5b4d72
|
|
|
|
|
| |
Change-Id: I14f934957e1086b803f3a7b9b5e6d602380f0be2
Fixes: Coverity CID 158987
|
|
|
|
|
|
| |
So let's ignore the error we might get from this opreration.
Change-Id: I69dad90403355b6512c3bf4c7fd10dd1dd985f01
|
|
|
|
|
|
|
|
| |
There are some serial ports that apparently block during the open in
some circumstances. We don't want that. We want to either open it
immediately, or fail fast.
Change-Id: I626b138574bc50f4f4b09c4d609f3623ff512dff
|
|
|
|
|
|
| |
Use the implementation from Linux lib/crc-ccitt.c (GPLv2)
Change-Id: I26bb54038f5ab36bbb34da7f5fb8ae6c0c0386a4
|
|
|
|
|
|
|
| |
libosmocore itself is GPLv2-or-later. Only the test cases are permitted
to be AGPL licensed.
Change-Id: I62f2eed6305bfa11a64c6d633e08aabeaf9f0b10
|
|
|
|
|
|
|
|
| |
Logging 'Release' is a bit ambiguous. At first I tought a subscriber
connection was being released, IMHO 'Freeing instance' better describes that
we are freeing an osmo_fsm_inst.
Change-Id: I5cf99707d2ba5620b2988f777fa39cc806ec0212
|
|
|
|
| |
Change-Id: Ifc2b499792fda378c807c678b8e06630cb64d273
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
OSMO_STRINGIFY particularly allows putting port numbers from a #define into VTY
doc strings, like:
#define FOO_PORT 2342
DEFUN(...,
"Foo UDP port (default: " OSMO_STRINGIFY(FOO_PORT) ")\n")
OSMO_VALUE_STRING creates value_string items with the string being exactly the
enum value's name. Replaces a similar macro def in fsm.c
Change-Id: I857af45ae602bb9a647ba26cf8b0d1b23403b54c
|
|
|
|
|
|
|
|
|
|
|
|
| |
* update debian/changelog
* update TODO-RELEASE
* add comments to Makefile.am and TODO-RELEASE to simplify the process
in future
* add link to libtool docs to Makefile.am to simplify LIBVERSION
maintenance
Related: OS#1861
Change-Id: I22c257e357f597519120232d742d6a61289db021
|
|
|
|
|
|
|
|
|
|
|
|
| |
When terminating child FSMs, restart iteration after every child, to make
sure that we don't terminate a child twice. Terminating one child may emit
events that in turn terminates other children.
I created this patch because at first it looked like the cause of a bug,
which turned out not to be the case. So I have no actual use case of this
situation, but it does generally make sense to me, so submitting this.
Change-Id: I00990b47e42eeb43707a9a42abcd9df52fe5f483
|
|
|
|
|
|
|
|
|
|
|
| |
Since removing an FSM from its parent twice causes a segfault, it is very
interesting to see when that is attempted.
Removing could be made more robust, but logging is interesting for
investigating why an FSM is being removed twice in the first place (currently
the case in openbsc's vlr_lu_fsm).
Change-Id: Idec6b7aa5344f1e903c9d2aa2a3640cab0d70fb0
|
|
|
|
| |
Change-Id: Iaf63d3cadb0d46bf454e3314ebb439240cafd834
|
|
|
|
| |
Change-Id: I6f683ed0c864a87bf1232994eb2deaf9b313a244
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When looking at log output, it is not interesting to see that a state
transition's petty details are implemented in fsm.c. Rather log the *caller's*
source file and line that caused an event, state change and cascading events.
To that end, introduce LOGPSRC() absorbing the guts of LOGP(), to be able to
explicitly pass the source file and line information.
Prepend an underscore to the function names of osmo_fsm_inst_state_chg(),
osmo_fsm_inst_dispatch() and osmo_fsm_inst_term(), and add file and line
arguments to them. Provide the previous names as macros that insert the
caller's __BASE_FILE__ and __LINE__ constants for the new arguments. Hence no
calling code needs to be changed.
In fsm.c, add LOGPFSMSRC to call LOGPSRC, and add LOGPFSMLSRC, and use them in
above _osmo_fsm_inst_* functions.
In addition, in _osmo_fsm_inst_term(), pass the caller's source file and line
on to nested event dispatches, so showing where a cascade originated from.
Change-Id: Iae72aba7bbf99e19dd584ccabea5867210650dcd
|