summaryrefslogtreecommitdiffstats
path: root/include/osmocom/gsm
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-06-16 18:34:52 +0200
committerHarald Welte <laforge@gnumonks.org>2018-06-16 18:39:59 +0200
commitb1a35d63b9ad888429216276d060429d0991aaf7 (patch)
tree2eb5cbe8b01eedf5903268f8e0b16fdd473152be /include/osmocom/gsm
parent6a6a609309bee71e0ed0cba4753f06ae36038a44 (diff)
gsm 04.80: Add value_string for component type and op code
Change-Id: I2615a88db5224d65f37c7cc505e183ec8b196e8a
Diffstat (limited to 'include/osmocom/gsm')
-rw-r--r--include/osmocom/gsm/gsm0480.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/osmocom/gsm/gsm0480.h b/include/osmocom/gsm/gsm0480.h
index fafa1f4b..e928d83f 100644
--- a/include/osmocom/gsm/gsm0480.h
+++ b/include/osmocom/gsm/gsm0480.h
@@ -7,6 +7,16 @@
#include <osmocom/gsm/protocol/gsm_04_08.h>
#include <osmocom/gsm/protocol/gsm_04_80.h>
+extern const struct value_string gsm0480_comp_type_names[];
+static inline const char *gsm0480_comp_type_name(uint8_t comp_type) {
+ return get_value_string(gsm0480_comp_type_names, comp_type);
+}
+
+extern const struct value_string gsm0480_op_code_names[];
+static inline const char *gsm0480_op_code_name(uint8_t op_code) {
+ return get_value_string(gsm0480_op_code_names, op_code);
+}
+
/**
* According to the GSM 04.80 (version 5.0.0) specification Annex A
* "Expanded ASN.1 Module "SS-Protocol", the maximum size of a USSD