diff options
author | Harald Welte <laforge@gnumonks.org> | 2016-04-25 19:01:26 +0200 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2016-04-29 13:10:37 +0200 |
commit | 50f1c0af567423b6ade9a84aaa5197ecf6237819 (patch) | |
tree | 7f3ae0ca3ff35d790c29eac8b83f543feae0a59b /openbsc/src/gprs/oap_messages.c | |
parent | eff215a8bb766e62a02bcc0f4334470a53475001 (diff) |
move utils.h functions to libosmocore
This needs the corresponding commit in libosmocore which imports
the related functions
Diffstat (limited to 'openbsc/src/gprs/oap_messages.c')
-rw-r--r-- | openbsc/src/gprs/oap_messages.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/openbsc/src/gprs/oap_messages.c b/openbsc/src/gprs/oap_messages.c index 49b54e439..d5750a612 100644 --- a/openbsc/src/gprs/oap_messages.c +++ b/openbsc/src/gprs/oap_messages.c @@ -20,11 +20,11 @@ * */ +#include <osmocom/core/utils.h> #include <openbsc/oap_messages.h> #include <openbsc/debug.h> #include <openbsc/gprs_utils.h> -#include <openbsc/utils.h> #include <osmocom/gsm/tlv.h> #include <osmocom/core/msgb.h> @@ -51,7 +51,7 @@ int oap_decode(const uint8_t *const_data, size_t data_len, rc = osmo_shift_v_fixed(&data, &data_len, 1, &value); if (rc < 0) return -GMM_CAUSE_INV_MAND_INFO; - oap_msg->message_type = decode_big_endian(value, 1); + oap_msg->message_type = osmo_decode_big_endian(value, 1); /* specific parts */ while (data_len > 0) { @@ -72,7 +72,7 @@ int oap_decode(const uint8_t *const_data, size_t data_len, return -GMM_CAUSE_PROTO_ERR_UNSPEC; } - oap_msg->client_id = decode_big_endian(value, value_len); + oap_msg->client_id = osmo_decode_big_endian(value, value_len); if (oap_msg->client_id == 0) { LOGP(DGPRS, LOGL_NOTICE, @@ -159,7 +159,8 @@ void oap_encode(struct msgb *msg, const struct oap_message *oap_msg) if (oap_msg->client_id > 0) msgb_tlv_put(msg, OAP_CLIENT_ID_IE, sizeof(oap_msg->client_id), - encode_big_endian(oap_msg->client_id, sizeof(oap_msg->client_id))); + osmo_encode_big_endian(oap_msg->client_id, + sizeof(oap_msg->client_id))); if (oap_msg->rand_present) msgb_tlv_put(msg, OAP_RAND_IE, sizeof(oap_msg->rand), oap_msg->rand); |