Age | Commit message (Collapse) | Author | Files | Lines |
|
This patch doesn't really tests whether osmo-pcu can work on a multi-bts
environment, but it prepares the data structures to be able to do so at
any later point in time.
Change-Id: I6b10913f46c19d438c4e250a436a7446694b725a
|
|
In get_paging_mi(), before this, an encoded buffer of Mobile Identity bytes is
returned. Code paths following this repeatedly decode the Mobile Identity
bytes, e.g. for logging. Also, in get_paging_mi(), since the TMSI is read in
from a different encoding than a typical Mobile Identity IE, the TMSI was
manually encoded into a typical Mobile Identity IE. This is essentially a code
dup of osmo_mobile_identity_encode(). Stop this madness.
Instead, in get_paging_mi(), return a decoded struct osmo_mobile_identity. Code
paths after this use the struct osmo_mobile_identity directly without repeated
decoding.
At the point of finally needing an encoded Mobile Identity IE (in
Encoding::write_paging_request()), do a proper osmo_mobile_identity_encode().
Since this may return errors, add an rc check for the caller of
write_paging_request(), gprs_rlcmac_paging_request().
A side effect is stricter validation of the Mobile Identity passing through the
Paging code path. Before, invalid MI might have passed through unnoticed.
Change-Id: Iad845acb0096b75dc453105c9c16b2252879b4ca
|
|
Note: subsequent patch Iad845acb0096b75dc453105c9c16b2252879b4ca will change to
passing a struct osmo_mobile_identity in the Paging code path, instead of
passing the encoded IE data.
Change-Id: Ibb03b8e601160427944f434761ca59811d1fc12f
|
|
P-TMSI is optional IE, but IE is mandatory and hence always available.
Since the encoding is actually a Mobile Identity, the IMSI is used in
case P-TMSI is not available.
Change-Id: I4dbf8db04e81f98352a42ce34a5d91326be9bfd1
|
|
Change-Id: Id0663a81f439f2d0b893b0d34f85a6db1927ef8e
|
|
Change-Id: I0515b5c8f6744fa501de88fa7808b7fc91981f0e
|
|
Recent commit added an assertion to check for buffer boundaries and it
actually gets hit.
One of the 2 code paths calling pcu_l1if_tx_pch() was passing a buffer
of 23 bytes while one of maximum 22 is expected (because plen is not set
in the buffer but set inside pcu_l1if_tx_pch()).
So it seems before the assert, that code path was actually writing 1
byte outside the boundaries of data buffer, since bitvec_pack() uses
data_len field of bitvec.
Related: OS#4228
Fixes: 8dc09e73d0b361b27232526ebcd5f25cd8c7edfd
Change-Id: I84c5dfd4d5580e9d4c00ed21887cb51bd9abbd2e
|
|
Receive an Application Information Request from the BTS via PCU
interface. Construct a Packet Application Information message from it
(3GPP TS 44.060 11.2.47) and send it to all MS with active TBF.
The TTCN-3 test infrastructure to test this feature is not quite ready
yet, so I've added C unit tests instead.
Related: OS#4048
Change-Id: Ie35959f833f46bde5f2126314b6f96763f863b36
|
|
Change-Id: I464920b3d6d47bb1c797a4ce06230f005a2e06a0
|
|
Many files include unnecessary headers and don't include headers which
are actually used. Because of that combined with the fact that OsmoPCU
is a mixture of C and C++, it makes it hard to modularize code. Fix
this (using iwyu [1] tool):
* add missing headers
* remove unused headers
[1] https://include-what-you-use.org/
Related: OS#1539
Change-Id: I8c9f488a43b099c72b2d30d3245e7ba50872fc00
|
|
Change-Id: I59da04edd1b8ff965bbfbe00ccae1f7c9b6e5301
|
|
The osmocore bitvec is exact the same, but use a pointer instead of
a reference.
Change-Id: Id8f797631d89aa12b6e48efb2dc153a3e2f059f7
|
|
This approach is somehow flawed. We need/want to debug problems on
systems with real traffic and re-compiling it with debug_diagram
is not an option. All internal logging needs to be expressive enough
so we can understand what is going on (e.g. create a script to
post-process the output).
|
|
|
|
Now all updates to the tlli/tlli_valid are in one place. If we
implement the policy to update the matching/linked TBF we can
now to do it in a single place. Add a todo item for that as I
am waiting for feedback from the mailinglist.
|
|
This is like gsm_lchan_name and should be used in log statements.
This way we can easily change the information that is printed and
we know how to search things. The other part is that direct use
of tfi/tlli is removed which will allow us to make them private
and at the same time start to resolve the "tlli" updated in many
places.
Not old log statements are changed yet. This will done whenever
a bad log statement is seen on the console...
|
|
|
|
|
|
|
|
The list belongs to the BTS. This makes cleaning this up more easy
and establishes a hierachy of resources that start from the BTS. The
debug_diagram code is now broken.
|
|
Move the code around and then turn it into an object...
|
|
|
|
Add some TODO to this class. E.g. they could all work on the
bitvec and the parameter handling could better.
|
|
|
|
Only the gprs_rlcmac_pdch will manipulate the paging list now. There
can be various more refactorings of the code but they can be done
later. E.g. on memory allocation failure we can continue instead
of leaving the code, we should also set any_tbf only after things
have been paged.
|
|
Rely on packet_paging_request returning NULL in case the queue
is empty. We should move the write_packet_paging_request into
a separate file/object as well.
|
|
When a PDCH is disabled all resources should be freed. This is
currently not possible as the PDCH does not know where it belongs
to. On top of that the list (and other resources) should be
properly initialized on construction so that disable() is idempotent
and does not check if it was disabled. During the re-factoring I
noticed that during a sysmobts re-start some resources are not
freed. I left a warning in the code to resolve this issue later.
|
|
Begin to make the BTS a real C++ object with real responsibilities.
The biggest issue will be the pcu_vty.c that might not like C++
at all.
|
|
|
|
|
|
|
|
|
|
|
|
Similiar to the previous patches
|
|
Global state makes mocking/writing tests more difficult. Continue
by removing direct usage of the bts and adding it as pointer to
the function calls (showing the true dependencies of the functions)
|
|
|
|
|
|
Vladimir Rolbin pointed out that in case of the alloc_algorithm_a
the usf has not been assigned. For now move all the assignment into
a method and call it from the A and B algorithm.
|
|
Introduce the first instance method for printing out diagonistic
about itself and create a jump function for it.
|
|
|
|
|
|
This is the begin of a long march of turning tbf into a C++ class
and properly hiding the secrets inside this implementation instead
of having it spread across various different files.
|
|
|
|
Print the payload type that is not handled as this allows one to
look it up in the specification.
|
|
Do not claim that the payload is not known. Add the missing break.
Do not print:
<0002> gprs_rlcmac.cpp:1174 GPRS_RLCMAC_CONTROL_BLOCK_OPT block payload is not supported.
<0002> gprs_rlcmac.cpp:1176 Unknown RLCMAC block payload.
|
|
|
|
|
|
|
|
Call things by what they do and this function doesn't allocate
anything but it is searching for the first unallocated tbf index.
|
|
For mocking/unit-testing/emulation (and a dual trx-systems) having
global state is quite bad. Cut back on the usage of the global
struct gprs_rlcmac_bts. It also makes the complexity of certain
routines more clear.
|