Commit Graph

20 Commits

Author SHA1 Message Date
Pau Espin d24c3dfba0 Split smscb_peer_fsm into CBSP and SBcAP specific FSMs
This further simplifies tracking of events and simplifies and clears
code on each of the FSMs.

Change-Id: I0fd00b60cdc6bc6a088be1336d849548ca89c847
2022-07-29 14:54:26 +02:00
Pau Espin 7beca6fda0 Rearrange cbc_message and cbsp message code
Move code from message_handling containing both code for generic
cbc_message and specific cbsp_message into thers files. The former are
moved to cbc_message.c and the later to cbsp_msg.c, similar to what's
already done for SBc-AP messages.

Change-Id: Ie4082e40f23170cfd6c573fbbb7beb8c6226b6e6
2022-07-26 10:01:05 +02:00
Pau Espin 5661cef889 Move struct cbc bring up code to its own file and functions
This way it's clear and we have in one place all the related code that
neds to be run at a given time.t

Change-Id: I00fe755340664d4ca4a5cfdcae8d4cd33b2f40a1
2022-07-22 15:45:09 +02:00
Pau Espin 5f6dfe77d4 Rename {cbsp,sbcap}_server(_fsm).h s/server/link/
Change-Id: I1e56dd1fcba23f6efd209e9d4dcdc88c8866d250
2022-07-20 20:10:16 +02:00
Pau Espin 36be606dd4 Split cbc_message related code to its own .c and .h file
Change-Id: I41f6e169b1ee6731cd472f6b72ea922260e30ceb
2022-07-20 19:23:36 +02:00
Pau Espin 1486ac0191 Split cbc_peer to its own .c and .h files
Change-Id: I41c890d81e76ac1a1c89d42af70a1f0631e9724e
2022-07-20 17:58:45 +02:00
Pau Espin 6e59534d6b Add initial SBc-AP support to osmo-cbc
This patch makes use of the newly introduced sbcap library, and
introduces new code (and extends existing one) to handle all the aspects
of MME peers talking SBc-AP and its underlaying SCTP connection.

This commit doesn't aim to implement all the SBc-AP features, but to
implement a minimal subset of features already available for CBSP in
osmo-cbc, in order to have similar support level for both 2G and 4G
networks.

Related: OS#4945
Change-Id: Ib278bc1d1a74459814016fef7a8fe21cc29d46c9
2022-07-19 09:10:12 +00:00
Pau Espin 4b8175d189 Add sbcap library
This commit adds initial support to encode/decode SBc-AP messages in the
form of a library, under src/sbcap/ (includes in
include/osmocom/sbcap/).
asn1c is used to generate all suport code and structures for ASN.1 APER
encoding/decoding, based on asn files obtained from 3GPP TS 29.168 and
stored under src/sbcap/asn1/.
Currently, mainstream asn1c doesn't yet support ASN.1 APER
encoding/decoding, hence mouse07410 's fork is used [1]. Furthermore,
several encdoing/decoding bugs where found during the process and fixed,
which means asn1.c git >= 30219de2d3da888b4f1eea0dd79f2a505000401a must
be used to generate proper code.

A new "make -C src/ gen" target is added which can be used to regenerate
all C code from the available ASN.1 files in src/sbcap/asn1/*.asn (after
properly setting configure.ac ASN_* variables if needed).

[1] https://github.com/mouse07410/asn1c

Related: OS#4945
Change-Id: If76f8619a9b2d46af6d94b8ae49348b8514e53aa
2022-07-15 15:53:35 +02:00
Pau Espin 8dc5648176 Move header files to include/osmocom/cbc/ dir
Change-Id: Id6c9f99805169d624a2c6e001fe1983e24fdc5c3
2022-07-04 13:35:47 +02:00
Pau Espin fb6f123daf src/Makefile: Reformat files one per line
Change-Id: I666d6cd1461117397e05ac573c834a82abb2807d
2022-06-16 16:10:14 +02:00
Harald Welte edf22db326 more fsm wip
Change-Id: I29c7eca5f56061b66e303b952f8f04c71438fe8b
2020-12-31 01:18:34 +01:00
Harald Welte 0aa005141d WIP: smscb_peer_fsm
Change-Id: I7941e373bea6ed5299fa9f53c03ff7cbcf38548d
2020-12-30 17:18:35 +01:00
Harald Welte 41634872dc WIP: use inter-thread queue between REST and main
This way we serialize access to core data structures and also allow
future per-message FSMs in the main thread to first communicate to the
RAN peers before permitting the REST/HTTP worker thread to return
any response back to the external REST interface user.

Change-Id: Ia9f656733cf16412926a6d6dc9e1ff4243d941af
2020-12-30 17:18:31 +01:00
Harald Welte 85d1b36e9d foo
Change-Id: I266dfb3862e7c9794fc1bbbb143740eb120b3125
2020-12-30 17:18:07 +01:00
Harald Welte fdb29d94e3 track libulfius memory allocations using talloc
Change-Id: I9be666e5fac0caf6f7d07c01f39e0f409c7465db
2019-08-05 22:09:34 +02:00
Harald Welte 83b4096efa add minimalistic VTY
Change-Id: I55cd44fd7ef342c1262eaede393312aa29f01b58
2019-08-05 22:09:15 +02:00
Harald Welte ba6868f4b9 Add some basic functions operating on cbc_data structures
Change-Id: I6c2e5a193a902040f21e6c6d5de578647696d9d6
2019-07-20 21:51:53 +02:00
Harald Welte 0c7a0346fc fix 'make dist': Include header files
Change-Id: Ie8728c4fc1fe60b8fd3b5d20b95721a800f3aa7e
2019-07-20 15:39:40 +02:00
Harald Welte 1b13c35884 Add initial version of REST API
Change-Id: Ib38cefa59553af6f5bc0414d6d2845f40de8fd04
2019-07-20 14:44:22 +02:00
Harald Welte 63b7905fa3 Initial (building) start of OsmoCBC (Cell Broadcast Centre)
this is far from doing anything useful yet. Stay tuned.

Change-Id: I64a6833ce068db60d713d0fa318a1d8093e37be9
2019-05-06 23:15:23 +02:00