Feature #1537

Move the BSSGP handling to libosmocore

Added by zecke almost 5 years ago. Updated almost 3 years ago.

Target version:
Start date:
Due date:
% Done:


Spec Reference:


Currently the BSSGP stack is cut into two halves. The SGSN side is implemented as a part of libosmocore the BSS side is implemented within the PCU (protocol) and libosmocore (tx functions, bctx allocation).

In libosmocore, incoming messages are just decoded, the protocol handling is done (mainly sending acknowledges or status messages), the corresponding bctx is updated, and further processing is passed to the upper layer via BSSGP primitives. Only the BVC RESET code does a bit more, since it automatically allocates bctx for unknown BVCIs.

The PCU contains the full protocol handling for the BSS side. Since only BVC RESET and STATUS may be sent in either direction, there is not much code duplication. But the BSS side implementation cannot be used for other projects that way (e.g. for intermediaries like the gbproxy).

The bssgp_rcvmsg() can already be used by the BSS side to process BSSGP messages, which only makes sense for BSSGP STATUS currently.


  • Adapt the PCU functions to invoke BSSGP primaries instead of doing the PCU related action directly from within the rx functions
  • Integrate the BSS side message dispatcher into libosmocore's BSSGP stack, the cases are already there
  • Delegate the creation of BSSGP contexts (bctx) in bssgp_rx_bvc_reset to the higher layers by using (and inventing) a primary call or by modifying the semantics of the existing one (e.g. using the rc of bssgp_prim_cb to decide, whether to send ACK or STATUS)

Related issues

Related to OsmoPCU - Bug #1638: BVC RESET ignoredClosed03/09/2016

Related to OsmoPCU - Bug #2388: OsmoPCU sends BVC-RESET over NS-VC which is still in state BLOCKEDResolved07/23/2017


#1 Updated by msuraev over 3 years ago

  • Related to Bug #1638: BVC RESET ignored added

#2 Updated by laforge almost 3 years ago

  • Assignee deleted (msuraev)

#3 Updated by msuraev about 2 years ago

  • Related to Bug #2388: OsmoPCU sends BVC-RESET over NS-VC which is still in state BLOCKED added

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)