summaryrefslogtreecommitdiffstats
path: root/include/osmocom/gprs/gprs_ns.h
diff options
context:
space:
mode:
authorJacob Erlbeck <jerlbeck@sysmocom.de>2013-10-24 01:33:23 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2013-10-24 10:01:18 +0200
commit5405a104bbe7d3711fe6f19ea7d0fce50ef91147 (patch)
treed0bac56348b47cb2bf698e8d794d2cb1bc2c8801 /include/osmocom/gprs/gprs_ns.h
parent81d7c14756ee17c2748c3d34a198c640655fd0c6 (diff)
gb: Fix NS RESET/RESET_ACK abnormal cases
This changes the implementations for the reception of RESET and RESET_ACK to be compatible with 3GPP TS 08.16, 7.3.1: - Just send a RESET_ACK with correct values back to the SGSN when a RESET with an invalid NSVCI or NSEI has been received. - Check RESET_ACK for matching NSEI and NSVCI. - Ignore unexpected RESET_ACKs. In addition, use RESET_ACK from a BSS to update the BSS source address based on the NSVCI to be tolerant with changing UDP source addresses/ports. Sponsored-by: On-Waves ehf
Diffstat (limited to 'include/osmocom/gprs/gprs_ns.h')
-rw-r--r--include/osmocom/gprs/gprs_ns.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/osmocom/gprs/gprs_ns.h b/include/osmocom/gprs/gprs_ns.h
index b28c58d6..296800e4 100644
--- a/include/osmocom/gprs/gprs_ns.h
+++ b/include/osmocom/gprs/gprs_ns.h
@@ -36,6 +36,7 @@ enum ns_timeout {
#define NSE_S_BLOCKED 0x0001
#define NSE_S_ALIVE 0x0002
+#define NSE_S_RESET 0x0004
/*! \brief Osmocom NS link layer types */
enum gprs_ns_ll {
@@ -199,12 +200,16 @@ enum signal_ns {
S_NS_UNBLOCK,
S_NS_ALIVE_EXP, /* Tns-alive expired more than N times */
S_NS_REPLACED, /* nsvc object is replaced (sets old_nsvc) */
+ S_NS_MISMATCH, /* got an unexpected IE (sets msg, pdu_type, ie_type) */
};
struct ns_signal_data {
struct gprs_nsvc *nsvc;
struct gprs_nsvc *old_nsvc;
uint8_t cause;
+ uint8_t pdu_type;
+ uint8_t ie_type;
+ struct msgb *msg;
};
void gprs_ns_set_log_ss(int ss);