From 5b5c3499cfd9b001215ae23ca86ba04c780abb46 Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Wed, 26 Dec 2018 18:03:17 +0100 Subject: gsm_utils: add enum osmo_rat_type, from osmo-msc enum ran_type In the MSC, we have RAN types GERAN_A and UTRAN_IU, now we need a similar enum in osmo-hlr's GSUP client. Naming: in the MAP specifications, the RAN type is mostly called RAT type, (Radio Access Network vs. Radio Access Technology?). Since GSUP is more about MAP messages, I'm calling the enum osmo_rat_type. Rationale: osmo-msc and osmo-sgsn want to tell the osmo-hlr which RAT a subscriber is calling on. A subsequent patch will extend the GSUP protocol and add a RAT types IE. Change-Id: I659687aef7a4d67ca372a39fef31dee07aed7631 --- src/gsm/gsm_utils.c | 8 ++++++++ src/gsm/libosmogsm.map | 2 ++ 2 files changed, 10 insertions(+) (limited to 'src') diff --git a/src/gsm/gsm_utils.c b/src/gsm/gsm_utils.c index 8b4b5586..38620470 100644 --- a/src/gsm/gsm_utils.c +++ b/src/gsm/gsm_utils.c @@ -997,3 +997,11 @@ int gsm_7bit_encode_oct(uint8_t *result, const char *data, int *octets) return gsm_7bit_encode_n(result, GSM_7BIT_LEGACY_MAX_BUFFER_SIZE, data, octets); } + +/* This is also used by osmo-hlr's db schema */ +const struct value_string osmo_rat_type_names[] = { + { OSMO_RAT_UNKNOWN, "unknown" }, + { OSMO_RAT_GERAN_A, "GERAN-A" }, + { OSMO_RAT_UTRAN_IU, "UTRAN-Iu" }, + {} +}; diff --git a/src/gsm/libosmogsm.map b/src/gsm/libosmogsm.map index 76b3fd02..bb978786 100644 --- a/src/gsm/libosmogsm.map +++ b/src/gsm/libosmogsm.map @@ -553,5 +553,7 @@ sgsap_sgs_cause_names; sgsap_ue_emm_mode_names; sgsap_ie_tlvdef; +osmo_rat_type_names; + local: *; }; -- cgit v1.2.3