Change in libosmocore[master]: gsm29118: add value strings for SGSAP IEI

dexter gerrit-no-reply at lists.osmocom.org
Thu Nov 15 14:08:42 UTC 2018


dexter has uploaded this change for review. ( https://gerrit.osmocom.org/11780


Change subject: gsm29118: add value strings for SGSAP IEI
......................................................................

gsm29118: add value strings for SGSAP IEI

The value strings for the SGSAP IEI are missing, lets add a set of value
strings and a function to retrieve them.

Change-Id: I2787303174f74ffba86675bce2c12f680d8ea708
Related: OS#3615
---
M include/osmocom/gsm/protocol/gsm_29_118.h
M src/gsm/gsm29118.c
M src/gsm/libosmogsm.map
3 files changed, 40 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/80/11780/1

diff --git a/include/osmocom/gsm/protocol/gsm_29_118.h b/include/osmocom/gsm/protocol/gsm_29_118.h
index c344f04..bf210ad 100644
--- a/include/osmocom/gsm/protocol/gsm_29_118.h
+++ b/include/osmocom/gsm/protocol/gsm_29_118.h
@@ -74,7 +74,10 @@
 	SGSAP_IE_ADDL_PAGING_INDICATORS		= 0x26,
 	SGSAP_IE_TMSI_BASED_NRI_CONT		= 0x27,
 };
-
+const struct value_string sgsap_iei_names[];
+static inline const char *sgsap_iei_name(enum sgsap_iei iei) {
+	return get_value_string(sgsap_iei_names, iei);
+}
 
 /* TS 29.118 Section 9.4.2 */
 enum sgsap_eps_lu_type {
diff --git a/src/gsm/gsm29118.c b/src/gsm/gsm29118.c
index de625a9..3898be6 100644
--- a/src/gsm/gsm29118.c
+++ b/src/gsm/gsm29118.c
@@ -32,6 +32,41 @@
 	{ 0, NULL }
 };
 
+const struct value_string sgsap_iei_names[] = {
+	{ SGSAP_IE_IMSI,			"IMSI" },
+	{ SGSAP_IE_VLR_NAME,			"VLR-NAME" },
+	{ SGSAP_IE_TMSI,			"TMSI" },
+	{ SGSAP_IE_LAI,				"LAI" },
+	{ SGSAP_IE_CHAN_NEEDED,			"CHAN-NEEDED" },
+	{ SGSAP_IE_EMLPP_PRIORITY,		"EMLPP-PRIORITY" },
+	{ SGSAP_IE_TMSI_STATUS,			"TMSI-STATUS" },
+	{ SGSAP_IE_SGS_CAUSE,			"SGS-CAUSE" },
+	{ SGSAP_IE_MME_NAME,			"MME-NAME" },
+	{ SGSAP_IE_EPS_LU_TYPE,			"EPS-LU-TYPE" },
+	{ SGSAP_IE_GLOBAL_CN_ID,		"GLOBAL-CN-ID" },
+	{ SGSAP_IE_MOBILE_ID,			"MOBILE-ID" },
+	{ SGSAP_IE_REJECT_CAUSE,		"REJECT-CAUSE" },
+	{ SGSAP_IE_IMSI_DET_EPS_TYPE,		"IMSI-DET-EPS-TYPE" },
+	{ SGSAP_IE_IMSI_DET_NONEPS_TYPE,	"IMSI-DET-NONEPS-TYPE" },
+	{ SGSAP_IE_IMEISV,			"IMEISV" },
+	{ SGSAP_IE_NAS_MSG_CONTAINER,		"NAS-MSG-CONTAINER" },
+	{ SGSAP_IE_MM_INFO,			"MM-INFO" },
+	{ SGSAP_IE_ERR_MSG,			"ERR-MSG" },
+	{ SGSAP_IE_CLI,				"CLI" },
+	{ SGSAP_IE_LCS_CLIENT_ID,		"LCS-CLIENT-ID" },
+	{ SGSAP_IE_LCS_INDICATOR,		"LCS-INDICATOR" },
+	{ SGSAP_IE_SS_CODE,			"SS-CODE" },
+	{ SGSAP_IE_SERVICE_INDICATOR,		"SERVICE-INDICATOR" },
+	{ SGSAP_IE_UE_TIMEZONE,			"UE-TIMEZONE" },
+	{ SGSAP_IE_MS_CLASSMARK2,		"MS-CLASSMARK2" },
+	{ SGSAP_IE_TAI,				"TAI" },
+	{ SGSAP_IE_EUTRAN_CGI,			"EUTRAN-CGI" },
+	{ SGSAP_IE_UE_EMM_MODE,			"UE-EMM-MODE" },
+	{ SGSAP_IE_ADDL_PAGING_INDICATORS,	"ADDL-PAGING-INDICATORS" },
+	{ SGSAP_IE_TMSI_BASED_NRI_CONT,		"TMSI-BASED-NRI-CONT" },
+	{ 0, NULL }
+};
+
 const struct value_string sgsap_eps_lu_type_names[] = {
 	{ SGSAP_EPS_LUT_IMSI_ATTACH,	"IMSI Attach" },
 	{ SGSAP_EPS_LUT_NORMAL,		"Normal" },
diff --git a/src/gsm/libosmogsm.map b/src/gsm/libosmogsm.map
index 4813e13..6234d94 100644
--- a/src/gsm/libosmogsm.map
+++ b/src/gsm/libosmogsm.map
@@ -512,6 +512,7 @@
 osmo_oap_client_register;
 
 sgsap_msg_type_names;
+sgsap_iei_names;
 sgsap_eps_lu_type_names;
 sgsap_ismi_det_eps_type_names;
 sgsap_ismi_det_noneps_type_names;

-- 
To view, visit https://gerrit.osmocom.org/11780
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2787303174f74ffba86675bce2c12f680d8ea708
Gerrit-Change-Number: 11780
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20181115/940ab81a/attachment.html>


More information about the gerrit-log mailing list