summaryrefslogtreecommitdiffstats
path: root/src/gb/gb_internal.h
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-07-01 19:09:52 +0200
committerHarald Welte <laforge@gnumonks.org>2019-02-26 11:17:44 +0000
commit17a642d8ff309119532bf85f4ad95d1b049047f0 (patch)
tree759ffa3cebcb922247961fcdc32a9a6236a9bb9e /src/gb/gb_internal.h
parent99273c7662b786a9c92d25282060dc791ee37a4a (diff)
gprs_ns: Add code for SNS-SIZE and SNS-CONFIG encoding
Modern NS specifications contain a SNS (Sub Network Service) for negotiating IP/port/weight parameters of NS-over-IP links dynamically. This patch adds message encoding routines for SNS-CONFIG, SNS-SIZE and their respective acknowledgements. Related: OS#3372 Change-Id: I5c47e1c3c10deb89a7470ee2c03adfc174accc93
Diffstat (limited to 'src/gb/gb_internal.h')
-rw-r--r--src/gb/gb_internal.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/gb/gb_internal.h b/src/gb/gb_internal.h
new file mode 100644
index 00000000..c1fa8e19
--- /dev/null
+++ b/src/gb/gb_internal.h
@@ -0,0 +1,19 @@
+#pragma once
+
+#include <osmocom/core/msgb.h>
+#include <osmocom/gsm/tlv.h>
+#include <osmocom/gprs/gprs_ns.h>
+
+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);
+
+int gprs_ns_tx_sns_config(struct gprs_nsvc *nsvc, bool end_flag,
+ const struct gprs_ns_ie_ip4_elem *ip4_elems,
+ unsigned int num_ip4_elems);
+
+int gprs_ns_tx_sns_config_ack(struct gprs_nsvc *nsvc, uint8_t *cause);
+
+int gprs_ns_tx_sns_size(struct gprs_nsvc *nsvc, bool reset_flag, uint16_t max_nr_nsvc,
+ uint16_t *ip4_ep_nr, uint16_t *ip6_ep_nr);
+
+int gprs_ns_tx_sns_size_ack(struct gprs_nsvc *nsvc, uint8_t *cause);