libosmogsm
0.9.3
Osmocom GSM library
|
00001 #pragma once 00002 00003 /* GSM Radio Signalling Link messages on the A-bis interface 00004 * 3GPP TS 08.58 version 8.6.0 Release 1999 / ETSI TS 100 596 V8.6.0 */ 00005 00006 /* (C) 2008 by Harald Welte <laforge@gnumonks.org> 00007 * All Rights Reserved 00008 * 00009 * This program is free software; you can redistribute it and/or modify 00010 * it under the terms of the GNU General Public License as published by 00011 * the Free Software Foundation; either version 2 of the License, or 00012 * (at your option) any later version. 00013 * 00014 * This program is distributed in the hope that it will be useful, 00015 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00017 * GNU General Public License for more details. 00018 * 00019 * You should have received a copy of the GNU General Public License along 00020 * with this program; if not, write to the Free Software Foundation, Inc., 00021 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 00022 * 00023 */ 00024 00025 #include <stdint.h> 00026 00034 struct abis_rsl_common_hdr { 00035 uint8_t msg_discr; 00036 uint8_t msg_type; 00037 uint8_t data[0]; 00038 } __attribute__ ((packed)); 00039 00040 /* \brief RSL RLL header (Chapter 8.3) */ 00041 struct abis_rsl_rll_hdr { 00042 struct abis_rsl_common_hdr c; 00043 uint8_t ie_chan; 00044 uint8_t chan_nr; 00045 uint8_t ie_link_id; 00046 uint8_t link_id; 00047 uint8_t data[0]; 00048 } __attribute__ ((packed)); 00049 00050 /* \brief RSL Dedicated Channel header (Chapter 8.3 and 8.4) */ 00051 struct abis_rsl_dchan_hdr { 00052 struct abis_rsl_common_hdr c; 00053 uint8_t ie_chan; 00054 uint8_t chan_nr; 00055 uint8_t data[0]; 00056 } __attribute__ ((packed)); 00057 00058 /* \brief RSL Common Channel header (Chapter 8.5) */ 00059 struct abis_rsl_cchan_hdr { 00060 struct abis_rsl_common_hdr c; 00061 uint8_t ie_chan; 00062 uint8_t chan_nr; 00063 uint8_t data[0]; 00064 } __attribute__ ((packed)); 00065 00066 00067 /* Chapter 9.1 */ 00068 /* \brief RSL Message Discriminator: RLL */ 00069 #define ABIS_RSL_MDISC_RLL 0x02 00070 /* \brief RSL Message Discriminator: Dedicated Channel */ 00071 #define ABIS_RSL_MDISC_DED_CHAN 0x08 00072 /* \brief RSL Message Discriminator: Common Channel */ 00073 #define ABIS_RSL_MDISC_COM_CHAN 0x0c 00074 /* \brief RSL Message Discriminator: TRX Management */ 00075 #define ABIS_RSL_MDISC_TRX 0x10 00076 /* \brief RSL Message Discriminator: Location Service */ 00077 #define ABIS_RSL_MDISC_LOC 0x20 00078 /* \brief RSL Message Discriminator: ip.access */ 00079 #define ABIS_RSL_MDISC_IPACCESS 0x7e 00080 #define ABIS_RSL_MDISC_TRANSP 0x01 00081 00082 /* \brief Check if given RSL message discriminator is transparent */ 00083 #define ABIS_RSL_MDISC_IS_TRANSP(x) (x & 0x01) 00084 00085 /* \brief RSL Message Tyoe (Chapter 9.1) */ 00086 enum abis_rsl_msgtype { 00087 /* Radio Link Layer Management */ 00088 RSL_MT_DATA_REQ = 0x01, 00089 RSL_MT_DATA_IND, 00090 RSL_MT_ERROR_IND, 00091 RSL_MT_EST_REQ, 00092 RSL_MT_EST_CONF, 00093 RSL_MT_EST_IND, 00094 RSL_MT_REL_REQ, 00095 RSL_MT_REL_CONF, 00096 RSL_MT_REL_IND, 00097 RSL_MT_UNIT_DATA_REQ, 00098 RSL_MT_UNIT_DATA_IND, /* 0x0b */ 00099 RSL_MT_SUSP_REQ, /* non-standard elements */ 00100 RSL_MT_SUSP_CONF, 00101 RSL_MT_RES_REQ, 00102 RSL_MT_RECON_REQ, /* 0x0f */ 00103 00104 /* Common Channel Management / TRX Management */ 00105 RSL_MT_BCCH_INFO = 0x11, 00106 RSL_MT_CCCH_LOAD_IND, 00107 RSL_MT_CHAN_RQD, 00108 RSL_MT_DELETE_IND, 00109 RSL_MT_PAGING_CMD, 00110 RSL_MT_IMMEDIATE_ASSIGN_CMD, 00111 RSL_MT_SMS_BC_REQ, 00112 RSL_MT_CHAN_CONF, /* non-standard element */ 00113 /* empty */ 00114 RSL_MT_RF_RES_IND = 0x19, 00115 RSL_MT_SACCH_FILL, 00116 RSL_MT_OVERLOAD, 00117 RSL_MT_ERROR_REPORT, 00118 RSL_MT_SMS_BC_CMD, 00119 RSL_MT_CBCH_LOAD_IND, 00120 RSL_MT_NOT_CMD, /* 0x1f */ 00121 00122 /* Dedicate Channel Management */ 00123 RSL_MT_CHAN_ACTIV = 0x21, 00124 RSL_MT_CHAN_ACTIV_ACK, 00125 RSL_MT_CHAN_ACTIV_NACK, 00126 RSL_MT_CONN_FAIL, 00127 RSL_MT_DEACTIVATE_SACCH, 00128 RSL_MT_ENCR_CMD, 00129 RSL_MT_HANDO_DET, 00130 RSL_MT_MEAS_RES, 00131 RSL_MT_MODE_MODIFY_REQ, 00132 RSL_MT_MODE_MODIFY_ACK, 00133 RSL_MT_MODE_MODIFY_NACK, 00134 RSL_MT_PHY_CONTEXT_REQ, 00135 RSL_MT_PHY_CONTEXT_CONF, 00136 RSL_MT_RF_CHAN_REL, 00137 RSL_MT_MS_POWER_CONTROL, 00138 RSL_MT_BS_POWER_CONTROL, /* 0x30 */ 00139 RSL_MT_PREPROC_CONFIG, 00140 RSL_MT_PREPROC_MEAS_RES, 00141 RSL_MT_RF_CHAN_REL_ACK, 00142 RSL_MT_SACCH_INFO_MODIFY, 00143 RSL_MT_TALKER_DET, 00144 RSL_MT_LISTENER_DET, 00145 RSL_MT_REMOTE_CODEC_CONF_REP, 00146 RSL_MT_RTD_REP, 00147 RSL_MT_PRE_HANDO_NOTIF, 00148 RSL_MT_MR_CODEC_MOD_REQ, 00149 RSL_MT_MR_CODEC_MOD_ACK, 00150 RSL_MT_MR_CODEC_MOD_NACK, 00151 RSL_MT_MR_CODEC_MOD_PER, 00152 RSL_MT_TFO_REP, 00153 RSL_MT_TFO_MOD_REQ, /* 0x3f */ 00154 RSL_MT_LOCATION_INFO = 0x41, 00155 00156 /* ip.access specific RSL message types */ 00157 RSL_MT_IPAC_DIR_RETR_ENQ = 0x40, 00158 RSL_MT_IPAC_PDCH_ACT = 0x48, 00159 RSL_MT_IPAC_PDCH_ACT_ACK, 00160 RSL_MT_IPAC_PDCH_ACT_NACK, 00161 RSL_MT_IPAC_PDCH_DEACT = 0x4b, 00162 RSL_MT_IPAC_PDCH_DEACT_ACK, 00163 RSL_MT_IPAC_PDCH_DEACT_NACK, 00164 RSL_MT_IPAC_CONNECT_MUX = 0x50, 00165 RSL_MT_IPAC_CONNECT_MUX_ACK, 00166 RSL_MT_IPAC_CONNECT_MUX_NACK, 00167 RSL_MT_IPAC_BIND_MUX = 0x53, 00168 RSL_MT_IPAC_BIND_MUX_ACK, 00169 RSL_MT_IPAC_BIND_MUX_NACK, 00170 RSL_MT_IPAC_DISC_MUX = 0x56, 00171 RSL_MT_IPAC_DISC_MUX_ACK, 00172 RSL_MT_IPAC_DISC_MUX_NACK, 00173 RSL_MT_IPAC_CRCX = 0x70, /* Bind to local BTS RTP port */ 00174 RSL_MT_IPAC_CRCX_ACK, 00175 RSL_MT_IPAC_CRCX_NACK, 00176 RSL_MT_IPAC_MDCX = 0x73, 00177 RSL_MT_IPAC_MDCX_ACK, 00178 RSL_MT_IPAC_MDCX_NACK, 00179 RSL_MT_IPAC_DLCX_IND = 0x76, 00180 RSL_MT_IPAC_DLCX = 0x77, 00181 RSL_MT_IPAC_DLCX_ACK, 00182 RSL_MT_IPAC_DLCX_NACK, 00183 }; 00184 00186 enum abis_rsl_msgtype_siemens { 00187 RSL_MT_SIEMENS_MRPCI = 0x41, 00188 RSL_MT_SIEMENS_INTRAC_HO_COND_IND = 0x42, 00189 RSL_MT_SIEMENS_INTERC_HO_COND_IND = 0x43, 00190 RSL_MT_SIEMENS_FORCED_HO_REQ = 0x44, 00191 RSL_MT_SIEMENS_PREF_AREA_REQ = 0x45, 00192 RSL_MT_SIEMENS_PREF_AREA = 0x46, 00193 RSL_MT_SIEMENS_START_TRACE = 0x47, 00194 RSL_MT_SIEMENS_START_TRACE_ACK = 0x48, 00195 RSL_MT_SIEMENS_STOP_TRACE = 0x49, 00196 RSL_MT_SIEMENS_TRMR = 0x4a, 00197 RSL_MT_SIEMENS_HO_FAIL_IND = 0x4b, 00198 RSL_MT_SIEMENS_STOP_TRACE_ACK = 0x4c, 00199 RSL_MT_SIEMENS_UPLF = 0x4d, 00200 RSL_MT_SIEMENS_UPLB = 0x4e, 00201 RSL_MT_SIEMENS_SET_SYS_INFO_10 = 0x4f, 00202 RSL_MT_SIEMENS_MODIF_COND_IND = 0x50, 00203 }; 00204 00206 enum abis_rsl_ie { 00207 RSL_IE_CHAN_NR = 0x01, 00208 RSL_IE_LINK_IDENT, 00209 RSL_IE_ACT_TYPE, 00210 RSL_IE_BS_POWER, 00211 RSL_IE_CHAN_IDENT, 00212 RSL_IE_CHAN_MODE, 00213 RSL_IE_ENCR_INFO, 00214 RSL_IE_FRAME_NUMBER, 00215 RSL_IE_HANDO_REF, 00216 RSL_IE_L1_INFO, 00217 RSL_IE_L3_INFO, 00218 RSL_IE_MS_IDENTITY, 00219 RSL_IE_MS_POWER, 00220 RSL_IE_PAGING_GROUP, 00221 RSL_IE_PAGING_LOAD, 00222 RSL_IE_PYHS_CONTEXT = 0x10, 00223 RSL_IE_ACCESS_DELAY, 00224 RSL_IE_RACH_LOAD, 00225 RSL_IE_REQ_REFERENCE, 00226 RSL_IE_RELEASE_MODE, 00227 RSL_IE_RESOURCE_INFO, 00228 RSL_IE_RLM_CAUSE, 00229 RSL_IE_STARTNG_TIME, 00230 RSL_IE_TIMING_ADVANCE, 00231 RSL_IE_UPLINK_MEAS, 00232 RSL_IE_CAUSE, 00233 RSL_IE_MEAS_RES_NR, 00234 RSL_IE_MSG_ID, 00235 /* reserved */ 00236 RSL_IE_SYSINFO_TYPE = 0x1e, 00237 RSL_IE_MS_POWER_PARAM, 00238 RSL_IE_BS_POWER_PARAM, 00239 RSL_IE_PREPROC_PARAM, 00240 RSL_IE_PREPROC_MEAS, 00241 RSL_IE_IMM_ASS_INFO, /* Phase 1 (3.6.0), later Full below */ 00242 RSL_IE_SMSCB_INFO = 0x24, 00243 RSL_IE_MS_TIMING_OFFSET, 00244 RSL_IE_ERR_MSG, 00245 RSL_IE_FULL_BCCH_INFO, 00246 RSL_IE_CHAN_NEEDED, 00247 RSL_IE_CB_CMD_TYPE, 00248 RSL_IE_SMSCB_MSG, 00249 RSL_IE_FULL_IMM_ASS_INFO, 00250 RSL_IE_SACCH_INFO, 00251 RSL_IE_CBCH_LOAD_INFO, 00252 RSL_IE_SMSCB_CHAN_INDICATOR, 00253 RSL_IE_GROUP_CALL_REF, 00254 RSL_IE_CHAN_DESC = 0x30, 00255 RSL_IE_NCH_DRX_INFO, 00256 RSL_IE_CMD_INDICATOR, 00257 RSL_IE_EMLPP_PRIO, 00258 RSL_IE_UIC, 00259 RSL_IE_MAIN_CHAN_REF, 00260 RSL_IE_MR_CONFIG, 00261 RSL_IE_MR_CONTROL, 00262 RSL_IE_SUP_CODEC_TYPES, 00263 RSL_IE_CODEC_CONFIG, 00264 RSL_IE_RTD, 00265 RSL_IE_TFO_STATUS, 00266 RSL_IE_LLP_APDU, 00267 /* Siemens vendor-specific */ 00268 RSL_IE_SIEMENS_MRPCI = 0x40, 00269 RSL_IE_SIEMENS_PREF_AREA_TYPE = 0x43, 00270 RSL_IE_SIEMENS_ININ_CELL_HO_PAR = 0x45, 00271 RSL_IE_SIEMENS_TRACE_REF_NR = 0x46, 00272 RSL_IE_SIEMENS_INT_TRACE_IDX = 0x47, 00273 RSL_IE_SIEMENS_L2_HDR_INFO = 0x48, 00274 RSL_IE_SIEMENS_HIGHEST_RATE = 0x4e, 00275 RSL_IE_SIEMENS_SUGGESTED_RATE = 0x4f, 00276 00277 /* ip.access */ 00278 RSL_IE_IPAC_SRTP_CONFIG = 0xe0, 00279 RSL_IE_IPAC_PROXY_UDP = 0xe1, 00280 RSL_IE_IPAC_BSCMPL_TOUT = 0xe2, 00281 RSL_IE_IPAC_REMOTE_IP = 0xf0, 00282 RSL_IE_IPAC_REMOTE_PORT = 0xf1, 00283 RSL_IE_IPAC_RTP_PAYLOAD = 0xf2, 00284 RSL_IE_IPAC_LOCAL_PORT = 0xf3, 00285 RSL_IE_IPAC_SPEECH_MODE = 0xf4, 00286 RSL_IE_IPAC_LOCAL_IP = 0xf5, 00287 RSL_IE_IPAC_CONN_STAT = 0xf6, 00288 RSL_IE_IPAC_HO_C_PARMS = 0xf7, 00289 RSL_IE_IPAC_CONN_ID = 0xf8, 00290 RSL_IE_IPAC_RTP_CSD_FMT = 0xf9, 00291 RSL_IE_IPAC_RTP_JIT_BUF = 0xfa, 00292 RSL_IE_IPAC_RTP_COMPR = 0xfb, 00293 RSL_IE_IPAC_RTP_PAYLOAD2= 0xfc, 00294 RSL_IE_IPAC_RTP_MPLEX = 0xfd, 00295 RSL_IE_IPAC_RTP_MPLEX_ID= 0xfe, 00296 }; 00297 00298 /* Chapter 9.3.1 */ 00299 #define RSL_CHAN_NR_MASK 0xf8 00300 #define RSL_CHAN_Bm_ACCHs 0x08 00301 #define RSL_CHAN_Lm_ACCHs 0x10 /* .. 0x18 */ 00302 #define RSL_CHAN_SDCCH4_ACCH 0x20 /* .. 0x38 */ 00303 #define RSL_CHAN_SDCCH8_ACCH 0x40 /* ...0x78 */ 00304 #define RSL_CHAN_BCCH 0x80 00305 #define RSL_CHAN_RACH 0x88 00306 #define RSL_CHAN_PCH_AGCH 0x90 00307 00308 /* Chapter 9.3.3 */ 00309 #define RSL_ACT_TYPE_INITIAL 0x00 00310 #define RSL_ACT_TYPE_REACT 0x80 00311 #define RSL_ACT_INTRA_IMM_ASS 0x00 00312 #define RSL_ACT_INTRA_NORM_ASS 0x01 00313 #define RSL_ACT_INTER_ASYNC 0x02 00314 #define RSL_ACT_INTER_SYNC 0x03 00315 #define RSL_ACT_SECOND_ADD 0x04 00316 #define RSL_ACT_SECOND_MULTI 0x05 00317 00319 struct rsl_ie_chan_mode { 00320 uint8_t dtx_dtu; 00321 uint8_t spd_ind; 00322 uint8_t chan_rt; 00323 uint8_t chan_rate; 00324 } __attribute__ ((packed)); 00325 #define RSL_CMOD_DTXu 0x01 /* uplink */ 00326 #define RSL_CMOD_DTXd 0x02 /* downlink */ 00327 enum rsl_cmod_spd { 00328 RSL_CMOD_SPD_SPEECH = 0x01, 00329 RSL_CMOD_SPD_DATA = 0x02, 00330 RSL_CMOD_SPD_SIGN = 0x03, 00331 }; 00332 #define RSL_CMOD_CRT_SDCCH 0x01 00333 #define RSL_CMOD_CRT_TCH_Bm 0x08 /* full-rate */ 00334 #define RSL_CMOD_CRT_TCH_Lm 0x09 /* half-rate */ 00335 /* FIXME: More CRT types */ 00336 /* Speech */ 00337 #define RSL_CMOD_SP_GSM1 0x01 00338 #define RSL_CMOD_SP_GSM2 0x11 00339 #define RSL_CMOD_SP_GSM3 0x21 00340 /* non-transparent data */ 00341 #define RSL_CMOD_CSD_NT_43k5 0x74 00342 #define RSL_CMOD_CSD_NT_28k8 0x71 00343 #define RSL_CMOD_CSD_NT_14k5 0x58 00344 #define RSL_CMOD_CSD_NT_12k0 0x50 00345 #define RSL_CMOD_CSD_NT_6k0 0x51 00346 /* legacy #defines with wrong name */ 00347 #define RSL_CMOD_SP_NT_14k5 RSL_CMOD_CSD_NT_14k5 00348 #define RSL_CMOD_SP_NT_12k0 RSL_CMOD_CSD_NT_12k0 00349 #define RSL_CMOD_SP_NT_6k0 RSL_CMOD_CSD_NT_6k0 00350 /* transparent data */ 00351 #define RSL_CMOD_CSD_T_32000 0x38 00352 #define RSL_CMOD_CSD_T_29000 0x39 00353 #define RSL_CMOD_CSD_T_14400 0x18 00354 #define RSL_CMOD_CSD_T_9600 0x10 00355 #define RSL_CMOD_CSD_T_4800 0x11 00356 #define RSL_CMOD_CSD_T_2400 0x12 00357 #define RSL_CMOD_CSD_T_1200 0x13 00358 #define RSL_CMOD_CSD_T_600 0x14 00359 #define RSL_CMOD_CSD_T_1200_75 0x15 00360 00362 struct rsl_ie_chan_ident { 00363 /* GSM 04.08 10.5.2.5 */ 00364 struct { 00365 uint8_t iei; 00366 uint8_t chan_nr; /* enc_chan_nr */ 00367 uint8_t oct3; 00368 uint8_t oct4; 00369 } chan_desc; 00370 #if 0 /* spec says we need this but Abissim doesn't use it */ 00371 struct { 00372 uint8_t tag; 00373 uint8_t len; 00374 } mobile_alloc; 00375 #endif 00376 } __attribute__ ((packed)); 00377 00378 /* Chapter 9.3.22 */ 00379 #define RLL_CAUSE_T200_EXPIRED 0x01 00380 #define RLL_CAUSE_REEST_REQ 0x02 00381 #define RLL_CAUSE_UNSOL_UA_RESP 0x03 00382 #define RLL_CAUSE_UNSOL_DM_RESP 0x04 00383 #define RLL_CAUSE_UNSOL_DM_RESP_MF 0x05 00384 #define RLL_CAUSE_UNSOL_SPRV_RESP 0x06 00385 #define RLL_CAUSE_SEQ_ERR 0x07 00386 #define RLL_CAUSE_UFRM_INC_PARAM 0x08 00387 #define RLL_CAUSE_SFRM_INC_PARAM 0x09 00388 #define RLL_CAUSE_IFRM_INC_MBITS 0x0a 00389 #define RLL_CAUSE_IFRM_INC_LEN 0x0b 00390 #define RLL_CAUSE_FRM_UNIMPL 0x0c 00391 #define RLL_CAUSE_SABM_MF 0x0d 00392 #define RLL_CAUSE_SABM_INFO_NOTALL 0x0e 00393 00394 /* Chapter 9.3.26 */ 00395 #define RSL_ERRCLS_NORMAL 0x00 00396 #define RSL_ERRCLS_RESOURCE_UNAVAIL 0x20 00397 #define RSL_ERRCLS_SERVICE_UNAVAIL 0x30 00398 #define RSL_ERRCLS_SERVICE_UNIMPL 0x40 00399 #define RSL_ERRCLS_INVAL_MSG 0x50 00400 #define RSL_ERRCLS_PROTO_ERROR 0x60 00401 #define RSL_ERRCLS_INTERWORKING 0x70 00402 00403 /* normal event */ 00404 #define RSL_ERR_RADIO_IF_FAIL 0x00 00405 #define RSL_ERR_RADIO_LINK_FAIL 0x01 00406 #define RSL_ERR_HANDOVER_ACC_FAIL 0x02 00407 #define RSL_ERR_TALKER_ACC_FAIL 0x03 00408 #define RSL_ERR_OM_INTERVENTION 0x07 00409 #define RSL_ERR_NORMAL_UNSPEC 0x0f 00410 #define RSL_ERR_T_MSRFPCI_EXP 0x18 00411 /* resource unavailable */ 00412 #define RSL_ERR_EQUIPMENT_FAIL 0x20 00413 #define RSL_ERR_RR_UNAVAIL 0x21 00414 #define RSL_ERR_TERR_CH_FAIL 0x22 00415 #define RSL_ERR_CCCH_OVERLOAD 0x23 00416 #define RSL_ERR_ACCH_OVERLOAD 0x24 00417 #define RSL_ERR_PROCESSOR_OVERLOAD 0x25 00418 #define RSL_ERR_RES_UNAVAIL 0x2f 00419 /* service or option not available */ 00420 #define RSL_ERR_TRANSC_UNAVAIL 0x30 00421 #define RSL_ERR_SERV_OPT_UNAVAIL 0x3f 00422 /* service or option not implemented */ 00423 #define RSL_ERR_ENCR_UNIMPL 0x40 00424 #define RSL_ERR_SERV_OPT_UNIMPL 0x4f 00425 /* invalid message */ 00426 #define RSL_ERR_RCH_ALR_ACTV_ALLOC 0x50 00427 #define RSL_ERR_INVALID_MESSAGE 0x5f 00428 /* protocol error */ 00429 #define RSL_ERR_MSG_DISCR 0x60 00430 #define RSL_ERR_MSG_TYPE 0x61 00431 #define RSL_ERR_MSG_SEQ 0x62 00432 #define RSL_ERR_IE_ERROR 0x63 00433 #define RSL_ERR_MAND_IE_ERROR 0x64 00434 #define RSL_ERR_OPT_IE_ERROR 0x65 00435 #define RSL_ERR_IE_NONEXIST 0x66 00436 #define RSL_ERR_IE_LENGTH 0x67 00437 #define RSL_ERR_IE_CONTENT 0x68 00438 #define RSL_ERR_PROTO 0x6f 00439 /* interworking */ 00440 #define RSL_ERR_INTERWORKING 0x7f 00441 00442 /* Chapter 9.3.30 */ 00443 #define RSL_SYSTEM_INFO_8 0x00 00444 #define RSL_SYSTEM_INFO_1 0x01 00445 #define RSL_SYSTEM_INFO_2 0x02 00446 #define RSL_SYSTEM_INFO_3 0x03 00447 #define RSL_SYSTEM_INFO_4 0x04 00448 #define RSL_SYSTEM_INFO_5 0x05 00449 #define RSL_SYSTEM_INFO_6 0x06 00450 #define RSL_SYSTEM_INFO_7 0x07 00451 #define RSL_SYSTEM_INFO_16 0x08 00452 #define RSL_SYSTEM_INFO_17 0x09 00453 #define RSL_SYSTEM_INFO_2bis 0x0a 00454 #define RSL_SYSTEM_INFO_2ter 0x0b 00455 #define RSL_SYSTEM_INFO_5bis 0x0d 00456 #define RSL_SYSTEM_INFO_5ter 0x0e 00457 #define RSL_SYSTEM_INFO_10 0x0f 00458 #define RSL_EXT_MEAS_ORDER 0x47 00459 #define RSL_MEAS_INFO 0x48 00460 #define RSL_SYSTEM_INFO_13 0x28 00461 #define RSL_SYSTEM_INFO_2quater 0x29 00462 #define RSL_SYSTEM_INFO_9 0x2a 00463 #define RSL_SYSTEM_INFO_18 0x2b 00464 #define RSL_SYSTEM_INFO_19 0x2c 00465 #define RSL_SYSTEM_INFO_20 0x2d 00466 00467 /* Chapter 9.3.40 */ 00468 #define RSL_CHANNEED_ANY 0x00 00469 #define RSL_CHANNEED_SDCCH 0x01 00470 #define RSL_CHANNEED_TCH_F 0x02 00471 #define RSL_CHANNEED_TCH_ForH 0x03 00472 00474 struct rsl_ie_cb_cmd_type { 00475 uint8_t last_block:2; 00476 uint8_t spare:1; 00477 uint8_t def_bcast:1; 00478 uint8_t command:4; 00479 } __attribute__ ((packed)); 00480 /* ->command */ 00481 #define RSL_CB_CMD_TYPE_NORMAL 0x00 00482 #define RSL_CB_CMD_TYPE_SCHEDULE 0x08 00483 #define RSL_CB_CMD_TYPE_DEFAULT 0x0e 00484 #define RSL_CB_CMD_TYPE_NULL 0x0f 00485 /* ->def_bcast */ 00486 #define RSL_CB_CMD_DEFBCAST_NORMAL 0 00487 #define RSL_CB_CMD_DEFBCAST_NULL 1 00488 /* ->last_block */ 00489 #define RSL_CB_CMD_LASTBLOCK_4 0 00490 #define RSL_CB_CMD_LASTBLOCK_1 1 00491 #define RSL_CB_CMD_LASTBLOCK_2 2 00492 #define RSL_CB_CMD_LASTBLOCK_3 3 00493 00494 /* Chapter 3.3.2.3 Brocast control channel */ 00495 /* CCCH-CONF, NC is not combined */ 00496 #define RSL_BCCH_CCCH_CONF_1_NC 0x00 00497 #define RSL_BCCH_CCCH_CONF_1_C 0x01 00498 #define RSL_BCCH_CCCH_CONF_2_NC 0x02 00499 #define RSL_BCCH_CCCH_CONF_3_NC 0x04 00500 #define RSL_BCCH_CCCH_CONF_4_NC 0x06 00501 00502 /* BS-PA-MFRMS */ 00503 #define RSL_BS_PA_MFRMS_2 0x00 00504 #define RSL_BS_PA_MFRMS_3 0x01 00505 #define RSL_BS_PA_MFRMS_4 0x02 00506 #define RSL_BS_PA_MFRMS_5 0x03 00507 #define RSL_BS_PA_MFRMS_6 0x04 00508 #define RSL_BS_PA_MFRMS_7 0x05 00509 #define RSL_BS_PA_MFRMS_8 0x06 00510 #define RSL_BS_PA_MFRMS_9 0x07 00511 00512 /* RSL_IE_IPAC_RTP_PAYLOAD[2] */ 00513 enum rsl_ipac_rtp_payload { 00514 RSL_IPAC_RTP_GSM = 1, 00515 RSL_IPAC_RTP_EFR, 00516 RSL_IPAC_RTP_AMR, 00517 RSL_IPAC_RTP_CSD, 00518 RSL_IPAC_RTP_MUX, 00519 }; 00520 00521 /* RSL_IE_IPAC_SPEECH_MODE, lower four bits */ 00522 enum rsl_ipac_speech_mode_s { 00523 RSL_IPAC_SPEECH_GSM_FR = 0, /* GSM FR (Type 1, FS) */ 00524 RSL_IPAC_SPEECH_GSM_EFR = 1, /* GSM EFR (Type 2, FS) */ 00525 RSL_IPAC_SPEECH_GSM_AMR_FR = 2, /* GSM AMR/FR (Type 3, FS) */ 00526 RSL_IPAC_SPEECH_GSM_HR = 3, /* GSM HR (Type 1, HS) */ 00527 RSL_IPAC_SPEECH_GSM_AMR_HR = 5, /* GSM AMR/hr (Type 3, HS) */ 00528 RSL_IPAC_SPEECH_AS_RTP = 0xf, /* As specified by RTP Payload IE */ 00529 }; 00530 /* RSL_IE_IPAC_SPEECH_MODE, upper four bits */ 00531 enum rsl_ipac_speech_mode_m { 00532 RSL_IPAC_SPEECH_M_RXTX = 0, /* Send and Receive */ 00533 RSL_IPAC_SPEECH_M_RX = 1, /* Receive only */ 00534 RSL_IPAC_SPEECH_M_TX = 2, /* Send only */ 00535 }; 00536 00537 /* RSL_IE_IPAC_RTP_CSD_FMT, lower four bits */ 00538 enum rsl_ipac_rtp_csd_format_d { 00539 RSL_IPAC_RTP_CSD_EXT_TRAU = 0, 00540 RSL_IPAC_RTP_CSD_NON_TRAU = 1, 00541 RSL_IPAC_RTP_CSD_TRAU_BTS = 2, 00542 RSL_IPAC_RTP_CSD_IWF_FREE = 3, 00543 }; 00544 /* RSL_IE_IPAC_RTP_CSD_FMT, upper four bits */ 00545 enum rsl_ipac_rtp_csd_format_ir { 00546 RSL_IPAC_RTP_CSD_IR_8k = 0, 00547 RSL_IPAC_RTP_CSD_IR_16k = 1, 00548 RSL_IPAC_RTP_CSD_IR_32k = 2, 00549 RSL_IPAC_RTP_CSD_IR_64k = 3, 00550 }; 00551 00552 /* Siemens vendor-specific RSL extensions */ 00553 struct rsl_mrpci { 00554 uint8_t power_class:3, 00555 vgcs_capable:1, 00556 vbs_capable:1, 00557 gsm_phase:2; 00558 } __attribute__ ((packed)); 00559 00560 enum rsl_mrpci_pwrclass { 00561 RSL_MRPCI_PWRC_1 = 0, 00562 RSL_MRPCI_PWRC_2 = 1, 00563 RSL_MRPCI_PWRC_3 = 2, 00564 RSL_MRPCI_PWRC_4 = 3, 00565 RSL_MRPCI_PWRC_5 = 4, 00566 }; 00567 enum rsl_mrpci_phase { 00568 RSL_MRPCI_PHASE_1 = 0, 00569 /* reserved */ 00570 RSL_MRPCI_PHASE_2 = 2, 00571 RSL_MRPCI_PHASE_2PLUS = 3, 00572 }; 00573 00574 /* 9.3.20 Release Mode */ 00575 enum rsl_rel_mode { 00576 RSL_REL_NORMAL = 0, 00577 RSL_REL_LOCAL_END = 1, 00578 }; 00579