This primitive API allows the application to drive the RLCMAC layer
based on a lower L1CTL interface.
* RACH req are requested to the lower layers by the RLCMAC through the
RACH.req primitive.
* Received ImmAss, SI are fed to the RLC/MAC layer through CCCH_DATA.ind
* The RLCMAC registers DL and UL TBFs in the lower part (firwmare,
L1CTL):
** The lower part will trigger PDCH_RTS.ind in every TS in the
"(dl_slotmask|ul_slotmask)" superset, with the received USF. This
allows UL uplink to transmit blocks when requested by USF, or UL/DL TBF
to answer polls from PCU at a specific N+X FN (RRBP). This also allows
the RLCMAC layer to update its GSM clock and trigger internall
timeouts.
** The lower part will trigger PDCH_DATA.ind in every TS in the
dl_slotmask if either a CTRL block is received or a data block
matching the configured dl_tfi is received.
** Upon receival of PDCH_DATA.ind, the RLCMAC layer updates its FN clock
and submits PDCH_DATA.req based on USF.
This commit only adds the primitive set and API to submit/receive them,
but doesn't really implement them yet internally.
Related: OS#5500
Change-Id: I3d97425ec75059ceae983de869419230e8c4df01
Move types defined by spec not directly/solely intended for the CSN1
encoder/decoder operation to a separate types.h header.
More and more types will be added there which will be used by the data
domain inside and outside the library.
Change-Id: Ib0fdae48fc3e76d701d21644826e5ffd8553fecb
Done for files containing mostly (99%) of CSN1 related structrs and
encdec functions.
File ts_44_064.c is kept as is since it's not CSN1 related.
File csn1_ts_44_060.c still contains some enums and value_string which will
be split into ts_44_060.c in a follow up commit.
Change-Id: I93ad9f90e7496b81ccfe679a614589373f244166
That header is used (and should only be used) to contain CSN1 related
code for the encoder/decoder.
Hence rename it, otherwise it looks like a general placeholder for any
kind of stuff.
Change-Id: I84ea63ed0b804699fd995a2e0c07ced17b3ad4c8
llc_queue and codel code has been taken from osmo-pcu.git
6a5b1b1f3ef83f87a9df1d4511e22f59039e11ed and have been refactored to fit
in libosmo-gprs (removed llc_pdu structs, reworked struct types being
enqueued, etc.). Support for queues based on radio_prio has also been
added.
Related: OS#5500
Change-Id: Icdaa046fb6a71367f10beee16dcf9a5b7b61022e
The GRR primitives and types are kept 1-to-1 ABI compatible
to those at libosmo-gprs-llc so that they can be forwarded as pointers.
Still, we want to keep the types duplicated in order to avoid having to
depend one library on another, since the forwarding of one layer to the
other is done by the app and can use whatever it wishes on either side.
Related: OS#5500
Change-Id: I1870fa6a264612c5a669bfb832e6e8c0a892cb74
An initial header structure and LOG defines is created in a similar way
to those already existing for libosmo-gprs-llc and sndcp.
Related: OS#5500
Change-Id: Ic9ba207cafeada1b174f1b085e0d1d9a38c66b0a
Add missing definition for the <Multiple Blocks Packet Downlink
Assignment> structure. It's not 100% complete, but should serve
a good starting point if we ever need to support this.
Change-Id: I544245f690fdd14a94f858a5f3cd8f8d39d17611
Related: OS#5500
Use a self-explanatory name instead of the one with magic numbers.
It's safe to rename it because this API is not used anywhere yet.
Change-Id: I884cba359bfda21cf45fa846e5b7ff20d129bdf7
Related: OS#5500
Thanks to the unit tests, it was found that decoding of the LH part,
specifically the EGPRS Packet Uplink Assignment structure, is done
incorrectly. This patch fixes incorrect decoding.
Double usage of the UnionType element in the IA_EGPRS_t has a side
effect: the M_UINT actually consumes one bit, so the remaining bit
stream is shifted and decoded incorrectly.
Replace a combination of M_UINT and M_CHOICE with two M_UNIONs.
Remove struct IA_EGPRS_t, which is not used anywhere yet.
For reference, see 3GPP TS 44.018, table 10.5.2.16.1.
Change-Id: I7fedbad1ac4d744d1d3941553e573d4202e9d24a
Fixes: I39a29dc9b5b22ce4374ae33336696014e326d012
Related: OS#5500
This new API is needed for the MS side GPRS implementation in order
to be able to establish an Uplink TBF. Both wireshark and osmo-pcu
rely on hand-written code for parsing and generating the IA Rest
Octets IE, making no use of the CSN.1 codec.
We already have some (mostly commented out) CSN.1 definitions needed
for decoding the IA Rest Octets IE, inherited as-is from wireshark.
Ths patch adds the missing bits and a few unit test vectors.
Note that decoding of the LH part, specifically the EGPRS Packet
Uplink Assignment structure, is currently done incorrectly because
there is a problem in the IA_EGPRS_t definition. This will be
fixed in a follow-up patch.
For reference, see 3GPP TS 44.018, table 10.5.2.16.1.
Change-Id: I39a29dc9b5b22ce4374ae33336696014e326d012
Related: OS#5500
According to table 10.5.2.37b.1, SI 13 Rest Octets IE does contain
spare padding. Adding M_PADDING_BITS fixes decoder warnings about
unhandled remaining bits.
Change-Id: I44fb7e2a60da022ee99f1a6cd4f2635bef2bfe1e
Do not require the API user to include <stddef.h>:
note: 'offsetof' is defined in header '<stddef.h>';
did you forget to '#include <stddef.h>'?
Change-Id: I2a144c9967b90d78d95db103eebce83822d8c64d
This commit introduces a new library called 'libosmo-gprs-rlcmac',
which is going to be used by osmo-pcu and osmocom-bb for parsing
and generation of PDUs defined using CSN.1 (see 3GPP TS 24.007).
The actual RLC/MAC definitions are imported from osmo-pcu.git [1].
Change-Id: Ic322543e6d9a870beec83fa1166352e4a51366e7
Related: [1] osmo-pcu.git 0eaa3d379828517b5478d0202a26f6f3eb561a4e