From aead241df0282344e068dbae4d4221dbad7a71d9 Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Fri, 6 Apr 2018 04:31:00 +0200 Subject: add gsm48_reject_value_names There seems to be quite some confusion / overlap between enum gsm48_reject_value, gsm48_gsm_cause and gsm48_gmm_cause. I tried to go with gsm48_gsm_cause_names[], but e.g. GSM48_REJECT_CONGESTION is not represented. Instead of attempting to mix/merge those enums, provide a separate value string array for enum gsm48_reject_value. This will be used by osmo-msc's libvlr (refactoring of FSM result handling), I27bf8d68737ff1f8dc6d11fb1eac3d391aab0cb1. Change-Id: I6661f139e68a498fb1bef10c266c2f064b72774a --- include/osmocom/gsm/protocol/gsm_04_08.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include') diff --git a/include/osmocom/gsm/protocol/gsm_04_08.h b/include/osmocom/gsm/protocol/gsm_04_08.h index 4a821cca..6a5fb3bb 100644 --- a/include/osmocom/gsm/protocol/gsm_04_08.h +++ b/include/osmocom/gsm/protocol/gsm_04_08.h @@ -1509,6 +1509,10 @@ enum gsm48_reject_value { GSM48_REJECT_MSC_TMP_NOT_REACHABLE = 16, }; +extern const struct value_string gsm48_reject_value_names[]; +static inline const char *gsm48_reject_value_name(enum gsm48_reject_value val) +{ return get_value_string(gsm48_reject_value_names, val); } + enum chreq_type { CHREQ_T_EMERG_CALL, CHREQ_T_CALL_REEST_TCH_F, -- cgit v1.2.3