libosmogsm 1.10.0.57-8972
Osmocom GSM library
|
Files | |
file | bssmap_le.h |
Message encoding and decoding for 3GPP TS 49.031 BSSMAP-LE. | |
file | gsm_49_031.h |
file | bssmap_le.c |
Message encoding and decoding for 3GPP TS 49.031 BSSMAP-LE. | |
Data Structures | |
struct | osmo_bssmap_le_err |
struct | osmo_bssap_le_err |
struct | lcs_cause_ie |
3GPP TS 49.031 10.13 LCS Cause, also in 3GPP TS 48.008 3.2.2.66, which simply refers to the former. More... | |
struct | osmo_bssmap_le_lcs_qos |
struct | bssmap_le_location_type |
struct | bssmap_le_perform_loc_req |
struct | bssmap_le_perform_loc_resp |
struct | bssmap_le_conn_oriented_info |
struct | bssmap_le_pdu |
struct | bssap_le_pdu |
struct | osmo_bssap_le_header |
Macros | |
#define | BSSAP_LE_MSG_SIZE BSSMAP_MSG_SIZE |
#define | BSSAP_LE_MSG_HEADROOM BSSMAP_MSG_HEADROOM |
#define | DEC_ERR_NO_RETURN(RC, MSG_TYPE, IEI, CAUSE, fmt, args...) |
#define | DEC_ERR(RC, MSG_TYPE, IEI, CAUSE, fmt, args...) |
#define | DEC_IE_MANDATORY(MSG_TYPE, IEI, DEC_FUN, DEC_FUN_ARG) |
#define | DEC_IE_OPTIONAL_FLAG(MSG_TYPE, IEI, DEC_FUN, DEC_FUN_ARG, PRESENCE_FLAG) |
#define | DEC_IE_OPTIONAL(MSG_TYPE, IEI, DEC_FUN, DEC_FUN_ARG) |
Functions | |
enum bssmap_le_msgt | osmo_bssmap_le_msgt (const uint8_t *data, uint8_t len) |
Return the BSSMAP-LE msg_type from a BSSAP-LE PDU, e.g. More... | |
static const char * | osmo_bssmap_le_msgt_name (enum bssmap_le_msgt val) |
static const char * | osmo_bssmap_le_iei_name (enum bssmap_le_iei val) |
int | osmo_lcs_cause_enc (struct msgb *msg, const struct lcs_cause_ie *lcs_cause) |
Encode the value part of 3GPP TS 49.031 10.13 LCS Cause, without IEI and len. More... | |
int | osmo_lcs_cause_dec (struct lcs_cause_ie *lcs_cause, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *data, uint8_t len) |
Decode the value part of 3GPP TS 49.031 10.13 LCS Cause, without IEI and len. More... | |
int | osmo_bssap_le_pdu_to_str_buf (char *buf, size_t buflen, const struct bssap_le_pdu *bssap_le) |
Return a human readable string describing a BSSAP-LE PDU. More... | |
char * | osmo_bssap_le_pdu_to_str_c (void *ctx, const struct bssap_le_pdu *bssap_le) |
Return a human readable string describing a BSSAP-LE PDU. More... | |
struct msgb * | osmo_bssap_le_enc (const struct bssap_le_pdu *pdu) |
Encode BSSAP-LE PDU returned in new msgb (3GPP TS 49.031). More... | |
int | osmo_bssap_le_dec (struct bssap_le_pdu *pdu, struct osmo_bssap_le_err **err, void *err_ctx, struct msgb *msg) |
Decode BSSAP-LE PDU (3GPP TS 49.031). More... | |
uint8_t | osmo_bssmap_le_ie_enc_location_type (struct msgb *msg, const struct bssmap_le_location_type *location_type) |
Encode full BSSMAP-LE Location Type IE, including IEI tag and length. More... | |
int | osmo_bssmap_le_ie_dec_location_type (struct bssmap_le_location_type *lt, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
Decode BSSMAP-LE Location Type IE value part. More... | |
struct osmo_bssmap_le_lcs_qos | __attribute__ ((packed)) |
static uint8_t | osmo_bssmap_le_ie_enc_lcs_client_type (struct msgb *msg, enum bssmap_le_lcs_client_type client_type) |
Encode full BSSMAP-LE LCS Client Type IE, including IEI tag and length. More... | |
static int | osmo_bssmap_le_ie_dec_lcs_client_type (enum bssmap_le_lcs_client_type *client_type, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static uint8_t | osmo_bssmap_le_ie_enc_lcs_priority (struct msgb *msg, uint8_t priority) |
Encode full BSSMAP-LE LCS Priority IE, including IEI tag and length. More... | |
static int | osmo_bssmap_le_ie_dec_lcs_priority (uint8_t *priority, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static uint8_t | osmo_bssmap_le_ie_enc_lcs_qos (struct msgb *msg, const struct osmo_bssmap_le_lcs_qos *qos) |
Encode full BSSMAP-LE LCS QoS IE, including IEI tag and length. More... | |
static int | osmo_bssmap_le_ie_dec_lcs_qos (struct osmo_bssmap_le_lcs_qos *qos, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static int | osmo_bssmap_le_ie_enc_apdu (struct msgb *msg, const struct bsslap_pdu *bsslap) |
static int | osmo_bssmap_le_ie_dec_apdu (struct bsslap_pdu *bsslap, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *data, size_t len) |
static int | osmo_bssmap_le_ie_dec_cell_id (struct gsm0808_cell_id *cell_id, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static int | osmo_bssmap_le_ie_dec_imsi (struct osmo_mobile_identity *imsi, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static int | osmo_bssmap_le_ie_dec_imei (struct osmo_mobile_identity *imei, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static int | osmo_bssmap_le_ie_dec_gad (union gad_raw *gad, enum bssmap_le_msgt msgt, enum bssmap_le_iei iei, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *elem, uint8_t len) |
static int | osmo_bssmap_le_enc_reset (struct msgb *msg, enum gsm0808_cause cause) |
static int | osmo_bssmap_le_dec_reset (enum gsm0808_cause *cause, enum bssmap_le_msgt msgt, struct osmo_bssmap_le_err **err, void *err_ctx, const struct tlv_parsed *tp) |
static int | osmo_bssmap_le_enc_perform_loc_req (struct msgb *msg, const struct bssmap_le_perform_loc_req *params) |
static int | osmo_bssmap_le_dec_perform_loc_req (struct bssmap_le_perform_loc_req *params, enum bssmap_le_msgt msgt, struct osmo_bssmap_le_err **err, void *err_ctx, const struct tlv_parsed *tp) |
static int | osmo_bssmap_le_enc_perform_loc_resp (struct msgb *msg, const struct bssmap_le_perform_loc_resp *params) |
static int | osmo_bssmap_le_dec_perform_loc_resp (struct bssmap_le_perform_loc_resp *params, enum bssmap_le_msgt msgt, struct osmo_bssmap_le_err **err, void *err_ctx, const struct tlv_parsed *tp) |
static int | osmo_bssmap_le_enc_perform_loc_abort (struct msgb *msg, const struct lcs_cause_ie *params) |
static int | osmo_bssmap_le_dec_perform_loc_abort (struct lcs_cause_ie *params, enum bssmap_le_msgt msgt, struct osmo_bssmap_le_err **err, void *err_ctx, const struct tlv_parsed *tp) |
static int | osmo_bssmap_le_enc_conn_oriented_info (struct msgb *msg, const struct bssmap_le_conn_oriented_info *params) |
static int | osmo_bssmap_le_dec_conn_oriented_info (struct bssmap_le_conn_oriented_info *params, enum bssmap_le_msgt msgt, struct osmo_bssmap_le_err **err, void *err_ctx, const struct tlv_parsed *tp) |
static int | osmo_bssmap_le_enc (struct msgb *msg, const struct bssmap_le_pdu *pdu) |
Encode BSSMAP-LE PDU and add to msgb (3GPP TS 49.031). More... | |
static int | osmo_bssmap_le_dec (struct bssmap_le_pdu *pdu, struct osmo_bssmap_le_err **err, void *err_ctx, const uint8_t *data, size_t len) |
Decode BSSMAP-LE PDU (3GPP TS 49.031). More... | |
Variables | |
const struct value_string | osmo_bssmap_le_msgt_names [] |
const struct value_string | osmo_bssmap_le_iei_names [] |
enum bssap_le_msg_discr | __attribute__ |
static const struct tlv_definition | osmo_bssmap_le_tlvdef |
const struct value_string | osmo_bssmap_le_msgt_names [] |
const struct value_string | osmo_bssmap_le_iei_names [] |
#define BSSAP_LE_MSG_HEADROOM BSSMAP_MSG_HEADROOM |
#define BSSAP_LE_MSG_SIZE BSSMAP_MSG_SIZE |
#define DEC_ERR | ( | RC, | |
MSG_TYPE, | |||
IEI, | |||
CAUSE, | |||
fmt, | |||
args... | |||
) |
#define DEC_ERR_NO_RETURN | ( | RC, | |
MSG_TYPE, | |||
IEI, | |||
CAUSE, | |||
fmt, | |||
args... | |||
) |
#define DEC_IE_MANDATORY | ( | MSG_TYPE, | |
IEI, | |||
DEC_FUN, | |||
DEC_FUN_ARG | |||
) |
#define DEC_IE_OPTIONAL | ( | MSG_TYPE, | |
IEI, | |||
DEC_FUN, | |||
DEC_FUN_ARG | |||
) |
#define DEC_IE_OPTIONAL_FLAG | ( | MSG_TYPE, | |
IEI, | |||
DEC_FUN, | |||
DEC_FUN_ARG, | |||
PRESENCE_FLAG | |||
) |
enum bssap_le_msg_discr |
enum bssmap_le_apdu_proto |
enum bssmap_le_iei |
enum bssmap_le_msgt |
enum lcs_cause |
3GPP TS 49.031 10.13 LCS Cause, also in 3GPP TS 48.008 3.2.2.66, which simply refers to the former.
struct osmo_bssmap_le_lcs_qos __attribute__ | ( | (packed) | ) |
int osmo_bssap_le_dec | ( | struct bssap_le_pdu * | pdu, |
struct osmo_bssap_le_err ** | err, | ||
void * | err_ctx, | ||
struct msgb * | msg | ||
) |
Decode BSSAP-LE PDU (3GPP TS 49.031).
[out] | pdu | Write decoded values here. |
[in] | data | Pointer to BSSMAP-LE PDU raw data. |
[in] | len | Data length to decode. |
References BSSAP_LE_DEC_ERR, BSSAP_LE_MSG_DISCR_BSSMAP_LE, bssap_le_pdu::bssmap_le, h, osmo_bssmap_le_err::logmsg, msg, msgb_l2, msgb_l2len(), osmo_bssmap_le_dec(), and osmo_bssmap_le_err::rc.
struct msgb * osmo_bssap_le_enc | ( | const struct bssap_le_pdu * | pdu | ) |
Encode BSSAP-LE PDU returned in new msgb (3GPP TS 49.031).
By spec, BSSAP-LE contains either BSSMAP-LE or DTAP.
[in] | pdu | PDU data to encode. |
References BSSAP_LE_MSG_DISCR_BSSMAP_LE, BSSAP_LE_MSG_HEADROOM, BSSAP_LE_MSG_SIZE, bssap_le_pdu::bssmap_le, bssap_le_pdu::discr, msg, bssmap_le_pdu::msg_type, msgb_alloc_headroom(), msgb_free(), msgb_length(), msgb_tv_push(), osmo_bssmap_le_enc(), and osmo_bssmap_le_msgt_name().
int osmo_bssap_le_pdu_to_str_buf | ( | char * | buf, |
size_t | buflen, | ||
const struct bssap_le_pdu * | bssap_le | ||
) |
Return a human readable string describing a BSSAP-LE PDU.
[out] | buf | String buffer to write to. |
[in] | buflen | sizeof(buf). |
[in] | bssap_le | Decoded BSSAP-LE PDU data. |
References bssmap_le_perform_loc_req::apdu, bssmap_le_conn_oriented_info::apdu, bssmap_le_perform_loc_req::apdu_present, BSSAP_LE_MSG_DISCR_BSSMAP_LE, bssap_le_pdu::bssmap_le, BSSMAP_LE_MSGT_CONN_ORIENTED_INFO, BSSMAP_LE_MSGT_PERFORM_LOC_REQ, osmo_strbuf::buf, osmo_strbuf::chars_needed, bssmap_le_pdu::conn_oriented_info, bssap_le_pdu::discr, bsslap_pdu::msg_type, bssmap_le_pdu::msg_type, osmo_bsslap_msgt_name(), osmo_bssmap_le_msgt_name(), OSMO_STRBUF_PRINTF, and bssmap_le_pdu::perform_loc_req.
Referenced by osmo_bssap_le_pdu_to_str_c().
char * osmo_bssap_le_pdu_to_str_c | ( | void * | ctx, |
const struct bssap_le_pdu * | bssap_le | ||
) |
Return a human readable string describing a BSSAP-LE PDU.
[in] | ctx | Talloc context to allocate string buffer from. |
[in] | bssap_le | Decoded BSSAP-LE PDU data. |
References osmo_bssap_le_pdu_to_str_buf(), and OSMO_NAME_C_IMPL.
|
static |
Decode BSSMAP-LE PDU (3GPP TS 49.031).
See also osmo_bssap_le_dec().
[out] | pdu | Write decoded values here. |
[in] | data | Pointer to BSSMAP-LE PDU raw data. |
[in] | len | Data length to decode. |
References BSSMAP_LE_MSGT_CONN_ORIENTED_INFO, BSSMAP_LE_MSGT_PERFORM_LOC_ABORT, BSSMAP_LE_MSGT_PERFORM_LOC_REQ, BSSMAP_LE_MSGT_PERFORM_LOC_RESP, BSSMAP_LE_MSGT_RESET, BSSMAP_LE_MSGT_RESET_ACK, bssmap_le_pdu::conn_oriented_info, data, DEC_ERR, LCS_CAUSE_UNSPECIFIED, len, bssmap_le_pdu::msg_type, osmo_bssmap_le_dec_conn_oriented_info(), osmo_bssmap_le_dec_perform_loc_abort(), osmo_bssmap_le_dec_perform_loc_req(), osmo_bssmap_le_dec_perform_loc_resp(), osmo_bssmap_le_dec_reset(), osmo_bssmap_le_tlvdef, bssmap_le_pdu::perform_loc_abort, bssmap_le_pdu::perform_loc_req, bssmap_le_pdu::perform_loc_resp, bssmap_le_pdu::reset, and tlv_parse().
Referenced by osmo_bssap_le_dec().
|
static |
References BSSMAP_LE_IEI_APDU, DEC_IE_MANDATORY, osmo_bssmap_le_ie_dec_apdu(), and params.
Referenced by osmo_bssmap_le_dec().
|
static |
References BSSMAP_LE_IEI_LCS_CAUSE, DEC_IE_MANDATORY, osmo_lcs_cause_dec(), and params.
Referenced by osmo_bssmap_le_dec().
|
static |
References BSSMAP_LE_IEI_APDU, BSSMAP_LE_IEI_CELL_ID, BSSMAP_LE_IEI_IMEI, BSSMAP_LE_IEI_IMSI, BSSMAP_LE_IEI_LCS_CLIENT_TYPE, BSSMAP_LE_IEI_LCS_PRIORITY, BSSMAP_LE_IEI_LCS_QoS, BSSMAP_LE_IEI_LOCATION_TYPE, DEC_IE_MANDATORY, DEC_IE_OPTIONAL, DEC_IE_OPTIONAL_FLAG, osmo_bssmap_le_ie_dec_apdu(), osmo_bssmap_le_ie_dec_cell_id(), osmo_bssmap_le_ie_dec_imei(), osmo_bssmap_le_ie_dec_imsi(), osmo_bssmap_le_ie_dec_lcs_client_type(), osmo_bssmap_le_ie_dec_lcs_priority(), osmo_bssmap_le_ie_dec_lcs_qos(), osmo_bssmap_le_ie_dec_location_type(), and params.
Referenced by osmo_bssmap_le_dec().
|
static |
References BSSMAP_LE_IEI_GEO_LOCATION, BSSMAP_LE_IEI_LCS_CAUSE, DEC_IE_OPTIONAL, DEC_IE_OPTIONAL_FLAG, osmo_bssmap_le_ie_dec_gad(), osmo_lcs_cause_dec(), and params.
Referenced by osmo_bssmap_le_dec().
|
static |
References BSSMAP_LE_IEI_CAUSE, cause, DEC_ERR, gsm0808_get_cause(), LCS_CAUSE_DATA_MISSING_IN_REQ, LCS_CAUSE_UNSPECIFIED, and TLVP_GET.
Referenced by osmo_bssmap_le_dec().
|
static |
Encode BSSMAP-LE PDU and add to msgb (3GPP TS 49.031).
See also osmo_bssap_le_enc().
[out] | msg | msgb to append to. |
[in] | pdu | PDU data to encode. |
References BSSMAP_LE_MSGT_CONN_ORIENTED_INFO, BSSMAP_LE_MSGT_PERFORM_LOC_ABORT, BSSMAP_LE_MSGT_PERFORM_LOC_REQ, BSSMAP_LE_MSGT_PERFORM_LOC_RESP, BSSMAP_LE_MSGT_RESET, BSSMAP_LE_MSGT_RESET_ACK, bssmap_le_pdu::conn_oriented_info, ENOTSUP, msg, bssmap_le_pdu::msg_type, msgb_v_put(), osmo_bssmap_le_enc_conn_oriented_info(), osmo_bssmap_le_enc_perform_loc_abort(), osmo_bssmap_le_enc_perform_loc_req(), osmo_bssmap_le_enc_perform_loc_resp(), osmo_bssmap_le_enc_reset(), bssmap_le_pdu::perform_loc_abort, bssmap_le_pdu::perform_loc_req, bssmap_le_pdu::perform_loc_resp, and bssmap_le_pdu::reset.
Referenced by osmo_bssap_le_enc().
|
static |
References msg, osmo_bssmap_le_ie_enc_apdu(), and params.
Referenced by osmo_bssmap_le_enc().
|
static |
References BSSMAP_LE_IEI_LCS_CAUSE, l, msg, msgb_tl_put(), osmo_lcs_cause_enc(), and params.
Referenced by osmo_bssmap_le_enc().
|
static |
References BSSMAP_LE_IEI_IMEI, BSSMAP_LE_IEI_IMSI, gsm0808_enc_cell_id(), GSM_MI_TYPE_IMEI, GSM_MI_TYPE_IMSI, l, msg, msgb_tl_put(), osmo_bssmap_le_ie_enc_apdu(), osmo_bssmap_le_ie_enc_lcs_client_type(), osmo_bssmap_le_ie_enc_lcs_priority(), osmo_bssmap_le_ie_enc_lcs_qos(), osmo_bssmap_le_ie_enc_location_type(), osmo_mobile_identity_encode_msgb(), and params.
Referenced by osmo_bssmap_le_enc().
|
static |
References BSSMAP_LE_IEI_GEO_LOCATION, BSSMAP_LE_IEI_LCS_CAUSE, l, msg, msgb_tl_put(), osmo_gad_raw_write(), osmo_lcs_cause_enc(), and params.
Referenced by osmo_bssmap_le_enc().
|
static |
References cause, gsm0808_enc_cause(), and msg.
Referenced by osmo_bssmap_le_enc().
|
static |
References BSSMAP_LE_APDU_PROT_BSSLAP, BSSMAP_LE_APDU_PROT_LLP, BSSMAP_LE_APDU_PROT_SMLCPP, data, DEC_ERR, DEC_ERR_NO_RETURN, iei, LCS_CAUSE_UNSPECIFIED, len, osmo_bsslap_err::logmsg, osmo_bsslap_dec(), proto, and osmo_bsslap_err::rc.
Referenced by osmo_bssmap_le_dec_conn_oriented_info(), and osmo_bssmap_le_dec_perform_loc_req().
|
static |
References DEC_ERR, gsm0808_dec_cell_id(), iei, LCS_CAUSE_UNSPECIFIED, len, osmo_hexdump_c(), and osmo_bsslap_err::rc.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References BSSMAP_LE_IEI_GEO_LOCATION, DEC_ERR_NO_RETURN, LCS_CAUSE_UNSPECIFIED, len, osmo_gad_err::logmsg, osmo_gad_raw_read(), and osmo_gad_err::rc.
Referenced by osmo_bssmap_le_dec_perform_loc_resp().
|
static |
References DEC_ERR, GSM_MI_TYPE_IMEI, iei, LCS_CAUSE_UNSPECIFIED, len, osmo_hexdump_c(), osmo_mobile_identity_decode(), and osmo_bsslap_err::rc.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References DEC_ERR, GSM_MI_TYPE_IMSI, iei, LCS_CAUSE_UNSPECIFIED, len, osmo_hexdump_c(), osmo_mobile_identity_decode(), and osmo_bsslap_err::rc.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References BSSMAP_LE_LCS_CTYPE_EMERG_SVC_UNSPECIFIED, BSSMAP_LE_LCS_CTYPE_LI_UNSPECIFIED, BSSMAP_LE_LCS_CTYPE_PLMN_OPER_ANON_STATS, BSSMAP_LE_LCS_CTYPE_PLMN_OPER_BCAST_SERVICE, BSSMAP_LE_LCS_CTYPE_PLMN_OPER_OAM, BSSMAP_LE_LCS_CTYPE_PLMN_OPER_TGT_MS_SVC, BSSMAP_LE_LCS_CTYPE_PLMN_OPER_UNSPECIFIED, BSSMAP_LE_LCS_CTYPE_VALUE_ADDED_UNSPECIFIED, DEC_ERR, iei, LCS_CAUSE_UNSPECIFIED, and len.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References DEC_ERR, iei, LCS_CAUSE_UNSPECIFIED, and len.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References DEC_ERR, iei, LCS_CAUSE_UNSPECIFIED, and len.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
int osmo_bssmap_le_ie_dec_location_type | ( | struct bssmap_le_location_type * | lt, |
enum bssmap_le_msgt | msgt, | ||
enum bssmap_le_iei | iei, | ||
struct osmo_bssmap_le_err ** | err, | ||
void * | err_ctx, | ||
const uint8_t * | elem, | ||
uint8_t | len | ||
) |
Decode BSSMAP-LE Location Type IE value part.
[out] | lt | Buffer to write decoded values to. |
[in] | elem | Pointer to the value part, the V of a TLV. |
[in] | len | Length, the L of a TLV. |
References BSSMAP_LE_LOC_INFO_ASSIST_TARGET_MS, BSSMAP_LE_LOC_INFO_BC_DECIPHER_KEYS, BSSMAP_LE_LOC_INFO_CURRENT_GEOGRAPHIC, BSSMAP_LE_POS_METHOD_ASSISTED_GPS, BSSMAP_LE_POS_METHOD_MOBILE_ASSISTED_E_OTD, BSSMAP_LE_POS_METHOD_MOBILE_BASED_E_OTD, BSSMAP_LE_POS_METHOD_OMITTED, DEC_ERR, iei, LCS_CAUSE_UNSPECIFIED, len, bssmap_le_location_type::location_information, and bssmap_le_location_type::positioning_method.
Referenced by osmo_bssmap_le_dec_perform_loc_req().
|
static |
References BSSMAP_LE_APDU_PROT_BSSLAP, BSSMAP_LE_IEI_APDU, l, msg, msgb_put(), msgb_put_u8(), and osmo_bsslap_enc().
Referenced by osmo_bssmap_le_enc_conn_oriented_info(), and osmo_bssmap_le_enc_perform_loc_req().
|
static |
Encode full BSSMAP-LE LCS Client Type IE, including IEI tag and length.
[in,out] | msg | Message buffer to append to. |
[in] | client_type | Value to enconde. |
References BSSMAP_LE_IEI_LCS_CLIENT_TYPE, msg, msgb_put_u8(), and OSMO_ASSERT.
Referenced by osmo_bssmap_le_enc_perform_loc_req().
|
static |
Encode full BSSMAP-LE LCS Priority IE, including IEI tag and length.
[in,out] | msg | Message buffer to append to. |
[in] | priority | Value to enconde. |
References BSSMAP_LE_IEI_LCS_PRIORITY, msg, msgb_put_u8(), and OSMO_ASSERT.
Referenced by osmo_bssmap_le_enc_perform_loc_req().
|
static |
Encode full BSSMAP-LE LCS QoS IE, including IEI tag and length.
[in,out] | msg | Message buffer to append to. |
[in] | priority | Value to enconde. |
References BSSMAP_LE_IEI_LCS_QoS, msg, msgb_tlv_put(), and OSMO_ASSERT.
Referenced by osmo_bssmap_le_enc_perform_loc_req().
uint8_t osmo_bssmap_le_ie_enc_location_type | ( | struct msgb * | msg, |
const struct bssmap_le_location_type * | location_type | ||
) |
Encode full BSSMAP-LE Location Type IE, including IEI tag and length.
[in,out] | msg | Message buffer to append to. |
[in] | location_type | Values to enconde. |
References BSSMAP_LE_IEI_LOCATION_TYPE, BSSMAP_LE_LOC_INFO_ASSIST_TARGET_MS, BSSMAP_LE_LOC_INFO_BC_DECIPHER_KEYS, bssmap_le_location_type::location_information, msg, msgb_put(), msgb_put_u8(), OSMO_ASSERT, and bssmap_le_location_type::positioning_method.
Referenced by gsm0808_create_perform_location_request(), and osmo_bssmap_le_enc_perform_loc_req().
|
inlinestatic |
References get_value_string(), and osmo_bssmap_le_iei_names.
enum bssmap_le_msgt osmo_bssmap_le_msgt | ( | const uint8_t * | data, |
uint8_t | len | ||
) |
Return the BSSMAP-LE msg_type from a BSSAP-LE PDU, e.g.
from a msgb_l3().
[in] | data | BSSAP-LE PDU data, starting with BSSAP-LE discriminator. |
[in] | len | Length of data in bytes. |
References BSSAP_LE_MSG_DISCR_BSSMAP_LE, data, h, and len.
|
inlinestatic |
References get_value_string(), and osmo_bssmap_le_msgt_names.
Referenced by osmo_bssap_le_enc(), and osmo_bssap_le_pdu_to_str_buf().
int osmo_lcs_cause_dec | ( | struct lcs_cause_ie * | lcs_cause, |
enum bssmap_le_msgt | msgt, | ||
enum bssmap_le_iei | iei, | ||
struct osmo_bssmap_le_err ** | err, | ||
void * | err_ctx, | ||
const uint8_t * | data, | ||
uint8_t | len | ||
) |
Decode the value part of 3GPP TS 49.031 10.13 LCS Cause, without IEI and len.
Identically used in 3GPP TS 48.008 3.2.2.66.
[out] | lcs_cause | Write decoded LCS Cause values here. |
[in] | data | Encoded cause bytes. |
[in] | len | Length of data in bytes. |
References data, DEC_ERR, iei, LCS_CAUSE_UNSPECIFIED, and len.
Referenced by osmo_bssmap_le_dec_perform_loc_abort(), and osmo_bssmap_le_dec_perform_loc_resp().
int osmo_lcs_cause_enc | ( | struct msgb * | msg, |
const struct lcs_cause_ie * | lcs_cause | ||
) |
Encode the value part of 3GPP TS 49.031 10.13 LCS Cause, without IEI and len.
Identically used in 3GPP TS 48.008 3.2.2.66. Usage example:
uint8_t *l = msgb_tl_put(msg, BSSMAP_LE_IEI_LCS_CAUSE); int rc = osmo_lcs_cause_enc(msg, &lcs_cause); if (rc < 0) goto error; *l = rc;
[in,out] | msg | Message buffer to append the LCS Cause values to. |
[in] | lcs_cause | LCS Cause values to enconde. |
References LCS_CAUSE_POS_METH_FAILURE, msg, and msgb_put_u8().
Referenced by gsm0808_create_perform_location_response(), gsm0808_enc_lcs_cause(), osmo_bssmap_le_enc_perform_loc_abort(), and osmo_bssmap_le_enc_perform_loc_resp().
enum bssap_le_msg_discr __attribute__ |
|
extern |
Referenced by osmo_bssmap_le_iei_name().
const struct value_string osmo_bssmap_le_iei_names[] |
Referenced by osmo_bssmap_le_iei_name().
|
extern |
Referenced by osmo_bssmap_le_msgt_name().
const struct value_string osmo_bssmap_le_msgt_names[] |
Referenced by osmo_bssmap_le_msgt_name().
|
static |
Referenced by osmo_bssmap_le_dec().