summaryrefslogtreecommitdiffstats
path: root/src/gb/gb_internal.h
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-07-01 21:04:45 +0200
committerHarald Welte <laforge@gnumonks.org>2019-02-26 12:18:30 +0100
commit047f3872f511353e894659719a6c5346249bca40 (patch)
treee719164186b93e96cfca6daa86b95f7679bbe669 /src/gb/gb_internal.h
parent35042a29197bd086a545976e5fa38d01c434f8ac (diff)
NS: Add support for GPRS NS IP Sub-Network-Service (SNS)
The NS implementation part of the Gb implementation libosmogb so far implemented a rather classic dialect of Gb, with lots of heritage to FR (Frame Relay) transports. At least since Release 6 of the NS specification, there's an IP Sub-Network Service (SNS), which * permits for dynamic configuration of IP endpoints and their NS-VCs * abandons the concept of a NSVCI on IP transport * forbids the use of RESET/BLOCK/UNBLOCK procedures on IP transport This commit introduces BSS-side IP-SNS support to libosmogb in a minimally invasive way. It adds a corresponding SNS FSM to each NS instance, and implements the new SIZE/CONFIG/ADD/DELETE/CHANGE_WEIGHT procedures very closely aligned with the spec. In order to use the SNS flavor (rather than the classic one), a BSS implementation should use gprs_ns_nsip_connect_sns() instead of the existing gprs_ns_nsip_connect(). This implementation comes with a set of TTCN-3 tests in PCU_Tests_RAW_SNS.ttcn, see Change-ID I0fe3d4579960bab0494c294ec7ab8032feed4fb2 of osmo-ttcn3-hacks.git Closes: OS#3372 Closes: OS#3617 Change-Id: I84786c3b43a8ae34ef3b3ba84b33c90042d234ea
Diffstat (limited to 'src/gb/gb_internal.h')
-rw-r--r--src/gb/gb_internal.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gb/gb_internal.h b/src/gb/gb_internal.h
index 72d940f5..cc7222e8 100644
--- a/src/gb/gb_internal.h
+++ b/src/gb/gb_internal.h
@@ -4,7 +4,17 @@
#include <osmocom/gsm/tlv.h>
#include <osmocom/gprs/gprs_ns.h>
+/* gprs_ns_sns.c */
+int gprs_ns_rx_sns(struct gprs_ns_inst *nsi, struct msgb *msg, struct tlv_parsed *tp);
+
+struct osmo_fsm_inst *gprs_sns_bss_fsm_alloc(void *ctx, struct gprs_nsvc *nsvc, const char *id);
+int gprs_sns_bss_fsm_start(struct gprs_ns_inst *nsi);
+
+int gprs_sns_init(void);
+
+/* gprs_ns.c */
void gprs_nsvc_start_test(struct gprs_nsvc *nsvc);
+void gprs_start_alive_all_nsvcs(struct gprs_ns_inst *nsi);
int gprs_ns_tx_sns_ack(struct gprs_nsvc *nsvc, uint8_t trans_id, uint8_t *cause,
const struct gprs_ns_ie_ip4_elem *ip4_elems,unsigned int num_ip4_elems);
@@ -18,3 +28,6 @@ int gprs_ns_tx_sns_size(struct gprs_nsvc *nsvc, bool reset_flag, uint16_t max_nr
uint16_t *ip4_ep_nr, uint16_t *ip6_ep_nr);
int gprs_ns_tx_sns_size_ack(struct gprs_nsvc *nsvc, uint8_t *cause);
+
+struct vty;
+void gprs_sns_dump_vty(struct vty *vty, const struct gprs_ns_inst *nsi, bool stats);