Harald Welte | c436245 | 2010-03-22 22:25:13 +0800 | [diff] [blame] | 1 | #ifndef PROTO_GSM_12_21_H |
| 2 | #define PROTO_GSM_12_21_H |
| 3 | |
| 4 | /* GSM Network Management messages on the A-bis interface |
| 5 | * 3GPP TS 12.21 version 8.0.0 Release 1999 / ETSI TS 100 623 V8.0.0 */ |
| 6 | |
| 7 | /* (C) 2008-2009 by Harald Welte <laforge@gnumonks.org> |
| 8 | * All Rights Reserved |
| 9 | * |
| 10 | * This program is free software; you can redistribute it and/or modify |
| 11 | * it under the terms of the GNU General Public License as published by |
| 12 | * the Free Software Foundation; either version 2 of the License, or |
| 13 | * (at your option) any later version. |
| 14 | * |
| 15 | * This program is distributed in the hope that it will be useful, |
| 16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 18 | * GNU General Public License for more details. |
| 19 | * |
| 20 | * You should have received a copy of the GNU General Public License along |
| 21 | * with this program; if not, write to the Free Software Foundation, Inc., |
| 22 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 23 | * |
| 24 | */ |
| 25 | |
| 26 | #include <stdint.h> |
| 27 | #include <osmocore/tlv.h> |
| 28 | |
| 29 | /* generic header in front of every OML message according to TS 08.59 */ |
| 30 | struct abis_om_hdr { |
| 31 | uint8_t mdisc; |
| 32 | uint8_t placement; |
| 33 | uint8_t sequence; |
| 34 | uint8_t length; |
| 35 | uint8_t data[0]; |
| 36 | } __attribute__ ((packed)); |
| 37 | |
| 38 | #define ABIS_OM_MDISC_FOM 0x80 |
| 39 | #define ABIS_OM_MDISC_MMI 0x40 |
| 40 | #define ABIS_OM_MDISC_TRAU 0x20 |
| 41 | #define ABIS_OM_MDISC_MANUF 0x10 |
| 42 | #define ABIS_OM_PLACEMENT_ONLY 0x80 |
| 43 | #define ABIS_OM_PLACEMENT_FIRST 0x40 |
| 44 | #define ABIS_OM_PLACEMENT_MIDDLE 0x20 |
| 45 | #define ABIS_OM_PLACEMENT_LAST 0x10 |
| 46 | |
| 47 | struct abis_om_obj_inst { |
| 48 | uint8_t bts_nr; |
| 49 | uint8_t trx_nr; |
| 50 | uint8_t ts_nr; |
| 51 | } __attribute__ ((packed)); |
| 52 | |
| 53 | struct abis_om_fom_hdr { |
| 54 | uint8_t msg_type; |
| 55 | uint8_t obj_class; |
| 56 | struct abis_om_obj_inst obj_inst; |
| 57 | uint8_t data[0]; |
| 58 | } __attribute__ ((packed)); |
| 59 | |
| 60 | #define ABIS_OM_FOM_HDR_SIZE (sizeof(struct abis_om_hdr) + sizeof(struct abis_om_fom_hdr)) |
| 61 | |
| 62 | /* Section 9.1: Message Types */ |
| 63 | enum abis_nm_msgtype { |
| 64 | /* SW Download Management Messages */ |
| 65 | NM_MT_LOAD_INIT = 0x01, |
| 66 | NM_MT_LOAD_INIT_ACK, |
| 67 | NM_MT_LOAD_INIT_NACK, |
| 68 | NM_MT_LOAD_SEG, |
| 69 | NM_MT_LOAD_SEG_ACK, |
| 70 | NM_MT_LOAD_ABORT, |
| 71 | NM_MT_LOAD_END, |
| 72 | NM_MT_LOAD_END_ACK, |
| 73 | NM_MT_LOAD_END_NACK, |
| 74 | NM_MT_SW_ACT_REQ, /* BTS->BSC */ |
| 75 | NM_MT_SW_ACT_REQ_ACK, |
| 76 | NM_MT_SW_ACT_REQ_NACK, |
| 77 | NM_MT_ACTIVATE_SW, /* BSC->BTS */ |
| 78 | NM_MT_ACTIVATE_SW_ACK, |
| 79 | NM_MT_ACTIVATE_SW_NACK, |
| 80 | NM_MT_SW_ACTIVATED_REP, /* 0x10 */ |
| 81 | /* A-bis Interface Management Messages */ |
| 82 | NM_MT_ESTABLISH_TEI = 0x21, |
| 83 | NM_MT_ESTABLISH_TEI_ACK, |
| 84 | NM_MT_ESTABLISH_TEI_NACK, |
| 85 | NM_MT_CONN_TERR_SIGN, |
| 86 | NM_MT_CONN_TERR_SIGN_ACK, |
| 87 | NM_MT_CONN_TERR_SIGN_NACK, |
| 88 | NM_MT_DISC_TERR_SIGN, |
| 89 | NM_MT_DISC_TERR_SIGN_ACK, |
| 90 | NM_MT_DISC_TERR_SIGN_NACK, |
| 91 | NM_MT_CONN_TERR_TRAF, |
| 92 | NM_MT_CONN_TERR_TRAF_ACK, |
| 93 | NM_MT_CONN_TERR_TRAF_NACK, |
| 94 | NM_MT_DISC_TERR_TRAF, |
| 95 | NM_MT_DISC_TERR_TRAF_ACK, |
| 96 | NM_MT_DISC_TERR_TRAF_NACK, |
| 97 | /* Transmission Management Messages */ |
| 98 | NM_MT_CONN_MDROP_LINK = 0x31, |
| 99 | NM_MT_CONN_MDROP_LINK_ACK, |
| 100 | NM_MT_CONN_MDROP_LINK_NACK, |
| 101 | NM_MT_DISC_MDROP_LINK, |
| 102 | NM_MT_DISC_MDROP_LINK_ACK, |
| 103 | NM_MT_DISC_MDROP_LINK_NACK, |
| 104 | /* Air Interface Management Messages */ |
| 105 | NM_MT_SET_BTS_ATTR = 0x41, |
| 106 | NM_MT_SET_BTS_ATTR_ACK, |
| 107 | NM_MT_SET_BTS_ATTR_NACK, |
| 108 | NM_MT_SET_RADIO_ATTR, |
| 109 | NM_MT_SET_RADIO_ATTR_ACK, |
| 110 | NM_MT_SET_RADIO_ATTR_NACK, |
| 111 | NM_MT_SET_CHAN_ATTR, |
| 112 | NM_MT_SET_CHAN_ATTR_ACK, |
| 113 | NM_MT_SET_CHAN_ATTR_NACK, |
| 114 | /* Test Management Messages */ |
| 115 | NM_MT_PERF_TEST = 0x51, |
| 116 | NM_MT_PERF_TEST_ACK, |
| 117 | NM_MT_PERF_TEST_NACK, |
| 118 | NM_MT_TEST_REP, |
| 119 | NM_MT_SEND_TEST_REP, |
| 120 | NM_MT_SEND_TEST_REP_ACK, |
| 121 | NM_MT_SEND_TEST_REP_NACK, |
| 122 | NM_MT_STOP_TEST, |
| 123 | NM_MT_STOP_TEST_ACK, |
| 124 | NM_MT_STOP_TEST_NACK, |
| 125 | /* State Management and Event Report Messages */ |
| 126 | NM_MT_STATECHG_EVENT_REP = 0x61, |
| 127 | NM_MT_FAILURE_EVENT_REP, |
| 128 | NM_MT_STOP_EVENT_REP, |
| 129 | NM_MT_STOP_EVENT_REP_ACK, |
| 130 | NM_MT_STOP_EVENT_REP_NACK, |
| 131 | NM_MT_REST_EVENT_REP, |
| 132 | NM_MT_REST_EVENT_REP_ACK, |
| 133 | NM_MT_REST_EVENT_REP_NACK, |
| 134 | NM_MT_CHG_ADM_STATE, |
| 135 | NM_MT_CHG_ADM_STATE_ACK, |
| 136 | NM_MT_CHG_ADM_STATE_NACK, |
| 137 | NM_MT_CHG_ADM_STATE_REQ, |
| 138 | NM_MT_CHG_ADM_STATE_REQ_ACK, |
| 139 | NM_MT_CHG_ADM_STATE_REQ_NACK, |
| 140 | NM_MT_REP_OUTST_ALARMS = 0x93, |
| 141 | NM_MT_REP_OUTST_ALARMS_ACK, |
| 142 | NM_MT_REP_OUTST_ALARMS_NACK, |
| 143 | /* Equipment Management Messages */ |
| 144 | NM_MT_CHANGEOVER = 0x71, |
| 145 | NM_MT_CHANGEOVER_ACK, |
| 146 | NM_MT_CHANGEOVER_NACK, |
| 147 | NM_MT_OPSTART, |
| 148 | NM_MT_OPSTART_ACK, |
| 149 | NM_MT_OPSTART_NACK, |
| 150 | NM_MT_REINIT, |
| 151 | NM_MT_REINIT_ACK, |
| 152 | NM_MT_REINIT_NACK, |
| 153 | NM_MT_SET_SITE_OUT, /* BS11: get alarm ?!? */ |
| 154 | NM_MT_SET_SITE_OUT_ACK, |
| 155 | NM_MT_SET_SITE_OUT_NACK, |
| 156 | NM_MT_CHG_HW_CONF = 0x90, |
| 157 | NM_MT_CHG_HW_CONF_ACK, |
| 158 | NM_MT_CHG_HW_CONF_NACK, |
| 159 | /* Measurement Management Messages */ |
| 160 | NM_MT_MEAS_RES_REQ = 0x8a, |
| 161 | NM_MT_MEAS_RES_RESP, |
| 162 | NM_MT_STOP_MEAS, |
| 163 | NM_MT_START_MEAS, |
| 164 | /* Other Messages */ |
| 165 | NM_MT_GET_ATTR = 0x81, |
| 166 | NM_MT_GET_ATTR_RESP, |
| 167 | NM_MT_GET_ATTR_NACK, |
| 168 | NM_MT_SET_ALARM_THRES, |
| 169 | NM_MT_SET_ALARM_THRES_ACK, |
| 170 | NM_MT_SET_ALARM_THRES_NACK, |
| 171 | }; |
| 172 | |
| 173 | enum abis_nm_msgtype_bs11 { |
| 174 | NM_MT_BS11_RESET_RESOURCE = 0x74, |
| 175 | |
| 176 | NM_MT_BS11_BEGIN_DB_TX = 0xa3, |
| 177 | NM_MT_BS11_BEGIN_DB_TX_ACK, |
| 178 | NM_MT_BS11_BEGIN_DB_TX_NACK, |
| 179 | NM_MT_BS11_END_DB_TX = 0xa6, |
| 180 | NM_MT_BS11_END_DB_TX_ACK, |
| 181 | NM_MT_BS11_END_DB_TX_NACK, |
| 182 | NM_MT_BS11_CREATE_OBJ = 0xa9, |
| 183 | NM_MT_BS11_CREATE_OBJ_ACK, |
| 184 | NM_MT_BS11_CREATE_OBJ_NACK, |
| 185 | NM_MT_BS11_DELETE_OBJ = 0xac, |
| 186 | NM_MT_BS11_DELETE_OBJ_ACK, |
| 187 | NM_MT_BS11_DELETE_OBJ_NACK, |
| 188 | |
| 189 | NM_MT_BS11_SET_ATTR = 0xd0, |
| 190 | NM_MT_BS11_SET_ATTR_ACK, |
| 191 | NM_MT_BS11_SET_ATTR_NACK, |
| 192 | NM_MT_BS11_LMT_SESSION = 0xdc, |
| 193 | |
| 194 | NM_MT_BS11_GET_STATE = 0xe3, |
| 195 | NM_MT_BS11_GET_STATE_ACK, |
| 196 | NM_MT_BS11_LMT_LOGON = 0xe5, |
| 197 | NM_MT_BS11_LMT_LOGON_ACK, |
| 198 | NM_MT_BS11_RESTART = 0xe7, |
| 199 | NM_MT_BS11_RESTART_ACK, |
| 200 | NM_MT_BS11_DISCONNECT = 0xe9, |
| 201 | NM_MT_BS11_DISCONNECT_ACK, |
| 202 | NM_MT_BS11_LMT_LOGOFF = 0xec, |
| 203 | NM_MT_BS11_LMT_LOGOFF_ACK, |
| 204 | NM_MT_BS11_RECONNECT = 0xf1, |
| 205 | NM_MT_BS11_RECONNECT_ACK, |
| 206 | }; |
| 207 | |
| 208 | enum abis_nm_msgtype_ipacc { |
| 209 | NM_MT_IPACC_RESTART = 0x87, |
| 210 | NM_MT_IPACC_RESTART_ACK, |
| 211 | NM_MT_IPACC_RESTART_NACK, |
| 212 | NM_MT_IPACC_RSL_CONNECT = 0xe0, |
| 213 | NM_MT_IPACC_RSL_CONNECT_ACK, |
| 214 | NM_MT_IPACC_RSL_CONNECT_NACK, |
| 215 | NM_MT_IPACC_RSL_DISCONNECT = 0xe3, |
| 216 | NM_MT_IPACC_RSL_DISCONNECT_ACK, |
| 217 | NM_MT_IPACC_RSL_DISCONNECT_NACK, |
| 218 | NM_MT_IPACC_CONN_TRAF = 0xe6, |
| 219 | NM_MT_IPACC_CONN_TRAF_ACK, |
| 220 | NM_MT_IPACC_CONN_TRAF_NACK, |
| 221 | NM_MT_IPACC_DEF_BOOT_SW = 0xec, |
| 222 | NM_MT_IPACC_DEF_BOOT_SW_ACK, |
| 223 | MN_MT_IPACC_DEF_BOOT_SW_NACK, |
| 224 | NM_MT_IPACC_SET_NVATTR = 0xef, |
| 225 | NM_MT_IPACC_SET_NVATTR_ACK, |
| 226 | NM_MT_IPACC_SET_NVATTR_NACK, |
| 227 | NM_MT_IPACC_GET_NVATTR = 0xf2, |
| 228 | NM_MT_IPACC_GET_NVATTR_ACK, |
| 229 | NM_MT_IPACC_GET_NVATTR_NACK, |
| 230 | NM_MT_IPACC_SET_ATTR = 0xf5, |
| 231 | NM_MT_IPACC_SET_ATTR_ACK, |
| 232 | NM_MT_IPACC_SET_ATTR_NACK, |
| 233 | }; |
| 234 | |
| 235 | enum abis_nm_bs11_cell_alloc { |
| 236 | NM_BS11_CANR_GSM = 0x00, |
| 237 | NM_BS11_CANR_DCS1800 = 0x01, |
| 238 | }; |
| 239 | |
| 240 | /* Section 9.2: Object Class */ |
| 241 | enum abis_nm_obj_class { |
| 242 | NM_OC_SITE_MANAGER = 0x00, |
| 243 | NM_OC_BTS, |
| 244 | NM_OC_RADIO_CARRIER, |
| 245 | NM_OC_CHANNEL, |
| 246 | NM_OC_BASEB_TRANSC, |
| 247 | /* RFU: 05-FE */ |
| 248 | |
| 249 | NM_OC_IPAC_E1_TRUNK = 0x0e, |
| 250 | NM_OC_IPAC_E1_PORT = 0x0f, |
| 251 | NM_OC_IPAC_E1_CHAN = 0x10, |
| 252 | NM_OC_IPAC_CLK_MODULE = 0x22, |
| 253 | |
| 254 | NM_OC_BS11_ADJC = 0xa0, |
| 255 | NM_OC_BS11_HANDOVER = 0xa1, |
| 256 | NM_OC_BS11_PWR_CTRL = 0xa2, |
| 257 | NM_OC_BS11_BTSE = 0xa3, /* LMT? */ |
| 258 | NM_OC_BS11_RACK = 0xa4, |
| 259 | NM_OC_BS11 = 0xa5, /* 01: ALCO */ |
| 260 | NM_OC_BS11_TEST = 0xa6, |
| 261 | NM_OC_BS11_ENVABTSE = 0xa8, |
| 262 | NM_OC_BS11_BPORT = 0xa9, |
| 263 | |
| 264 | NM_OC_GPRS_NSE = 0xf0, |
| 265 | NM_OC_GPRS_CELL = 0xf1, |
| 266 | NM_OC_GPRS_NSVC = 0xf2, |
| 267 | |
| 268 | NM_OC_NULL = 0xff, |
| 269 | }; |
| 270 | |
| 271 | /* Section 9.4: Attributes */ |
| 272 | enum abis_nm_attr { |
| 273 | NM_ATT_ABIS_CHANNEL = 0x01, |
| 274 | NM_ATT_ADD_INFO, |
| 275 | NM_ATT_ADD_TEXT, |
| 276 | NM_ATT_ADM_STATE, |
| 277 | NM_ATT_ARFCN_LIST, |
| 278 | NM_ATT_AUTON_REPORT, |
| 279 | NM_ATT_AVAIL_STATUS, |
| 280 | NM_ATT_BCCH_ARFCN, |
| 281 | NM_ATT_BSIC, |
| 282 | NM_ATT_BTS_AIR_TIMER, |
| 283 | NM_ATT_CCCH_L_I_P, |
| 284 | NM_ATT_CCCH_L_T, |
| 285 | NM_ATT_CHAN_COMB, |
| 286 | NM_ATT_CONN_FAIL_CRIT, |
| 287 | NM_ATT_DEST, |
| 288 | /* res */ |
| 289 | NM_ATT_EVENT_TYPE = 0x11, /* BS11: file data ?!? */ |
| 290 | NM_ATT_FILE_ID, |
| 291 | NM_ATT_FILE_VERSION, |
| 292 | NM_ATT_GSM_TIME, |
| 293 | NM_ATT_HSN, |
| 294 | NM_ATT_HW_CONFIG, |
| 295 | NM_ATT_HW_DESC, |
| 296 | NM_ATT_INTAVE_PARAM, |
| 297 | NM_ATT_INTERF_BOUND, |
| 298 | NM_ATT_LIST_REQ_ATTR, |
| 299 | NM_ATT_MAIO, |
| 300 | NM_ATT_MANUF_STATE, |
| 301 | NM_ATT_MANUF_THRESH, |
| 302 | NM_ATT_MANUF_ID, |
| 303 | NM_ATT_MAX_TA, |
| 304 | NM_ATT_MDROP_LINK, /* 0x20 */ |
| 305 | NM_ATT_MDROP_NEXT, |
| 306 | NM_ATT_NACK_CAUSES, |
| 307 | NM_ATT_NY1, |
| 308 | NM_ATT_OPER_STATE, |
| 309 | NM_ATT_OVERL_PERIOD, |
| 310 | NM_ATT_PHYS_CONF, |
| 311 | NM_ATT_POWER_CLASS, |
| 312 | NM_ATT_POWER_THRESH, |
| 313 | NM_ATT_PROB_CAUSE, |
| 314 | NM_ATT_RACH_B_THRESH, |
| 315 | NM_ATT_LDAVG_SLOTS, |
| 316 | NM_ATT_RAD_SUBC, |
| 317 | NM_ATT_RF_MAXPOWR_R, |
| 318 | NM_ATT_SITE_INPUTS, |
| 319 | NM_ATT_SITE_OUTPUTS, |
| 320 | NM_ATT_SOURCE, /* 0x30 */ |
| 321 | NM_ATT_SPEC_PROB, |
| 322 | NM_ATT_START_TIME, |
| 323 | NM_ATT_T200, |
| 324 | NM_ATT_TEI, |
| 325 | NM_ATT_TEST_DUR, |
| 326 | NM_ATT_TEST_NO, |
| 327 | NM_ATT_TEST_REPORT, |
| 328 | NM_ATT_VSWR_THRESH, |
| 329 | NM_ATT_WINDOW_SIZE, |
| 330 | /* Res */ |
| 331 | NM_ATT_BS11_RSSI_OFFS = 0x3d, |
| 332 | NM_ATT_BS11_TXPWR = 0x3e, |
| 333 | NM_ATT_BS11_DIVERSITY = 0x3f, |
| 334 | /* Res */ |
| 335 | NM_ATT_TSC = 0x40, |
| 336 | NM_ATT_SW_CONFIG, |
| 337 | NM_ATT_SW_DESCR, |
| 338 | NM_ATT_SEVERITY, |
| 339 | NM_ATT_GET_ARI, |
| 340 | NM_ATT_HW_CONF_CHG, |
| 341 | NM_ATT_OUTST_ALARM, |
| 342 | NM_ATT_FILE_DATA, |
| 343 | NM_ATT_MEAS_RES, |
| 344 | NM_ATT_MEAS_TYPE, |
| 345 | |
| 346 | NM_ATT_BS11_ESN_FW_CODE_NO = 0x4c, |
| 347 | NM_ATT_BS11_ESN_HW_CODE_NO = 0x4f, |
| 348 | |
| 349 | NM_ATT_BS11_ESN_PCB_SERIAL = 0x55, |
| 350 | NM_ATT_BS11_EXCESSIVE_DISTANCE = 0x58, |
| 351 | |
| 352 | NM_ATT_BS11_ALL_TEST_CATG = 0x60, |
| 353 | NM_ATT_BS11_BTSLS_HOPPING, |
| 354 | NM_ATT_BS11_CELL_ALLOC_NR, |
| 355 | NM_ATT_BS11_CELL_GLOBAL_ID, |
| 356 | NM_ATT_BS11_ENA_INTERF_CLASS = 0x66, |
| 357 | NM_ATT_BS11_ENA_INT_INTEC_HANDO = 0x67, |
| 358 | NM_ATT_BS11_ENA_INT_INTRC_HANDO = 0x68, |
| 359 | NM_ATT_BS11_ENA_MS_PWR_CTRL = 0x69, |
| 360 | NM_ATT_BS11_ENA_PWR_BDGT_HO = 0x6a, |
| 361 | NM_ATT_BS11_ENA_PWR_CTRL_RLFW = 0x6b, |
| 362 | NM_ATT_BS11_ENA_RXLEV_HO = 0x6c, |
| 363 | NM_ATT_BS11_ENA_RXQUAL_HO = 0x6d, |
| 364 | NM_ATT_BS11_FACCH_QUAL = 0x6e, |
| 365 | |
| 366 | NM_ATT_IPACC_DST_IP = 0x80, |
| 367 | NM_ATT_IPACC_DST_IP_PORT = 0x81, |
| 368 | NM_ATT_IPACC_SSRC = 0x82, |
| 369 | NM_ATT_IPACC_RTP_PAYLD_TYPE = 0x83, |
| 370 | NM_ATT_IPACC_BASEB_ID = 0x84, |
| 371 | NM_ATT_IPACC_STREAM_ID = 0x85, |
| 372 | NM_ATT_IPACC_NV_FLAGS = 0x86, |
| 373 | NM_ATT_IPACC_FREQ_CTRL = 0x87, |
| 374 | NM_ATT_IPACC_PRIM_OML_CFG = 0x88, |
| 375 | NM_ATT_IPACC_SEC_OML_CFG = 0x89, |
| 376 | NM_ATT_IPACC_IP_IF_CFG = 0x8a, /* IP interface */ |
| 377 | NM_ATT_IPACC_IP_GW_CFG = 0x8b, /* IP gateway */ |
| 378 | NM_ATT_IPACC_IN_SERV_TIME = 0x8c, |
| 379 | NM_ATT_IPACC_TRX_BTS_ASS = 0x8d, |
| 380 | NM_ATT_IPACC_LOCATION = 0x8e, /* string describing location */ |
| 381 | NM_ATT_IPACC_PAGING_CFG = 0x8f, |
| 382 | NM_ATT_IPACC_FILE_DATA = 0x90, |
| 383 | NM_ATT_IPACC_UNIT_ID = 0x91, /* Site/BTS/TRX */ |
| 384 | NM_ATT_IPACC_PARENT_UNIT_ID = 0x92, |
| 385 | NM_ATT_IPACC_UNIT_NAME = 0x93, /* default: nbts-<mac-as-string> */ |
| 386 | NM_ATT_IPACC_SNMP_CFG = 0x94, |
| 387 | NM_ATT_IPACC_PRIM_OML_CFG_LIST = 0x95, |
| 388 | NM_ATT_IPACC_PRIM_OML_FB_TOUT = 0x96, |
| 389 | NM_ATT_IPACC_CUR_SW_CFG = 0x97, |
| 390 | NM_ATT_IPACC_TIMING_BUS = 0x98, |
| 391 | NM_ATT_IPACC_CGI = 0x99, |
| 392 | NM_ATT_IPACC_RAC = 0x9a, |
| 393 | NM_ATT_IPACC_OBJ_VERSION = 0x9b, |
| 394 | NM_ATT_IPACC_GPRS_PAGING_CFG = 0x9c, |
| 395 | NM_ATT_IPACC_NSEI = 0x9d, |
| 396 | NM_ATT_IPACC_BVCI = 0x9e, |
| 397 | NM_ATT_IPACC_NSVCI = 0x9f, |
| 398 | NM_ATT_IPACC_NS_CFG = 0xa0, |
| 399 | NM_ATT_IPACC_BSSGP_CFG = 0xa1, |
| 400 | NM_ATT_IPACC_NS_LINK_CFG = 0xa2, |
| 401 | NM_ATT_IPACC_RLC_CFG = 0xa3, |
| 402 | NM_ATT_IPACC_ALM_THRESH_LIST = 0xa4, |
| 403 | NM_ATT_IPACC_MONIT_VAL_LIST = 0xa5, |
| 404 | NM_ATT_IPACC_TIB_CONTROL = 0xa6, |
| 405 | NM_ATT_IPACC_SUPP_FEATURES = 0xa7, |
| 406 | NM_ATT_IPACC_CODING_SCHEMES = 0xa8, |
| 407 | NM_ATT_IPACC_RLC_CFG_2 = 0xa9, |
| 408 | NM_ATT_IPACC_HEARTB_TOUT = 0xaa, |
| 409 | NM_ATT_IPACC_UPTIME = 0xab, |
| 410 | NM_ATT_IPACC_RLC_CFG_3 = 0xac, |
| 411 | NM_ATT_IPACC_SSL_CFG = 0xad, |
| 412 | NM_ATT_IPACC_SEC_POSSIBLE = 0xae, |
| 413 | NM_ATT_IPACC_IML_SSL_STATE = 0xaf, |
| 414 | NM_ATT_IPACC_REVOC_DATE = 0xb0, |
| 415 | |
| 416 | |
| 417 | NM_ATT_BS11_RF_RES_IND_PER = 0x8f, |
| 418 | |
| 419 | NM_ATT_BS11_RX_LEV_MIN_CELL = 0x90, |
| 420 | NM_ATT_BS11_ABIS_EXT_TIME = 0x91, |
| 421 | NM_ATT_BS11_TIMER_HO_REQUEST = 0x92, |
| 422 | NM_ATT_BS11_TIMER_NCELL = 0x93, |
| 423 | NM_ATT_BS11_TSYNC = 0x94, |
| 424 | NM_ATT_BS11_TTRAU = 0x95, |
| 425 | NM_ATT_BS11_EMRG_CFG_MEMBER = 0x9b, |
| 426 | NM_ATT_BS11_TRX_AREA = 0x9f, |
| 427 | |
| 428 | NM_ATT_BS11_BCCH_RECONF = 0xd7, |
| 429 | NM_ATT_BS11_BIT_ERR_THESH = 0xa0, |
| 430 | NM_ATT_BS11_BOOT_SW_VERS = 0xa1, |
| 431 | NM_ATT_BS11_CCLK_ACCURACY = 0xa3, |
| 432 | NM_ATT_BS11_CCLK_TYPE = 0xa4, |
| 433 | NM_ATT_BS11_INP_IMPEDANCE = 0xaa, |
| 434 | NM_ATT_BS11_L1_PROT_TYPE = 0xab, |
| 435 | NM_ATT_BS11_LINE_CFG = 0xac, |
| 436 | NM_ATT_BS11_LI_PORT_1 = 0xad, |
| 437 | NM_ATT_BS11_LI_PORT_2 = 0xae, |
| 438 | |
| 439 | NM_ATT_BS11_L1_REM_ALM_TYPE = 0xb0, |
| 440 | NM_ATT_BS11_SW_LOAD_INTENDED = 0xbb, |
| 441 | NM_ATT_BS11_SW_LOAD_SAFETY = 0xbc, |
| 442 | NM_ATT_BS11_SW_LOAD_STORED = 0xbd, |
| 443 | |
| 444 | NM_ATT_BS11_VENDOR_NAME = 0xc1, |
| 445 | NM_ATT_BS11_HOPPING_MODE = 0xc5, |
| 446 | NM_ATT_BS11_LMT_LOGON_SESSION = 0xc6, |
| 447 | NM_ATT_BS11_LMT_LOGIN_TIME = 0xc7, |
| 448 | NM_ATT_BS11_LMT_USER_ACC_LEV = 0xc8, |
| 449 | NM_ATT_BS11_LMT_USER_NAME = 0xc9, |
| 450 | |
| 451 | NM_ATT_BS11_L1_CONTROL_TS = 0xd8, |
| 452 | NM_ATT_BS11_RADIO_MEAS_GRAN = 0xdc, /* in SACCH multiframes */ |
| 453 | NM_ATT_BS11_RADIO_MEAS_REP = 0xdd, |
| 454 | |
| 455 | NM_ATT_BS11_SH_LAPD_INT_TIMER = 0xe8, |
| 456 | |
| 457 | NM_ATT_BS11_BTS_STATE = 0xf0, |
| 458 | NM_ATT_BS11_E1_STATE = 0xf1, |
| 459 | NM_ATT_BS11_PLL = 0xf2, |
| 460 | NM_ATT_BS11_RX_OFFSET = 0xf3, |
| 461 | NM_ATT_BS11_ANT_TYPE = 0xf4, |
| 462 | NM_ATT_BS11_PLL_MODE = 0xfc, |
| 463 | NM_ATT_BS11_PASSWORD = 0xfd, |
| 464 | }; |
| 465 | #define NM_ATT_BS11_FILE_DATA NM_ATT_EVENT_TYPE |
| 466 | |
| 467 | /* Section 9.4.4: Administrative State */ |
| 468 | enum abis_nm_adm_state { |
| 469 | NM_STATE_LOCKED = 0x01, |
| 470 | NM_STATE_UNLOCKED = 0x02, |
| 471 | NM_STATE_SHUTDOWN = 0x03, |
| 472 | NM_STATE_NULL = 0xff, |
| 473 | }; |
| 474 | |
| 475 | /* Section 9.4.7: Administrative State */ |
| 476 | enum abis_nm_avail_state { |
| 477 | NM_AVSTATE_IN_TEST = 1, |
| 478 | NM_AVSTATE_POWER_OFF = 2, |
| 479 | NM_AVSTATE_OFF_LINE = 3, |
| 480 | NM_AVSTATE_DEPENDENCY = 5, |
| 481 | NM_AVSTATE_DEGRADED = 6, |
| 482 | NM_AVSTATE_NOT_INSTALLED= 7, |
| 483 | NM_AVSTATE_OK = 0xff, |
| 484 | }; |
| 485 | |
| 486 | enum abis_nm_op_state { |
| 487 | NM_OPSTATE_DISABLED = 1, |
| 488 | NM_OPSTATE_ENABLED = 2, |
| 489 | NM_OPSTATE_NULL = 0xff, |
| 490 | }; |
| 491 | |
| 492 | /* Section 9.4.13: Channel Combination */ |
| 493 | enum abis_nm_chan_comb { |
| 494 | NM_CHANC_TCHFull = 0x00, /* TCH/F + TCH/H + SACCH/TF */ |
| 495 | NM_CHANC_TCHHalf = 0x01, /* TCH/H(0,1) + FACCH/H(0,1) + |
| 496 | SACCH/TH(0,1) */ |
| 497 | NM_CHANC_TCHHalf2 = 0x02, /* TCH/H(0) + FACCH/H(0) + SACCH/TH(0) + |
| 498 | TCH/H(1) */ |
| 499 | NM_CHANC_SDCCH = 0x03, /* SDCCH/8 + SACCH/8 */ |
| 500 | NM_CHANC_mainBCCH = 0x04, /* FCCH + SCH + BCCH + CCCH */ |
| 501 | NM_CHANC_BCCHComb = 0x05, /* FCCH + SCH + BCCH + CCCH + SDCCH/4 + |
| 502 | SACCH/C4 */ |
| 503 | NM_CHANC_BCCH = 0x06, /* BCCH + CCCH */ |
| 504 | NM_CHANC_BCCH_CBCH = 0x07, /* CHANC_BCCHComb + CBCH */ |
| 505 | NM_CHANC_SDCCH_CBCH = 0x08, /* CHANC_SDCCH8 + CBCH */ |
| 506 | /* ip.access */ |
| 507 | NM_CHANC_IPAC_bPDCH = 0x0b, /* PBCCH + PCCCH + PDTCH/F + PACCH/F + |
| 508 | PTCCH/F */ |
| 509 | NM_CHANC_IPAC_cPDCH = 0x0c, /* PBCCH + PDTCH/F + PACCH/F + PTCCH/F */ |
| 510 | NM_CHANC_IPAC_PDCH = 0x0d, /* PDTCH/F + PACCH/F + PTCCH/F */ |
| 511 | NM_CHANC_IPAC_TCHFull_PDCH = 0x80, |
| 512 | NM_CHANC_IPAC_TCHFull_TCHHalf = 0x81, |
| 513 | }; |
| 514 | |
| 515 | /* Section 9.4.16: Event Type */ |
| 516 | enum abis_nm_event_type { |
| 517 | NM_EVT_COMM_FAIL = 0x00, |
| 518 | NM_EVT_QOS_FAIL = 0x01, |
| 519 | NM_EVT_PROC_FAIL = 0x02, |
| 520 | NM_EVT_EQUIP_FAIL = 0x03, |
| 521 | NM_EVT_ENV_FAIL = 0x04, |
| 522 | }; |
| 523 | |
| 524 | /* Section: 9.4.63: Perceived Severity */ |
| 525 | enum abis_nm_severity { |
| 526 | NM_SEVER_CEASED = 0x00, |
| 527 | NM_SEVER_CRITICAL = 0x01, |
| 528 | NM_SEVER_MAJOR = 0x02, |
| 529 | NM_SEVER_MINOR = 0x03, |
| 530 | NM_SEVER_WARNING = 0x04, |
| 531 | NM_SEVER_INDETERMINATE = 0x05, |
| 532 | }; |
| 533 | |
| 534 | /* Section 9.4.43: Probable Cause Type */ |
| 535 | enum abis_nm_pcause_type { |
| 536 | NM_PCAUSE_T_X721 = 0x01, |
| 537 | NM_PCAUSE_T_GSM = 0x02, |
| 538 | NM_PCAUSE_T_MANUF = 0x03, |
| 539 | }; |
| 540 | |
| 541 | /* Section 9.4.36: NACK Causes */ |
| 542 | enum abis_nm_nack_cause { |
| 543 | /* General Nack Causes */ |
| 544 | NM_NACK_INCORR_STRUCT = 0x01, |
| 545 | NM_NACK_MSGTYPE_INVAL = 0x02, |
| 546 | NM_NACK_OBJCLASS_INVAL = 0x05, |
| 547 | NM_NACK_OBJCLASS_NOTSUPP = 0x06, |
| 548 | NM_NACK_BTSNR_UNKN = 0x07, |
| 549 | NM_NACK_TRXNR_UNKN = 0x08, |
| 550 | NM_NACK_OBJINST_UNKN = 0x09, |
| 551 | NM_NACK_ATTRID_INVAL = 0x0c, |
| 552 | NM_NACK_ATTRID_NOTSUPP = 0x0d, |
| 553 | NM_NACK_PARAM_RANGE = 0x0e, |
| 554 | NM_NACK_ATTRLIST_INCONSISTENT = 0x0f, |
| 555 | NM_NACK_SPEC_IMPL_NOTSUPP = 0x10, |
| 556 | NM_NACK_CANT_PERFORM = 0x11, |
| 557 | /* Specific Nack Causes */ |
| 558 | NM_NACK_RES_NOTIMPL = 0x19, |
| 559 | NM_NACK_RES_NOTAVAIL = 0x1a, |
| 560 | NM_NACK_FREQ_NOTAVAIL = 0x1b, |
| 561 | NM_NACK_TEST_NOTSUPP = 0x1c, |
| 562 | NM_NACK_CAPACITY_RESTR = 0x1d, |
| 563 | NM_NACK_PHYSCFG_NOTPERFORM = 0x1e, |
| 564 | NM_NACK_TEST_NOTINIT = 0x1f, |
| 565 | NM_NACK_PHYSCFG_NOTRESTORE = 0x20, |
| 566 | NM_NACK_TEST_NOSUCH = 0x21, |
| 567 | NM_NACK_TEST_NOSTOP = 0x22, |
| 568 | NM_NACK_MSGINCONSIST_PHYSCFG = 0x23, |
| 569 | NM_NACK_FILE_INCOMPLETE = 0x25, |
| 570 | NM_NACK_FILE_NOTAVAIL = 0x26, |
| 571 | NM_NACK_FILE_NOTACTIVATE = 0x27, |
| 572 | NM_NACK_REQ_NOT_GRANT = 0x28, |
| 573 | NM_NACK_WAIT = 0x29, |
| 574 | NM_NACK_NOTH_REPORT_EXIST = 0x2a, |
| 575 | NM_NACK_MEAS_NOTSUPP = 0x2b, |
| 576 | NM_NACK_MEAS_NOTSTART = 0x2c, |
| 577 | }; |
| 578 | |
| 579 | /* Section 9.4.1 */ |
| 580 | struct abis_nm_channel { |
| 581 | uint8_t attrib; |
| 582 | uint8_t bts_port; |
| 583 | uint8_t timeslot; |
| 584 | uint8_t subslot; |
| 585 | } __attribute__ ((packed)); |
| 586 | |
| 587 | /* Siemens BS-11 specific objects in the SienemsHW (0xA5) object class */ |
| 588 | enum abis_bs11_objtype { |
| 589 | BS11_OBJ_ALCO = 0x01, |
| 590 | BS11_OBJ_BBSIG = 0x02, /* obj_class: 0,1 */ |
| 591 | BS11_OBJ_TRX1 = 0x03, /* only DEACTIVATE TRX1 */ |
| 592 | BS11_OBJ_CCLK = 0x04, |
| 593 | BS11_OBJ_GPSU = 0x06, |
| 594 | BS11_OBJ_LI = 0x07, |
| 595 | BS11_OBJ_PA = 0x09, /* obj_class: 0, 1*/ |
| 596 | }; |
| 597 | |
| 598 | enum abis_bs11_trx_power { |
| 599 | BS11_TRX_POWER_GSM_2W = 0x06, |
| 600 | BS11_TRX_POWER_GSM_250mW= 0x07, |
| 601 | BS11_TRX_POWER_GSM_80mW = 0x08, |
| 602 | BS11_TRX_POWER_GSM_30mW = 0x09, |
| 603 | BS11_TRX_POWER_DCS_3W = 0x0a, |
| 604 | BS11_TRX_POWER_DCS_1W6 = 0x0b, |
| 605 | BS11_TRX_POWER_DCS_500mW= 0x0c, |
| 606 | BS11_TRX_POWER_DCS_160mW= 0x0d, |
| 607 | }; |
| 608 | |
| 609 | enum abis_bs11_li_pll_mode { |
| 610 | BS11_LI_PLL_LOCKED = 2, |
| 611 | BS11_LI_PLL_STANDALONE = 3, |
| 612 | }; |
| 613 | |
| 614 | enum abis_bs11_line_cfg { |
| 615 | BS11_LINE_CFG_STAR = 0x00, |
| 616 | BS11_LINE_CFG_MULTIDROP = 0x01, |
| 617 | BS11_LINE_CFG_LOOP = 0x02, |
| 618 | }; |
| 619 | |
| 620 | enum abis_bs11_phase { |
| 621 | BS11_STATE_SOFTWARE_RQD = 0x01, |
| 622 | BS11_STATE_LOAD_SMU_INTENDED = 0x11, |
| 623 | BS11_STATE_LOAD_SMU_SAFETY = 0x21, |
| 624 | BS11_STATE_LOAD_FAILED = 0x31, |
| 625 | BS11_STATE_LOAD_DIAGNOSTIC = 0x41, |
| 626 | BS11_STATE_WARM_UP = 0x51, |
| 627 | BS11_STATE_WARM_UP_2 = 0x52, |
| 628 | BS11_STATE_WAIT_MIN_CFG = 0x62, |
| 629 | BS11_STATE_MAINTENANCE = 0x72, |
| 630 | BS11_STATE_LOAD_MBCCU = 0x92, |
| 631 | BS11_STATE_WAIT_MIN_CFG_2 = 0xA2, |
| 632 | BS11_STATE_NORMAL = 0x03, |
| 633 | BS11_STATE_ABIS_LOAD = 0x13, |
| 634 | }; |
| 635 | |
| 636 | enum abis_nm_ipacc_test_no { |
| 637 | NM_IPACC_TESTNO_RLOOP_ANT = 0x01, |
| 638 | NM_IPACC_TESTNO_RLOOP_XCVR = 0x02, |
| 639 | NM_IPACC_TESTNO_FUNC_OBJ = 0x03, |
| 640 | NM_IPACC_TESTNO_CHAN_USAGE = 0x40, |
| 641 | NM_IPACC_TESTNO_BCCH_CHAN_USAGE = 0x41, |
| 642 | NM_IPACC_TESTNO_FREQ_SYNC = 0x42, |
| 643 | NM_IPACC_TESTNO_BCCH_INFO = 0x43, |
| 644 | NM_IPACC_TESTNO_TX_BEACON = 0x44, |
| 645 | NM_IPACC_TESTNO_SYSINFO_MONITOR = 0x45, |
| 646 | NM_IPACC_TESTNO_BCCCH_MONITOR = 0x46, |
| 647 | }; |
| 648 | |
| 649 | /* first byte after length inside NM_ATT_TEST_REPORT */ |
| 650 | enum abis_nm_ipacc_test_res { |
| 651 | NM_IPACC_TESTRES_SUCCESS = 0, |
| 652 | NM_IPACC_TESTRES_TIMEOUT = 1, |
| 653 | NM_IPACC_TESTRES_NO_CHANS = 2, |
| 654 | NM_IPACC_TESTRES_PARTIAL = 3, |
| 655 | NM_IPACC_TESTRES_STOPPED = 4, |
| 656 | }; |
| 657 | |
| 658 | /* internal IE inside NM_ATT_TEST_REPORT */ |
| 659 | enum abis_nm_ipacc_testres_ie { |
| 660 | NM_IPACC_TR_IE_FREQ_ERR_LIST = 3, |
| 661 | NM_IPACC_TR_IE_CHAN_USAGE = 4, |
| 662 | NM_IPACC_TR_IE_BCCH_INFO = 6, |
| 663 | NM_IPACC_TR_IE_RESULT_DETAILS = 8, |
| 664 | NM_IPACC_TR_IE_FREQ_ERR = 18, |
| 665 | }; |
| 666 | |
| 667 | enum ipac_eie { |
| 668 | NM_IPAC_EIE_ARFCN_WHITE = 0x01, |
| 669 | NM_IPAC_EIE_ARFCH_BLACK = 0x02, |
| 670 | NM_IPAC_EIE_FREQ_ERR_LIST = 0x03, |
| 671 | NM_IPAC_EIE_CHAN_USE_LIST = 0x04, |
| 672 | NM_IPAC_EIE_BCCH_INFO_TYPE = 0x05, |
| 673 | NM_IPAC_EIE_BCCH_INFO = 0x06, |
| 674 | NM_IPAC_EIE_CONFIG = 0x07, |
| 675 | NM_IPAC_EIE_RES_DETAILS = 0x08, |
| 676 | NM_IPAC_EIE_RXLEV_THRESH = 0x09, |
| 677 | NM_IPAC_EIE_FREQ_SYNC_OPTS = 0x0a, |
| 678 | NM_IPAC_EIE_MAC_ADDR = 0x0b, |
| 679 | NM_IPAC_EIE_HW_SW_COMPAT_NR = 0x0c, |
| 680 | NM_IPAC_EIE_MANUF_SER_NR = 0x0d, |
| 681 | NM_IPAC_EIE_OEM_ID = 0x0e, |
| 682 | NM_IPAC_EIE_DATE_TIME_MANUF = 0x0f, |
| 683 | NM_IPAC_EIE_DATE_TIME_CALIB = 0x10, |
| 684 | NM_IPAC_EIE_BEACON_INFO = 0x11, |
| 685 | NM_IPAC_EIE_FREQ_ERR = 0x12, |
| 686 | /* FIXME */ |
| 687 | NM_IPAC_EIE_FREQ_BANDS = 0x1c, |
| 688 | NM_IPAC_EIE_MAX_TA = 0x1d, |
| 689 | NM_IPAC_EIE_CIPH_ALGOS = 0x1e, |
| 690 | NM_IPAC_EIE_CHAN_TYPES = 0x1f, |
| 691 | NM_IPAC_EIE_CHAN_MODES = 0x20, |
| 692 | NM_IPAC_EIE_GPRS_CODING = 0x21, |
| 693 | NM_IPAC_EIE_RTP_FEATURES = 0x22, |
| 694 | NM_IPAC_EIE_RSL_FEATURES = 0x23, |
| 695 | NM_IPAC_EIE_BTS_HW_CLASS = 0x24, |
| 696 | NM_IPAC_EIE_BTS_ID = 0x25, |
| 697 | }; |
| 698 | |
| 699 | enum ipac_bcch_info_type { |
| 700 | IPAC_BINF_RXLEV = (1 << 8), |
| 701 | IPAC_BINF_RXQUAL = (1 << 9), |
| 702 | IPAC_BINF_FREQ_ERR_QUAL = (1 << 10), |
| 703 | IPAC_BINF_FRAME_OFFSET = (1 << 11), |
| 704 | IPAC_BINF_FRAME_NR_OFFSET = (1 << 12), |
| 705 | IPAC_BINF_BSIC = (1 << 13), |
| 706 | IPAC_BINF_CGI = (1 << 14), |
| 707 | IPAC_BINF_NEIGH_BA_SI2 = (1 << 15), |
| 708 | IPAC_BINF_NEIGH_BA_SI2bis = (1 << 0), |
| 709 | IPAC_BINF_NEIGH_BA_SI2ter = (1 << 1), |
| 710 | IPAC_BINF_CELL_ALLOC = (1 << 2), |
| 711 | }; |
| 712 | |
| 713 | #endif /* PROTO_GSM_12_21_H */ |