| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
This way we clean the build of warnings completely and we can enable
-Werror but we still see this FIXME message while compiling.
Change-Id: I24c11226cd5bb5b6032f4ece7d1a0695dc82f0dd
|
|
|
|
|
|
|
| |
fixes
lapd/lapd_test.c:54:2: runtime error: null pointer passed as argument 2, which is declared to never be null
Change-Id: I7030729f4f4c867adecc7afc15bb5ca9beff0030
|
|
|
|
|
|
|
| |
If LAPDm receives an I-Frame while there already is an I-Frame in the
tx_queue the code generates an additional RR (to acknowledge the
received I-Frame). Instead, N(R) of the I-Frame in the tx_queue should
be updated to ACK the data.
|
|
|
|
| |
Regression test for LAPDm recording the current state
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently it takes 3s to establish a SAPI 3 SACCH connection with
osmo-bts. This is due to the fact, that a broken SABME request is
sent first and and is ignored by the MS. Then, after a T200 timeout
(2s) the SABME command is sent again (this time correctly) and
answered by the MS.
The first SABME message is broken (it has a length field of 3 and
ends with 3 bytes from the tail of the original RSL message),
because of it is expected throughout lapdm.c that msg buffers
containing RSL have msg->l2h == msg->data. Some abis input drivers
fulfill this but IPA doesn't, thus the 3 bytes of the IPA header
are still part of the msg and confuse length computation.
Since internal fields of the msg are modified directly, this is
difficult to see.
This patch adds a new function msgb_pull_to_l3() that explicitely
skips over all headers prepending L3 and therefore resets l1h and
l2h. This function is then used instead of msgb_pull_l2h() which
only worked correctly when msg->l2h == msg->data. In addition,
code manipulating msg->tail and msg->len directly has been replaced
by calls to msgb_trim().
Note that this patch does not fix all issues of this case in the LADP
related code.
Ticket: SYS#192
Sponsored-by: On-Waves ehf
|
|
|
|
|
|
|
| |
This just adds a single test to verify that the ACCH queue is
actually empty.
Sponsored-by: On-Waves ehf
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since e.g. the IPA input driver leaves it's specific header in front
of msg->l2h, so that msg->l2h != msg->data. The lapdm code does not expect this at least in
rslms_rx_rll_est_req().
This patch modifies the test program to add a dummy L1 header to
generated messages (unless the test would abort when doing so).
Note that the ok file reflects the current state which is not
correct.
Sponsored-by: On-Waves ehf
|
|
|
|
|
|
| |
This adds and uses a wrapper for lapdm_phsap_dequeue_prim() that
prints information about the message that has been taken from the
queue.
|
|
|
|
|
|
|
|
|
| |
This test case processes RSL establish requests for SMS (SAPI 3)
on the SDCCH and the SACCH channels. The TX queues are checked
after processing each message.
Ticket: SYS#192
Sponsored-by: On-Waves ehf
|
|
|
|
|
|
|
|
|
| |
I have a crash with an older libosmocore and the sysmobts. I
am not sure how we can have a release for a channel where the
lapdm_channel has not gone through lapdm_channel_init. But to
prevent the crash we can promise lapdm_channel_exit to be idempotent.
It has been idempotent since f5a079f739c57d8be7c59149fd45475c402a45fc
|
|
|
|
|
| |
For whatever reason two functions were present twice in the code,
probably some git merge/rebase artefact?
|
| |
|
|
|
|
|
| |
Update the OSMO_ASSERT to what it should be like but can't due a
known issue in the LAPDm code.
|
|
|
|
|
|
|
|
|
| |
The issue about the wrong padding has been found when creating the
testcase in commit 15f740caa3a1ef681b3a5564daf6dfccb7b1e489 but the
patch to fix that was never proposed by inclusion by its author.
The issue about about the establish confirm carrying data with
a wrong size is still present.
|
|
|
|
|
|
|
|
|
| |
After reception of SABM, the network responds with UA and enters the
establised multiframe state. If UA is not received by mobile, the SABM
is transmitted again, and the network must respond with UA again, unless
it is from a different mobile.
Add LAPDm collision test (contention resolution on network side).
|
|
|
|
|
| |
The tests should unconditionally assert, regardless of debug settings.
This uses the OSMO_ prefix as it's in the global namespace.
|
|
|
|
|
|
|
|
| |
lapd_test.c: In function ‘ms_to_bts_l1_cb’:
lapd_test.c:192:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable]
lapd_test.c:199:1: warning: no return statement in function returning non-void [-Wreturn-type]
lapd_test.c: In function ‘main’:
lapd_test.c:355:2: warning: implicit declaration of function ‘osmo_init_logging’ [-Wimplicit-function-declaration]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This was found while implementing handover on a sysmobts. When we
receive a channel release request for a channel that was never really
activated (set_lapdm_context() was not called) we segfault in
lapd_recv_dlsap().
We now return early with -EINVAL in rslms_rx_rll() if we receive a
message that assumes set_lapdm_context() was already called.
These are:
* RSL_MT_UNIT_DATA_REQ
* RSL_MT_DATA_REQ
* RSL_MT_SUSP_REQ
* RSL_MT_REL_REQ
A test case was added to trigger the issue.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of using a ./configure parameter to decide whehter to build
tests or not, use the check_PROGRAMS variable so that the tests are
only built when running `make check`.
To avoid slowing down the test phase itself, collapse the declaration
of the test targets in the tests/Makefile.am file, this way they can
be built and linked in parallel before the testsuite is executed.
Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
|
|
|
|
|
|
|
|
|
|
| |
This code should not play with the internals of the msgb like this,
this code got introduced in af48bed55607931307 and is breaking the
osmo-bts usecase of forwarding an RSL message.
Add a test case that fails without the new code. I would prefer if
we could get rid of the manipulating the msgb like this, it is prone
to errors like this one.
|
|
|
|
|
|
| |
DATA REQ with a msgb_l3len(msg) == 0 message does not make any
sense, log an error and return immediately before attempting to
send an empty I frame in lapd_send_i.
|
|
|
|
|
| |
I thought this number would be wrong in the same way but it depends
on OS/ARCH. Disable this part of the test for now.
|
|
|
|
| |
Verify the output, accept two known errors in the generation of it.
|
|
This is testing the establishment of two ends (BTS, MS) one is in
the polling mode as used by osmo-bts. Transfer data between the two
ends. The sent data is not verified though. This should be followed
up soon.
|