Commit Graph

21 Commits

Author SHA1 Message Date
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 8dc5648176 Move header files to include/osmocom/cbc/ dir
Change-Id: Id6c9f99805169d624a2c6e001fe1983e24fdc5c3
2022-07-04 13:35:47 +02:00
Pau Espin 9f2a1e3013 main: remove newline char in perror() call
perror() appends ":" immediatelly afterwards in order to append the
error string, so having a newline breaks the format.

Change-Id: I14874c2c86495c83030fa40c7060706e9dfe1968
2022-07-01 17:22:36 +02:00
Pau Espin b38bc5cb38 Fix typos in error messages
Change-Id: I42b201127535ae9fc61adbdc37e1d23897fd81d8
2022-07-01 17:15:26 +02:00
Pau Espin 14b862099e Configure libosmocore logging system as multithread
OsmoCBC uses libulfius, which creates its own thread(s).
Hence, we must set up osmocom logging system appropiately so that
relevant stuff is protected by locks.

Related: OS#5598
Change-Id: Ic06edc19d22b90e2b6b7de3a25d62cda5001f46e
2022-06-30 16:21:50 +02:00
Pau Espin b3ee9ca764 Rework cbsp_cbc_create() params
There's no need to pass the specific params. Let's simply get whatever
need from the global config in the function.
This makes it easier to extend it to more params if needed.
Also, when we add SBc-AP support, the params that have to be passed to
the counter part function are different, so let's simplify param
passing here.

While at it, rename also the callback function to contain "cbsp" on it,
since it is cbsp specific.

Change-Id: Ia2362757275e7cbce82b64c7c2a0798276d964c3
2022-06-21 12:11:49 +02:00
Harald Welte 8e1093e244 terminate if CBSP or ECBE ports cannot be bound
Change-Id: I748648a0bd5a06da26cddc34ff0d9b6000e71370
2021-01-24 14:05:47 +01:00
Harald Welte 78fd4efa81 Make ECBE (REST interface) local bind IP + port VTY-configurable
Change-Id: I656d0d1c7b21db90b62e71109d9844476a2e3215
2021-01-24 14:05:47 +01:00
Harald Welte 5180d5ffae Make CBSP local bind IP+port VTY-configurable
Change-Id: I9ba3f4cf129d6df4468defc92697f1df62348719
2021-01-24 12:11:22 +01:00
Harald Welte a3c73d9212 Major Documentation update
* add command line help
* add basic user manual
* add vty reference manual
* install example configuration

Change-Id: Idf49d7fcee2b11638945baa25064273a7e5e5e61
2021-01-06 18:59:02 +01:00
Harald Welte 2f551c1179 don't immediately delete all state about deleted messages
keep them around so we can still check statistics later on

Change-Id: I59f733dcbd5f9ea2617ceccf652c35fdd23a444b
2021-01-06 12:03:59 +01:00
Harald Welte b76ce452ff move from gettid() to pthread_self()
Whatever you do sucks:
* gettid() doens't have a glibc wrapper function in Debian <= 9
* pthrad_self() returns an opaque pthread_t where we shouldn't really
  make the assumption it's an unsigned long

Change-Id: Ida200de75333e0d35997158000def3cac89759b1
2021-01-06 12:03:59 +01:00
Harald Welte 7313772cdb WIP
Change-Id: I240b4be2fbb316e423d1bf366061b08912814011
2020-12-31 19:07:41 +01:00
Harald Welte 50ec65c5af more (and better) logging
Change-Id: Ie6965b154bd0a60559ce40ac4def988d137ba351
2020-12-31 17:32:44 +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 be8cbaf3fc exit(2) on unsupported positional arguments on command line
Change-Id: I701e6bffbfdfc98ff09b1d824e7707ef5a8b8059
2019-12-04 12:14:29 +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 f8d8a01b6e introduce cbc_data.h with core data model of CBC
Change-Id: I5afecfede6c0b718d71bd9c825d4074d3c6635ca
2019-07-20 15:37:29 +02:00
Harald Welte b8f7c3bd5e cbsp_server: Allow for bind to non-standard port + bind to IP
Change-Id: I7bf0002b514318ca8014bf92a7ce9a15ee4227c5
2019-07-20 15:32:58 +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