2 * Routines for GSM A Interface (actually A-bis really) RR dissection - A.K.A. GSM layer 3 Radio Resource Protocol
4 * Copyright 2003, Michael Lum <mlum [AT] telostech.com>
5 * In association with Telos Technology Inc.
7 * Added Dissection of Radio Resource Management Information Elements
8 * and othere enhancements and fixes.
9 * Copyright 2005 - 2006, Anders Broman [AT] ericsson.com
14 * Mobile radio interface Layer 3 specification;
15 * Core network protocols;
17 * (3GPP TS 24.008 version 4.7.0 Release 4)
18 * (ETSI TS 124 008 V6.8.0 (2005-03))
21 * Mobile radio interface layer 3 specification;
22 * Radio Resource Control Protocol
23 * (GSM 04.18 version 8.4.1 Release 1999)
24 * (3GPP TS 04.18 version 8.26.0 Release 1999)
28 * Wireshark - Network traffic analyzer
29 * By Gerald Combs <gerald@wireshark.org>
30 * Copyright 1998 Gerald Combs
32 * This program is free software; you can redistribute it and/or
33 * modify it under the terms of the GNU General Public License
34 * as published by the Free Software Foundation; either version 2
35 * of the License, or (at your option) any later version.
37 * This program is distributed in the hope that it will be useful,
38 * but WITHOUT ANY WARRANTY; without even the implied warranty of
39 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
40 * GNU General Public License for more details.
42 * You should have received a copy of the GNU General Public License
43 * along with this program; if not, write to the Free Software
44 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
56 #include <epan/packet.h>
57 #include <epan/prefs.h>
59 #include <epan/asn1.h>
61 #include "packet-bssap.h"
62 #include "packet-sccp.h"
63 #include "packet-ber.h"
64 #include "packet-q931.h"
65 #include "packet-gsm_a_common.h"
66 #include "packet-ipv6.h"
67 #include "packet-e212.h"
68 #include "packet-ppp.h"
70 static dissector_handle_t rrc_irat_ho_info_handle;
71 static dissector_handle_t rrc_irat_ho_to_utran_cmd_handle;
73 #define PADDING_BYTE 0x2B
75 gboolean gsm_a_rr_is_bit_high(tvbuff_t *tvb, gint bit_offset)
77 guint8 bit_mask = 0x80 >> (bit_offset & 0x07);
78 if ((tvb_get_guint8(tvb,bit_offset >> 3) & bit_mask) != (PADDING_BYTE & bit_mask))
83 /* PROTOTYPES/FORWARDS */
85 const value_string gsm_a_dtap_msg_rr_strings[] = {
87 { 0x3b, "Additional Assignment" },
88 { 0x3f, "Immediate Assignment" },
89 { 0x39, "Immediate Assignment Extended" },
90 { 0x3a, "Immediate Assignment Reject" },
92 { 0x48, "DTM Assignment Failure" },
93 { 0x49, "DTM Reject" },
94 { 0x4a, "DTM Request" },
95 { 0x4b, "Main DCCH Assignment Command" },
96 { 0x4c, "Packet Assignment Command" },
98 { 0x35, "Ciphering Mode Command" },
99 { 0x32, "Ciphering Mode Complete" },
101 { 0x30, "Configuration Change Command" },
102 { 0x31, "Configuration Change Ack." },
103 { 0x33, "Configuration Change Reject" },
105 { 0x2e, "Assignment Command" },
106 { 0x29, "Assignment Complete" },
107 { 0x2f, "Assignment Failure" },
108 { 0x2b, "Handover Command" },
109 { 0x2c, "Handover Complete" },
110 { 0x28, "Handover Failure" },
111 { 0x2d, "Physical Information" },
112 { 0x4d, "DTM Assignment Command" },
114 { 0x08, "RR-cell Change Order" },
115 { 0x23, "PDCH Assignment Command" },
117 { 0x0d, "Channel Release" },
118 { 0x0a, "Partial Release" },
119 { 0x0f, "Partial Release Complete" },
121 { 0x21, "Paging Request Type 1" },
122 { 0x22, "Paging Request Type 2" },
123 { 0x24, "Paging Request Type 3" },
124 { 0x27, "Paging Response" },
125 { 0x20, "Notification/NCH" },
126 { 0x25, "Reserved" },
127 { 0x26, "Notification/Response" },
129 { 0x0b, "Reserved" },
131 /* ETSI TS 101 503 V8.5.0 Seems to give Other def for this Messages???
132 { 0xc0, "Utran Classmark Change" }, CONFLICTS WITH Handover To UTRAN Command
133 { 0xc1, "UE RAB Preconfiguration" },
134 { 0xc2, "cdma2000 Classmark Change" },*/
136 /* ETSI TS 101 503 V8.5.0 */
137 { 0x60, "Utran Classmark Change" },
138 { 0x62, "cdma2000 Classmark Change" },
139 { 0x63, "Inter System to UTRAN Handover Command" },
140 { 0x64, "Inter System to cdma2000 Handover Command" },
141 { 0x18, "System Information Type 8" },
142 { 0x19, "System Information Type 1" },
143 { 0x1a, "System Information Type 2" },
144 { 0x1b, "System Information Type 3" },
145 { 0x1c, "System Information Type 4" },
146 { 0x1d, "System Information Type 5" },
147 { 0x1e, "System Information Type 6" },
148 { 0x1f, "System Information Type 7" },
150 { 0x02, "System Information Type 2bis" },
151 { 0x03, "System Information Type 2ter" },
152 { 0x07, "System Information Type 2quater" },
153 { 0x05, "System Information Type 5bis" },
154 { 0x06, "System Information Type 5ter" },
155 { 0x04, "System Information Type 9" },
156 { 0x00, "System Information Type 13" },
158 { 0x3d, "System Information Type 16" },
159 { 0x3e, "System Information Type 17" },
161 { 0x40, "System Information Type 18" },
162 { 0x41, "System Information Type 19" },
163 { 0x42, "System Information Type 20" },
165 { 0x10, "Channel Mode Modify" },
166 { 0x12, "RR Status" },
167 { 0x17, "Channel Mode Modify Acknowledge" },
168 { 0x14, "Frequency Redefinition" },
169 { 0x15, "Measurement Report" },
170 { 0x16, "Classmark Change" },
171 { 0x13, "Classmark Enquiry" },
172 { 0x36, "Extended Measurement Report" },
173 { 0x37, "Extended Measurement Order" },
174 { 0x34, "GPRS Suspension Request" },
176 { 0x09, "VGCS Uplink Grant" },
177 { 0x0e, "Uplink Release" },
178 { 0x0c, "Reserved" },
179 { 0x2a, "Uplink Busy" },
180 { 0x11, "Talker Indication" },
182 { 0xc0, "UTRAN Classmark Change/Handover To UTRAN Command" }, /* spec conflict */
184 { 0x38, "Application Information" },
189 const value_string gsm_rr_elem_strings[] = {
190 /* Radio Resource Management Information Elements 10.5.2, most are from 10.5.1 */
191 { 0x00, "BA Range" }, /* [3] 10.5.2.1a BA Range */
192 { 0x00, "Cell Channel Description" }, /* [3] 10.5.2.1b */
193 { 0x00, "BA List Pref" }, /* [3] 10.5.2.1c BA List Pref */
194 { 0x00, "UTRAN Frequency List" }, /* [3] 10.5.2.1d UTRAN Frequency List */
195 { 0x00, "Cell Selection Indicator after Release of all TCH and SDCCH" }, /* [3] 10.5.2.1e Cell selection indicator after release of all TCH and SDCCH IE */
196 { 0x00, "Cell Description" }, /* 10.5.2.2 */
197 { 0x00, "Cell Options (BCCH)" }, /* [3] 10.5.2.3 Cell Options (BCCH) */
198 { 0x00, "Cell Options (SACCH)" }, /* [3] 10.5.2.3a Cell Options (SACCH) */
199 { 0x00, "Cell Selection Parameters" }, /* [3] 10.5.2.4 Cell Selection Parameters */
200 /* [3] 10.5.2.4a (void) */
201 { 0x00, "Channel Description" }, /* 10.5.2.5 */
202 { 0x00, "Channel Description 2" }, /* 10.5.2.5a */
203 { 0x00, "Channel Description 3" }, /* 10.5.2.5c */
204 { 0x00, "Channel Mode" }, /* [3] 10.5.2.6 */
205 { 0x00, "Channel Mode 2" }, /* [3] 10.5.2.7 */
206 { 0x00, "UTRAN Classmark" }, /* [3] 10.5.2.7a */
207 /* [3] 10.5.2.7b (void) */
208 { 0x00, "Classmark Enquiry Mask" }, /* [3] 10.5.2.7c */
209 /* [3] 10.5.2.7d GERAN Iu Mode Classmark information element */
210 { 0x00, "Channel Needed"}, /* [3] 10.5.2.8 */
211 /* [3] 10.5.2.8a (void) */
212 /* [3] 10.5.2.8b Channel Request Description 2 */
214 { 0x00, "Cipher Mode Setting" }, /* [3] 10.5.2.9 */
215 { 0x00, "Cipher Mode Response" }, /* [3] 10.5.2.10 */
216 { 0x00, "Control Channel Description" }, /* [3] 10.5.2.11 Control Channel Description */
217 /* [3] 10.5.2.11a DTM Information Details */
218 { 0x00, "Dynamic ARFCN Mapping" }, /* [3] 10.5.2.11b */
219 { 0x00, "Frequency Channel Sequence" }, /* [3] 10.5.2.12 */
220 { 0x00, "Frequency List" }, /* 10.5.2.13 */
221 { 0x00, "Frequency Short List" }, /* 10.5.2.14 */
222 { 0x00, "Frequency Short List2" }, /* 10.5.2.14a */
223 /* [3] 10.5.2.14b Group Channel Description */
224 { 0x00, "GPRS Resumption" }, /* [3] 10.5.2.14c GPRS Resumption */
225 { 0x00, "GPRS Broadcast Information" }, /* [3] 10.5.2.14d GPRS broadcast information */
226 /* [3] 10.5.2.14e Enhanced DTM CS Release Indication */
227 { 0x00, "Handover Reference" }, /* 10.5.2.15 */
228 { 0x00, "IA Rest Octets" }, /* [3] 10.5.2.16 */
229 { 0x00, "IAR Rest Octets" }, /* [3] 10.5.2.17 IAR Rest Octets */
230 { 0x00, "IAX Rest Octets" }, /* [3] 10.5.2.18 IAX Rest Octets */
231 { 0x00, "L2 Pseudo Length" }, /* [3] 10.5.2.19 */
232 { 0x00, "Measurement Results" }, /* [3] 10.5.2.20 Measurement Results */
234 * [3] 10.5.2.20a GPRS Measurement Results
236 { 0x00, "Mobile Allocation" }, /* [3] 10.5.2.21 */
237 { 0x00, "Mobile Time Difference" }, /* [3] 10.5.2.21a */
238 { 0x00, "MultiRate configuration" }, /* [3] 10.5.2.21aa */
240 { 0x00, "Multislot Allocation" }, /* [3] 10.5.2.21b */
242 * [3] 10.5.2.21c NC mode
244 { 0x00, "Neighbour Cell Description" }, /* [3] 10.5.2.22 Neighbour Cell Description */
245 { 0x00, "Neighbour Cell Description 2" }, /* [3] 10.5.2.22a Neighbour Cell Description 2 */
247 * [3] 10.5.2.22b (void)
248 * [3] 10.5.2.22c NT/N Rest Octets */
249 { 0x00, "P1 Rest Octets" }, /* [3] 10.5.2.23 P1 Rest Octets */
250 { 0x00, "P2 Rest Octets" }, /* [3] 10.5.2.24 P2 Rest Octets */
251 { 0x00, "P3 Rest Octets" }, /* [3] 10.5.2.25 P3 Rest Octets */
252 { 0x00, "Packet Channel Description" }, /* [3] 10.5.2.25a */
253 { 0x00, "Dedicated mode or TBF" }, /* [3] 10.5.2.25b */
254 /* [3] 10.5.2.25c RR Packet Uplink Assignment
255 * [3] 10.5.2.25d RR Packet Downlink Assignment */
256 { 0x00, "Page Mode" }, /* [3] 10.5.2.26 */
258 * [3] 10.5.2.26a (void)
259 * [3] 10.5.2.26b (void)
260 * [3] 10.5.2.26c (void)
261 * [3] 10.5.2.26d (void)
263 { 0x00, "NCC Permitted" }, /* [3] 10.5.2.27 NCC Permitted */
264 { 0x00, "Power Command" }, /* 10.5.2.28 */
265 { 0x00, "Power Command and access type" }, /* 10.5.2.28a */
266 { 0x00, "RACH Control Parameters" }, /* [3] 10.5.2.29 RACH Control Parameters */
267 { 0x00, "Request Reference" }, /* [3] 10.5.2.30 Request Reference */
268 { 0x00, "RR Cause" }, /* 10.5.2.31 */
269 { 0x00, "Synchronization Indication" }, /* 10.5.2.39 */
270 { 0x00, "SI 1 Rest Octets" }, /* [3] 10.5.2.32 */
271 /* [3] 10.5.2.33 SI 2bis Rest Octets */
272 { 0x00, "SI 2ter Rest Octets" }, /* [3] 10.5.2.33a */
273 { 0x00, "SI 2quater Rest Octets" }, /* [3] 10.5.2.33b */
274 { 0x00, "SI 3 Rest Octets" }, /* [3] 10.5.2.34 */
275 { 0x00, "SI 4 Rest Octets" }, /* [3] 10.5.2.35 */
276 { 0x00, "SI 6 Rest Octets" }, /* [3] 10.5.2.35a */
277 /* [3] 10.5.2.36 SI 7 Rest Octets
278 * [3] 10.5.2.37 SI 8 Rest Octets
279 * [3] 10.5.2.37a SI 9 Rest Octets
281 { 0x00, "SI 13 Rest Octets" }, /* [3] 10.5.2.37b */
282 /* [3] 10.5.2.37c (void)
283 * [3] 10.5.2.37d (void)
284 * [3] 10.5.2.37e SI 16 Rest Octets
285 * [3] 10.5.2.37f SI 17 Rest Octets
286 * [3] 10.5.2.37g SI 19 Rest Octets
287 * [3] 10.5.2.37h SI 18 Rest Octets
288 * [3] 10.5.2.37i SI 20 Rest Octets */
289 { 0x00, "Starting Time" }, /* [3] 10.5.2.38 Starting Time */
290 { 0x00, "Timing Advance" }, /* [3] 10.5.2.40 Timing Advance */
291 { 0x00, "Time Difference" }, /* [3] 10.5.2.41 Time Difference */
292 { 0x00, "TLLI" }, /* [3] 10.5.2.41a TLLI */
293 { 0x00, "TMSI/P-TMSI" }, /* [3] 10.5.2.42 TMSI/P-TMSI */
294 { 0x00, "VGCS target mode Indication" }, /* [3] 10.5.2.42a */
296 { 0x00, "VGCS Ciphering Parameters" }, /* [3] 10.5.2.42b */
297 { 0x00, "Wait Indication" }, /* [3] 10.5.2.43 Wait Indication */
298 /* [3] 10.5.2.44 SI10 rest octets $(ASCI)$ */
299 { 0x00, "Extended Measurement Results" }, /* [3] 10.5.2.45 Extended Measurement Results */
300 { 0x00, "Extended Measurement Frequency List" }, /* [3] 10.5.2.46 Extended Measurement Frequency List */
301 { 0x00, "Suspension Cause" }, /* [3] 10.5.2.47 */
302 /* [3] 10.5.2.48 APDU ID
303 * [3] 10.5.2.49 APDU Flags
304 * [3] 10.5.2.50 APDU Data */
305 { 0x00, "Handover to UTRAN Command" }, /* [3] 10.5.2.51 Handover To UTRAN Command */
306 /* [3] 10.5.2.52 Handover To cdma2000 Command
307 * [3] 10.5.2.53 (void)
308 * [3] 10.5.2.54 (void)
309 * [3] 10.5.2.55 (void)
310 * [3] 10.5.2.56 3G Target Cell */
311 { 0x00, "Service Support" }, /* [3] 10.5.2.57 */
312 /* 10.5.2.58 MBMS p-t-m Channel Description */
313 { 0x00, "Dedicated Service Information" }, /* [3] 10.5.2.59 */
315 * 10.5.2.60 MPRACH Description
316 * 10.5.2.61 Restriction Timer
317 * 10.5.2.62 MBMS Session Identity
318 * 10.5.2.63 Reduced group or broadcast call reference
319 * 10.5.2.64 Talker Priority status
320 * 10.5.2.65 Talker Identity
323 * 10.5.2.68 VGCS AMR Configuration
325 { 0x00, "Carrier Indication" }, /* 10.5.2.69 Carrier Indication */
329 const value_string gsm_rr_rest_octets_elem_strings[] = {
330 /* RR Rest Octets information elements */
331 { 0, "UTRAN FDD Description" },
332 { 0, "UTRAN TDD Description" },
333 { 0, "3G Measurement Parameters Description" },
334 { 0, "3G Additional Measurement Parameters Description" },
335 { 0, "Measurement Parameters Description" },
336 { 0, "GPRS Real Time Difference Description" },
337 { 0, "GPRS BSIC Description" },
338 { 0, "GPRS Report Priority Description" },
339 { 0, "GPRS Measurement Parameters Description" },
340 { 0, "NC Measurement Parameters" },
341 { 0, "SI2q Extension Information" },
342 { 0, "CCN Support Description" },
343 { 0, "3G Neighbour Cell Description" },
344 { 0, "FDD Cell Information Field" },
345 { 0, "TDD Cell Information Field" },
346 { 0, "GPRS 3G Measurement Parameters Description" },
347 { 0, "3G Additional Measurement Parameters Description 2" },
348 { 0, "Optional Selection Parameters" },
349 { 0, "GPRS Indicator" },
350 { 0, "SI4 Rest Octets_O" },
351 { 0, "SI4 Rest Octets_S" },
352 { 0, "LSA Parameters" },
353 { 0, "LSA ID Information" },
354 { 0, "PCH and NCH Info" },
355 { 0, "VBS/VGCS Options" },
356 { 0, "GPRS Mobile Allocation" },
357 { 0, "GPRS Cell Options" },
358 { 0, "GPRS Cell Options Extension Information" },
359 { 0, "GPRS Power Control Parameters" },
360 { 0, "PBCCH Description" },
361 { 0, "GSM Description" },
362 { 0, "Real Time Difference Description" },
363 { 0, "BSIC Description" },
364 { 0, "Report Priority Description" },
365 { 0, "CDMA2000 Description" },
366 { 0, "Serving cell data" },
367 { 0, "Repeated Invalid BSIC Information" },
368 { 0, "Bitmap Type Reporting" },
373 /* RR cause value (octet 2) TS 44.018 6.11.0*/
374 static const value_string gsm_a_rr_RR_cause_vals[] = {
375 { 0, "Normal event"},
376 { 1, "Abnormal release, unspecified"},
377 { 2, "Abnormal release, channel unacceptable"},
378 { 3, "Abnormal release, timer expired"},
379 { 4, "Abnormal release, no activity on the radio path"},
380 { 5, "Preemptive release"},
381 { 6, "UTRAN configuration unknown"},
382 { 8, "Handover impossible, timing advance out of range"},
383 { 9, "Channel mode unacceptable"},
384 { 10, "Frequency not implemented"},
385 { 13, "Originator or talker leaving group call area"},
386 { 12, "Lower layer failure"},
387 { 0x41, "Call already cleared"},
388 { 0x5f, "Semantically incorrect message"},
389 { 0x60, "Invalid mandatory information"},
390 { 0x61, "Message type non-existent or not implemented"},
391 { 0x62, "Message type not compatible with protocol state"},
392 { 0x64, "Conditional IE error"},
393 { 0x65, "No cell allocation available"},
394 { 0x6f, "Protocol error unspecified"},
398 static const value_string gsm_a_algorithm_identifier_vals[] = {
399 { 0, "Cipher with algorithm A5/1"},
400 { 1, "Cipher with algorithm A5/2"},
401 { 2, "Cipher with algorithm A5/3"},
402 { 3, "Cipher with algorithm A5/4"},
403 { 4, "Cipher with algorithm A5/5"},
404 { 5, "Cipher with algorithm A5/6"},
405 { 6, "Cipher with algorithm A5/7"},
411 #define DTAP_PD_MASK 0x0f
412 #define DTAP_SKIP_MASK 0xf0
413 #define DTAP_TI_MASK DTAP_SKIP_MASK
414 #define DTAP_TIE_PRES_MASK 0x07 /* after TI shifted to right */
415 #define DTAP_TIE_MASK 0x7f
417 #define DTAP_RR_IEI_MASK 0xff
419 /* Initialize the protocol and registered fields */
420 static int proto_a_ccch = -1;
421 static int proto_a_sacch = -1;
423 static int hf_gsm_a_dtap_msg_rr_type = -1;
424 int hf_gsm_a_rr_elem_id = -1;
426 static int hf_gsm_a_sacch_msg_rr_type = -1;
428 static int hf_gsm_a_bcc = -1;
429 static int hf_gsm_a_ncc = -1;
430 static int hf_gsm_a_bcch_arfcn = -1;
431 static int hf_gsm_a_rr_range_nb = -1;
432 static int hf_gsm_a_rr_range_lower = -1;
433 static int hf_gsm_a_rr_range_higher = -1;
434 static int hf_gsm_a_rr_ba_list_pref_length = -1;
435 static int hf_gsm_a_rr_ba_freq = -1;
436 static int hf_gsm_a_rr_utran_freq_list_length = -1;
437 static int hf_gsm_a_rr_ho_ref_val = -1;
438 static int hf_gsm_a_rr_L2_pseudo_len = -1;
439 static int hf_gsm_a_rr_ba_used = -1;
440 static int hf_gsm_a_rr_dtx_used = -1;
441 static int hf_gsm_a_rr_3g_ba_used = -1;
442 static int hf_gsm_a_rr_meas_valid = -1;
443 static int hf_gsm_a_rr_rxlev_full_serv_cell = -1;
444 static int hf_gsm_a_rr_rxlev_sub_serv_cell = -1;
445 static int hf_gsm_a_rr_rxqual_full_serv_cell = -1;
446 static int hf_gsm_a_rr_rxqual_sub_serv_cell = -1;
447 static int hf_gsm_a_rr_no_ncell_m = -1;
448 static int hf_gsm_a_rr_rxlev_ncell = -1;
449 static int hf_gsm_a_rr_bcch_freq_ncell = -1;
450 static int hf_gsm_a_rr_bsic_ncell = -1;
451 static int hf_gsm_a_rr_mobile_time_difference = -1;
452 static int hf_gsm_a_rr_pow_cmd_atc = -1;
453 static int hf_gsm_a_rr_pow_cmd_epc = -1;
454 static int hf_gsm_a_rr_page_mode = -1;
455 static int hf_gsm_a_rr_dedicated_mode_or_tbf = -1;
456 static int hf_gsm_a_rr_pow_cmd_fpcepc = -1;
457 static int hf_gsm_a_rr_pow_cmd_powlev = -1;
458 static int hf_gsm_a_rr_sync_ind_nci = -1;
459 static int hf_gsm_a_rr_sync_ind_rot = -1;
460 static int hf_gsm_a_rr_sync_ind_si = -1;
461 static int hf_gsm_a_rr_format_id = -1;
462 static int hf_gsm_a_rr_channel_mode = -1;
463 static int hf_gsm_a_rr_channel_mode2 = -1;
464 static int hf_gsm_a_rr_sc = -1;
465 static int hf_gsm_a_algorithm_id = -1;
466 static int hf_gsm_a_rr_cr = -1;
467 static int hf_gsm_a_rr_multirate_speech_ver = -1;
468 static int hf_gsm_a_rr_NCSB = -1;
469 static int hf_gsm_a_rr_ICMI = -1;
470 static int hf_gsm_a_rr_start_mode = -1;
471 static int hf_gsm_a_rr_timing_adv = -1;
472 static int hf_gsm_a_rr_time_diff = -1;
473 static int hf_gsm_a_rr_tlli = -1;
474 static int hf_gsm_a_rr_tmsi_ptmsi = -1;
475 static int hf_gsm_a_rr_target_mode = -1;
476 static int hf_gsm_a_rr_wait_indication = -1;
477 static int hf_gsm_a_rr_seq_code = -1;
478 static int hf_gsm_a_rr_group_cipher_key_number = -1;
479 static int hf_gsm_a_rr_MBMS_multicast = -1;
480 static int hf_gsm_a_rr_MBMS_broadcast = -1;
481 static int hf_gsm_a_rr_last_segment = -1;
482 static int hf_gsm_a_rr_carrier_ind = -1;
483 static int hf_gsm_a_rr_ra = -1;
484 static int hf_gsm_a_rr_T1prim = -1;
485 static int hf_gsm_a_rr_T3 = -1;
486 static int hf_gsm_a_rr_T2 = -1;
487 static int hf_gsm_a_rr_rfn = -1;
488 static int hf_gsm_a_rr_RR_cause = -1;
489 static int hf_gsm_a_rr_cm_cng_msg_req = -1;
490 static int hf_gsm_a_rr_utran_cm_cng_msg_req = -1;
491 static int hf_gsm_a_rr_cdma200_cm_cng_msg_req = -1;
492 static int hf_gsm_a_rr_geran_iu_cm_cng_msg_req = -1;
493 int hf_gsm_a_rr_chnl_needed_ch1 = -1;
494 static int hf_gsm_a_rr_chnl_needed_ch2 = -1;
495 static int hf_gsm_a_rr_chnl_needed_ch3 = -1;
496 static int hf_gsm_a_rr_chnl_needed_ch4 = -1;
497 static int hf_gsm_a_rr_suspension_cause = -1;
498 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b8 = -1;
499 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b7 = -1;
500 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b6 = -1;
501 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b5 = -1;
502 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b4 = -1;
503 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b3 = -1;
504 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b2 = -1;
505 static int hf_gsm_a_rr_set_of_amr_codec_modes_v1_b1 = -1;
506 static int hf_gsm_a_rr_set_of_amr_codec_modes_v2_b5 = -1;
507 static int hf_gsm_a_rr_set_of_amr_codec_modes_v2_b4 = -1;
508 static int hf_gsm_a_rr_set_of_amr_codec_modes_v2_b3 = -1;
509 static int hf_gsm_a_rr_set_of_amr_codec_modes_v2_b2 = -1;
510 static int hf_gsm_a_rr_set_of_amr_codec_modes_v2_b1 = -1;
511 static int hf_gsm_a_rr_amr_threshold = -1;
512 static int hf_gsm_a_rr_amr_hysteresis = -1;
513 static int hf_gsm_a_rr_pwrc = -1;
514 static int hf_gsm_a_rr_dtx_bcch = -1;
515 static int hf_gsm_a_rr_dtx_sacch = -1;
516 static int hf_gsm_a_rr_radio_link_timeout = -1;
517 static int hf_gsm_a_rr_cell_reselect_hyst = -1;
518 static int hf_gsm_a_rr_ms_txpwr_max_cch = -1;
519 static int hf_gsm_a_rr_acs = -1;
520 static int hf_gsm_a_rr_neci = -1;
521 static int hf_gsm_a_rr_rxlev_access_min = -1;
522 static int hf_gsm_a_rr_mscr = -1;
523 static int hf_gsm_a_rr_att = -1;
524 static int hf_gsm_a_rr_ccch_conf = -1;
525 static int hf_gsm_a_rr_cbq3 = -1;
526 static int hf_gsm_a_rr_bs_pa_mfrms = -1;
527 static int hf_gsm_a_rr_bs_ag_blks_res = -1;
528 static int hf_gsm_a_rr_t3212 = -1;
529 static int hf_gsm_a_rr_dyn_arfcn_length = -1;
530 static int hf_gsm_a_rr_gsm_band = -1;
531 static int hf_gsm_a_rr_arfcn_first = -1;
532 static int hf_gsm_a_rr_band_offset = -1;
533 static int hf_gsm_a_rr_arfcn_range = -1;
534 static int hf_gsm_a_rr_lowest_arfcn = -1;
535 static int hf_gsm_a_rr_inc_skip_arfcn = -1;
536 static int hf_gsm_a_rr_gprs_resumption_ack = -1;
537 static int hf_gsm_a_rr_ext_ind = -1;
538 static int hf_gsm_a_rr_ba_ind = -1;
539 static int hf_gsm_a_rr_multiband_reporting = -1;
540 static int hf_gsm_a_rr_ncc_permitted = -1;
541 static int hf_gsm_a_rr_max_retrans = -1;
542 static int hf_gsm_a_rr_tx_integer = -1;
543 static int hf_gsm_a_rr_cell_barr_access = -1;
544 static int hf_gsm_a_rr_re = -1;
545 static int hf_gsm_a_rr_acc = -1;
546 static int hf_gsm_a_rr_nch_position = -1;
547 static int hf_gsm_a_rr_si2ter_mp_change_mark = -1;
548 static int hf_gsm_a_rr_si2ter_3g_change_mark = -1;
549 static int hf_gsm_a_rr_si2ter_index = -1;
550 static int hf_gsm_a_rr_si2ter_count = -1;
551 static int hf_gsm_a_rr_fdd_uarfcn = -1;
552 static int hf_gsm_a_rr_bandwidth_fdd = -1;
553 static int hf_gsm_a_rr_tdd_uarfcn = -1;
554 static int hf_gsm_a_rr_bandwidth_tdd = -1;
555 static int hf_gsm_a_rr_arfcn = -1;
556 static int hf_gsm_a_rr_bsic = -1;
557 static int hf_gsm_a_rr_qsearch_i = -1;
558 static int hf_gsm_a_rr_fdd_qoffset = -1;
559 static int hf_gsm_a_rr_fdd_qmin = -1;
560 static int hf_gsm_a_rr_tdd_qoffset = -1;
561 static int hf_gsm_a_rr_fdd_qmin_offset = -1;
562 static int hf_gsm_a_rr_fdd_rscpmin = -1;
563 static int hf_gsm_a_rr_3g_ba_ind = -1;
564 static int hf_gsm_a_rr_mp_change_mark = -1;
565 static int hf_gsm_a_rr_si2quater_index = -1;
566 static int hf_gsm_a_rr_si2quater_count = -1;
567 static int hf_gsm_a_rr_gsm_report_type = -1;
568 static int hf_gsm_a_rr_serving_band_reporting = -1;
569 static int hf_gsm_a_rr_frequency_scrolling = -1;
570 static int hf_gsm_a_rr_rep_priority = -1;
571 static int hf_gsm_a_rr_report_type = -1;
572 static int hf_gsm_a_rr_reporting_rate = -1;
573 static int hf_gsm_a_rr_invalid_bsic_reporting = -1;
574 static int hf_gsm_a_rr_scale_ord = -1;
575 static int hf_gsm_a_rr_900_reporting_offset = -1;
576 static int hf_gsm_a_rr_900_reporting_threshold = -1;
577 static int hf_gsm_a_rr_1800_reporting_offset = -1;
578 static int hf_gsm_a_rr_1800_reporting_threshold = -1;
579 static int hf_gsm_a_rr_400_reporting_offset = -1;
580 static int hf_gsm_a_rr_400_reporting_threshold = -1;
581 static int hf_gsm_a_rr_1900_reporting_offset = -1;
582 static int hf_gsm_a_rr_1900_reporting_threshold = -1;
583 static int hf_gsm_a_rr_850_reporting_offset = -1;
584 static int hf_gsm_a_rr_850_reporting_threshold = -1;
585 static int hf_gsm_a_rr_network_control_order = -1;
586 static int hf_gsm_a_rr_nc_non_drx_period = -1;
587 static int hf_gsm_a_rr_nc_reporting_period_i = -1;
588 static int hf_gsm_a_rr_nc_reporting_period_t = -1;
589 static int hf_gsm_a_rr_index_start_3g = -1;
590 static int hf_gsm_a_rr_absolute_index_start_emr = -1;
591 static int hf_gsm_a_rr_qsearch_c_initial = -1;
592 static int hf_gsm_a_rr_fdd_rep_quant = -1;
593 static int hf_gsm_a_rr_fdd_multirat_reporting = -1;
594 static int hf_gsm_a_rr_tdd_multirat_reporting = -1;
595 static int hf_gsm_a_rr_qsearch_p = -1;
596 static int hf_gsm_a_rr_3g_search_prio = -1;
597 static int hf_gsm_a_rr_fdd_reporting_offset = -1;
598 static int hf_gsm_a_rr_fdd_reporting_threshold = -1;
599 static int hf_gsm_a_rr_tdd_reporting_offset = -1;
600 static int hf_gsm_a_rr_tdd_reporting_threshold = -1;
601 static int hf_gsm_a_rr_fdd_reporting_threshold_2 = -1;
602 static int hf_gsm_a_rr_3g_ccn_active = -1;
603 static int hf_gsm_a_rr_700_reporting_offset = -1;
604 static int hf_gsm_a_rr_700_reporting_threshold = -1;
605 static int hf_gsm_a_rr_810_reporting_offset = -1;
606 static int hf_gsm_a_rr_810_reporting_threshold = -1;
607 static int hf_gsm_a_rr_cbq = -1;
608 static int hf_gsm_a_rr_cell_reselect_offset = -1;
609 static int hf_gsm_a_rr_temporary_offset = -1;
610 static int hf_gsm_a_rr_penalty_time = -1;
611 static int hf_gsm_a_rr_si13_position = -1;
612 static int hf_gsm_a_rr_power_offset = -1;
613 static int hf_gsm_a_rr_si2quater_position = -1;
614 static int hf_gsm_a_rr_si13alt_position = -1;
615 static int hf_gsm_a_rr_prio_thr = -1;
616 static int hf_gsm_a_rr_lsa_offset = -1;
617 static int hf_gsm_a_rr_paging_channel_restructuring = -1;
618 static int hf_gsm_a_rr_nln_sacch = -1;
619 static int hf_gsm_a_rr_nln_status_sacch = -1;
620 static int hf_gsm_a_rr_nln_pch = -1;
621 static int hf_gsm_a_rr_nln_status_pch = -1;
622 static int hf_gsm_a_rr_vbs_vgcs_inband_notifications = -1;
623 static int hf_gsm_a_rr_vbs_vgcs_inband_pagings = -1;
624 static int hf_gsm_a_rr_rac = -1;
625 static int hf_gsm_a_rr_max_lapdm = -1;
626 static int hf_gsm_a_rr_gprs_ms_txpwr_max_ccch = -1;
627 static int hf_gsm_a_rr_dedicated_mode_mbms_notification_support = -1;
628 static int hf_gsm_a_rr_mnci_support = -1;
629 static int hf_gsm_a_rr_amr_config = -1;
630 static int hf_gsm_a_rr_bcch_change_mark = -1;
631 static int hf_gsm_a_rr_si_change_field = -1;
632 static int hf_gsm_a_rr_si13_change_mark = -1;
633 static int hf_gsm_a_rr_hsn = -1;
634 static int hf_gsm_a_rr_rfl_number = -1;
635 static int hf_gsm_a_rr_arfcn_index = -1;
636 static int hf_gsm_a_rr_ma_length = -1;
637 static int hf_gsm_a_rr_psi1_repeat_period = -1;
638 static int hf_gsm_a_rr_pbcch_pb = -1;
639 static int hf_gsm_a_rr_pbcch_tsc = -1;
640 static int hf_gsm_a_rr_pbcch_tn = -1;
641 static int hf_gsm_a_rr_spgc_ccch_sup = -1;
642 static int hf_gsm_a_rr_priority_access_thr = -1;
643 static int hf_gsm_a_rr_nmo = -1;
644 static int hf_gsm_a_rr_t3168 = -1;
645 static int hf_gsm_a_rr_t3192 = -1;
646 static int hf_gsm_a_rr_drx_timer_max = -1;
647 static int hf_gsm_a_rr_access_burst_type = -1;
648 static int hf_gsm_a_rr_control_ack_type = -1;
649 static int hf_gsm_a_rr_bs_cv_max = -1;
650 static int hf_gsm_a_rr_pan_dec = -1;
651 static int hf_gsm_a_rr_pan_inc = -1;
652 static int hf_gsm_a_rr_pan_max = -1;
653 static int hf_gsm_a_rr_egprs_packet_channel_request = -1;
654 static int hf_gsm_a_rr_bep_period = -1;
655 static int hf_gsm_a_rr_pfc_feature_mode = -1;
656 static int hf_gsm_a_rr_dtm_support = -1;
657 static int hf_gsm_a_rr_bss_paging_coordination = -1;
658 static int hf_gsm_a_rr_ccn_active = -1;
659 static int hf_gsm_a_rr_nw_ext_utbf = -1;
660 static int hf_gsm_a_rr_multiple_tbf_capability = -1;
661 static int hf_gsm_a_rr_ext_utbf_no_data = -1;
662 static int hf_gsm_a_rr_dtm_enhancements_capability = -1;
663 static int hf_gsm_a_rr_reduced_latency_access = -1;
664 static int hf_gsm_a_rr_alpha = -1;
665 static int hf_gsm_a_rr_t_avg_w = -1;
666 static int hf_gsm_a_rr_t_avg_t = -1;
667 static int hf_gsm_a_rr_pc_meas_chan = -1;
668 static int hf_gsm_a_rr_n_avg_i = -1;
669 static int hf_gsm_a_rr_sgsnr = -1;
670 static int hf_gsm_a_rr_si_status_ind = -1;
671 static int hf_gsm_a_rr_lb_ms_txpwr_max_cch = -1;
672 static int hf_gsm_a_rr_si2n_support = -1;
673 static int hf_gsm_a_rr_mi_index = -1;
674 static int hf_gsm_a_rr_mi_count = -1;
675 static int hf_gsm_a_rr_3g_wait = -1;
676 static int hf_gsm_a_rr_qsearch_c = -1;
677 static int hf_gsm_a_rr_bsic_seen = -1;
678 static int hf_gsm_a_rr_scale = -1;
679 static int hf_gsm_a_rr_mean_bep_gmsk = -1;
680 static int hf_gsm_a_rr_mean_cv_bep = -1;
681 static int hf_gsm_a_rr_nbr_rcvd_blocks = -1;
682 static int hf_gsm_a_rr_reporting_quantity = -1;
684 /* Initialize the subtree pointers */
685 static gint ett_ccch_msg = -1;
686 static gint ett_ccch_oct_1 = -1;
687 static gint ett_sacch_msg = -1;
689 static char a_bigbuf[1024];
691 static dissector_handle_t data_handle;
695 #define NUM_GSM_RR_ELEM (sizeof(gsm_rr_elem_strings)/sizeof(value_string))
696 gint ett_gsm_rr_elem[NUM_GSM_RR_ELEM];
700 /* RR Rest Octets information elements */
701 DE_RR_REST_OCTETS_UTRAN_FDD_DESC,
702 DE_RR_REST_OCTETS_UTRAN_TDD_DESC,
703 DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC,
704 DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC,
705 DE_RR_REST_OCTETS_MEAS_PARAM_DESC,
706 DE_RR_REST_OCTETS_GPRS_RTD_DESC,
707 DE_RR_REST_OCTETS_GPRS_BSIC_DESC,
708 DE_RR_REST_OCTETS_GPRS_REPORT_PRIO_DESC,
709 DE_RR_REST_OCTETS_GPRS_MEAS_PARAM_DESC,
710 DE_RR_REST_OCTETS_NC_MEAS_PARAM,
711 DE_RR_REST_OCTETS_SI2Q_EXT_INFO,
712 DE_RR_REST_OCTETS_CCN_SUPPORT_DESC,
713 DE_RR_REST_OCTETS_3G_NEIGH_CELL_DESC,
714 DE_RR_REST_OCTETS_FDD_CELL_INFORMATION_FIELD,
715 DE_RR_REST_OCTETS_TDD_CELL_INFORMATION_FIELD,
716 DE_RR_REST_OCTETS_GPRS_3G_MEAS_PARAM_DESC,
717 DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC2,
718 DE_RR_REST_OCTETS_OPTIONAL_SEL_PARAM,
719 DE_RR_REST_OCTETS_GPRS_INDICATOR,
720 DE_RR_REST_OCTETS_SI4_REST_OCTETS_O,
721 DE_RR_REST_OCTETS_SI4_REST_OCTETS_S,
722 DE_RR_REST_OCTETS_LSA_PARAMETERS,
723 DE_RR_REST_OCTETS_LSA_ID_INFO,
724 DE_RR_REST_OCTETS_PCH_AND_NCH_INFO,
725 DE_RR_REST_OCTETS_VBS_VGCS_OPTIONS,
726 DE_RR_REST_OCTETS_GPRS_MOBILE_ALLOC,
727 DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS,
728 DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS_EXT_INFO,
729 DE_RR_REST_OCTETS_GPRS_POWER_CONTROL_PARAMS,
730 DE_RR_REST_OCTETS_PBCCH_DESC,
731 DE_RR_REST_OCTETS_GSM_DESC,
732 DE_RR_REST_OCTETS_RTD_DESC,
733 DE_RR_REST_OCTETS_BSIC_DESC,
734 DE_RR_REST_OCTETS_REPORT_PRIO_DESC,
735 DE_RR_REST_OCTETS_CDMA2000_DESC,
736 DE_RR_REST_OCTETS_SERVING_CELL_DATA,
737 DE_RR_REST_OCTETS_REPEAT_INV_BSIC_INFO,
738 DE_RR_REST_OCTETS_BITMAP_TYPE_REPORTING,
739 DE_RR_REST_OCTETS_NONE
741 rr_rest_octets_elem_idx_t;
743 #define NUM_GSM_RR_REST_OCTETS_ELEM (sizeof(gsm_rr_rest_octets_elem_strings)/sizeof(value_string))
744 gint ett_gsm_rr_rest_octets_elem[NUM_GSM_RR_REST_OCTETS_ELEM];
747 10.5.2 Radio Resource management information elements
748 * [3] 10.5.2.1a BA Range
751 de_rr_ba_range(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
757 curr_offset = offset;
758 proto_tree_add_item(tree, hf_gsm_a_rr_range_nb, tvb, curr_offset, 1, FALSE);
759 value = tvb_get_guint8(tvb, curr_offset);
761 bit_offset = curr_offset << 3;
764 proto_tree_add_bits_item(tree, hf_gsm_a_rr_range_lower, tvb, bit_offset, 10, FALSE);
766 proto_tree_add_bits_item(tree, hf_gsm_a_rr_range_higher, tvb, bit_offset, 10, FALSE);
771 curr_offset += len - 1;
772 return (curr_offset - offset);
776 * [3] 10.5.2.1b Cell Channel Description
779 #define ARFCN_MAX 1024 /* total number of ARFCNs defined */
781 static void display_channel_list(guint8 *list, tvbuff_t *tvb, proto_tree *tree, guint32 offset)
786 ti = proto_tree_add_text(tree, tvb, 0, offset, "List of ARFCNs =");
787 for (arfcn=0; arfcn<ARFCN_MAX; arfcn++) {
789 proto_item_append_text(ti, " %d", arfcn);
795 static gint greatest_power_of_2_lesser_or_equal_to(gint index)
805 static gint f_k(gint k, gint *w, gint range)
811 range = range/greatest_power_of_2_lesser_or_equal_to(index);
815 j = greatest_power_of_2_lesser_or_equal_to(index);
817 if ((2*index) < 3*j){ /* left child */
819 n = (n+w[index]-1+((range-1)/2)+1)%range;
821 else { /* right child */
823 n = (n+w[index]-1+1)%range;
830 static void dissect_channel_list_n_range(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gint range)
832 gint curr_offset=offset, f0, arfcn_orig, bits, w[64], wsize, i, wi;
833 gint octet, nwi=1, jwi=0, wbits, imax, iused, arfcn;
836 memset((void*)list,0,sizeof(list));
838 octet = tvb_get_guint8(tvb, curr_offset++);
849 arfcn_orig = (octet&1);
850 arfcn_orig = (arfcn_orig << 8) + tvb_get_guint8(tvb, curr_offset++);
851 octet = tvb_get_guint8(tvb, curr_offset++);
852 arfcn_orig = (arfcn_orig << 1) + (octet>>7);
853 list[arfcn_orig] = 1;
871 DISSECTOR_ASSERT_NOT_REACHED();
874 iused = imax; /* in case the list is actually full */
876 /* extract the variable size w[] elements */
877 for (i=1; i<=imax; i++) {
878 wi = octet & ~(0xff<<bits); /* mask "bits" low bits to start wi from existing octet */
880 if (wsize>wbits) { /* need to extract more bits from the next octet */
881 octet = tvb_get_guint8(tvb, curr_offset++);
882 wi = (wi << 8) + octet;
887 if (wbits>wsize) { /* now we have too many bits - save some */
888 bits = wbits - wsize;
891 else /* just right number of bits */
895 if ((w[i]==0) || ((curr_offset-offset)>len)) {
897 break; /* all remaining elements must also be zero */
900 if (++jwi==nwi) { /* check if the number of wi at this wsize has been extracted */
901 jwi = 0; /* reset the count of wi at this size */
902 nwi <<= 1; /* get twice as many of the next size */
903 wsize--; /* make the next size 1 bit smaller */
907 for (i=1; i<=iused; i++) {
908 arfcn = (f_k(i, w, range) + arfcn_orig)%1024;
912 display_channel_list(list, tvb, tree, offset);
918 dissect_arfcn_list(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
925 curr_offset = offset;
927 oct = tvb_get_guint8(tvb, curr_offset);
929 /* FORMAT-ID, Format Identifier (part of octet 3)*/
930 proto_tree_add_item(tree, hf_gsm_a_rr_format_id, tvb, curr_offset, 1, FALSE);
932 if ((oct & 0xc0) == 0x00)
935 item = proto_tree_add_text(tree,tvb, curr_offset, len, "List of ARFCNs =");
938 for (byte = 0;byte <= len-1;byte++)
940 oct = tvb_get_guint8(tvb, curr_offset);
944 if (((oct >> bit) & 1) == 1)
946 proto_item_append_text(item," %d",arfcn);
953 else if ((oct & 0xc8) == 0x80)
956 dissect_channel_list_n_range(tvb, tree, curr_offset, len, 1024);
957 curr_offset = curr_offset + len;
959 else if ((oct & 0xce) == 0x88)
962 dissect_channel_list_n_range(tvb, tree, curr_offset, len, 512);
963 curr_offset = curr_offset + len;
965 else if ((oct & 0xce) == 0x8a)
968 dissect_channel_list_n_range(tvb, tree, curr_offset, len, 256);
969 curr_offset = curr_offset + len;
971 else if ((oct & 0xce) == 0x8c)
974 dissect_channel_list_n_range(tvb, tree, curr_offset, len, 128);
975 curr_offset = curr_offset + len;
977 else if ((oct & 0xce) == 0x8e)
979 /* variable bit map */
980 arfcn = ((oct & 0x01) << 9) | (tvb_get_guint8(tvb, curr_offset+1) << 1) | ((tvb_get_guint8(tvb, curr_offset + 2) & 0x80) >> 7);
981 item = proto_tree_add_text(tree,tvb,curr_offset,len,"List of ARFCNs = %d",arfcn);
982 curr_offset = curr_offset + 2;
984 for (byte = 0;byte <= len-3;byte++)
986 oct = tvb_get_guint8(tvb, curr_offset);
990 if (((oct >> bit) & 1) == 1)
992 proto_item_append_text(item," %d",arfcn);
1000 return(curr_offset - offset);
1004 de_rr_cell_ch_dsc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1006 return dissect_arfcn_list(tvb, tree, offset, 16, add_string, string_len);
1009 * [3] 10.5.2.1c BA List Pref
1012 de_rr_ba_list_pref(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
1014 guint32 curr_offset;
1018 curr_offset = offset;
1019 proto_tree_add_item(tree, hf_gsm_a_rr_ba_list_pref_length, tvb, curr_offset, 1, FALSE);
1021 bit_offset = curr_offset << 3;
1022 value = tvb_get_bits8(tvb,bit_offset,1);
1026 proto_tree_add_bits_item(tree, hf_gsm_a_rr_range_lower, tvb, bit_offset, 10, FALSE);
1028 proto_tree_add_bits_item(tree, hf_gsm_a_rr_range_higher, tvb, bit_offset, 10, FALSE);
1030 value = tvb_get_bits8(tvb,bit_offset,1);
1033 value = tvb_get_bits8(tvb,bit_offset,1);
1037 proto_tree_add_bits_item(tree, hf_gsm_a_rr_ba_freq, tvb, bit_offset, 10, FALSE);
1039 value = tvb_get_bits8(tvb,bit_offset,1);
1043 curr_offset += len - 1;
1044 return (curr_offset - offset);
1048 * [3] 10.5.2.1d UTRAN Frequency List
1051 de_rr_utran_freq_list(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
1053 guint32 curr_offset;
1057 curr_offset = offset;
1058 proto_tree_add_item(tree, hf_gsm_a_rr_utran_freq_list_length, tvb, curr_offset, 1, FALSE);
1060 bit_offset = curr_offset << 3;
1061 value = tvb_get_bits8(tvb,bit_offset,1);
1065 proto_tree_add_bits_item(tree, hf_gsm_a_rr_fdd_uarfcn, tvb, bit_offset, 14, FALSE);
1067 value = tvb_get_bits8(tvb,bit_offset,1);
1070 value = tvb_get_bits8(tvb,bit_offset,1);
1074 proto_tree_add_bits_item(tree, hf_gsm_a_rr_tdd_uarfcn, tvb, bit_offset, 14, FALSE);
1076 value = tvb_get_bits8(tvb,bit_offset,1);
1080 curr_offset += len - 1;
1081 return (curr_offset - offset);
1085 * [3] 10.5.2.1e Cell selection indicator after release of all TCH and SDCCH
1088 convert_n_to_p[32] = { 0, 10, 19, 28, 26, 44, 52, 60, 67, 74, 81, 88, 95, 102, 109, 116,
1089 122, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
1092 convert_n_to_q[32] = { 0, 9, 17, 25, 32, 39, 46, 53, 59, 65, 71, 77, 83, 89, 95, 101,
1093 106, 111, 116, 121, 126, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
1096 de_rr_cell_select_indic(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1098 proto_tree *subtree, *subtree2;
1099 proto_item *item, *item2;
1100 guint32 curr_offset;
1101 gint bit_offset, bit_offset_sav, idx, xdd_cell_info, wsize, nwi, jwi, w[64], i, iused, xdd_indic0;
1102 guint8 value, length;
1104 curr_offset = offset;
1105 length = tvb_get_guint8(tvb, curr_offset);
1107 bit_offset = curr_offset << 3;
1108 value = tvb_get_bits8(tvb,bit_offset,3);
1112 case 0: /* GSM Description */
1113 bit_offset_sav = bit_offset;
1114 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GSM_DESC].strptr);
1115 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GSM_DESC]);
1116 value = tvb_get_bits8(tvb,bit_offset,1);
1120 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Band Indicator: %s",tvb_get_bits8(tvb,bit_offset,1) ? "1900" : "1800");
1122 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_arfcn, tvb, bit_offset, 10, FALSE);
1124 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bsic, tvb, bit_offset, 6, FALSE);
1126 value = tvb_get_bits8(tvb,bit_offset,1);
1129 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
1131 case 1: /* UTRAN FDD Description */
1132 bit_offset_sav = bit_offset;
1133 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_FDD_DESC].strptr);
1134 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_FDD_DESC]);
1135 value = tvb_get_bits8(tvb,bit_offset,1);
1139 if (tvb_get_bits8(tvb,bit_offset,1))
1142 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bandwidth_fdd, tvb, bit_offset, 3, FALSE);
1147 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_uarfcn, tvb, bit_offset, 14, FALSE);
1149 if (tvb_get_bits8(tvb,bit_offset,1))
1152 xdd_indic0 = tvb_get_bits8(tvb,bit_offset,1);
1153 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "FDD Indic0: %d", xdd_indic0);
1155 idx = tvb_get_bits8(tvb,bit_offset,5);
1156 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Nr of FDD Cells : %d", idx);
1158 idx = convert_n_to_p[idx];
1159 item2 = proto_tree_add_text(subtree,tvb, bit_offset>>3, (idx>>3)+1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_FDD_DESC].strptr);
1160 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_FDD_CELL_INFORMATION_FIELD]);
1161 proto_tree_add_text(subtree2,tvb, bit_offset>>3, (idx>>3)+1, "Field is %d bits long", idx);
1164 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Scrambling Code: %d", 0);
1165 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Diversity: %d", 0);
1176 w[i] = tvb_get_bits16(tvb, bit_offset, wsize, FALSE);
1177 bit_offset += wsize;
1198 for (i=1; i <= iused; i++)
1200 xdd_cell_info = f_k(i, w, 1024);
1201 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Scrambling Code: %d", xdd_cell_info & 0x01FF);
1202 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Diversity: %d", (xdd_cell_info >> 9) & 0x01);
1208 value = tvb_get_bits8(tvb,bit_offset,1);
1211 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
1213 case 2: /* UTRAN TDD Description */
1214 bit_offset_sav = bit_offset;
1215 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_TDD_DESC].strptr);
1216 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_TDD_DESC]);
1217 value = tvb_get_bits8(tvb,bit_offset,1);
1221 if (tvb_get_bits8(tvb,bit_offset,1))
1224 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bandwidth_tdd, tvb, bit_offset, 3, FALSE);
1229 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_tdd_uarfcn, tvb, bit_offset, 14, FALSE);
1231 if (tvb_get_bits8(tvb,bit_offset,1))
1234 xdd_indic0 = tvb_get_bits8(tvb,bit_offset,1);
1235 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "TDD Indic0: %d", xdd_indic0);
1237 idx = tvb_get_bits8(tvb,bit_offset,5);
1238 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Nr of TDD Cells : %d", idx);
1240 idx = convert_n_to_q[idx];
1241 item2 = proto_tree_add_text(subtree,tvb, bit_offset>>3, (idx>>3)+1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_TDD_DESC].strptr);
1242 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_TDD_CELL_INFORMATION_FIELD]);
1243 proto_tree_add_text(subtree2,tvb, bit_offset>>3, (idx>>3)+1, "Field is %d bits long", idx);
1246 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Cell Parameter: %d", 0);
1247 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Sync Case TSTD: %d", 0);
1248 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Diversity TDD: %d", 0);
1259 w[i] = tvb_get_bits16(tvb, bit_offset, wsize, FALSE);
1260 bit_offset += wsize;
1281 for (i=1; i <= iused; i++)
1283 xdd_cell_info = f_k(i, w, 512);
1284 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Cell Parameter: %d", xdd_cell_info & 0x07F);
1285 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Sync Case TSTD: %d", (xdd_cell_info >> 7) & 0x01);
1286 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 0, "Diversity TDD: %d", (xdd_cell_info >> 8) & 0x01);
1292 value = tvb_get_bits8(tvb,bit_offset,1);
1295 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
1301 curr_offset += length;
1302 return (curr_offset - offset);
1306 * [3] 10.5.2.2 Cell Description
1309 de_rr_cell_dsc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1311 proto_tree *subtree;
1314 guint32 curr_offset;
1317 curr_offset = offset;
1319 oct = tvb_get_guint8(tvb, curr_offset);
1321 proto_tree_add_text(tree,
1322 tvb, curr_offset, 2, "%s",
1323 gsm_rr_elem_strings[DE_RR_CELL_DSC].strptr);
1325 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CELL_DSC]);
1327 proto_tree_add_item(subtree, hf_gsm_a_ncc, tvb, curr_offset, 1, FALSE);
1328 proto_tree_add_item(subtree, hf_gsm_a_bcc, tvb, curr_offset, 1, FALSE);
1329 bcch_arfcn = (tvb_get_guint8(tvb,curr_offset) & 0xc0) << 2;
1330 bcch_arfcn = bcch_arfcn | tvb_get_guint8(tvb,curr_offset+1);
1331 proto_tree_add_uint(subtree, hf_gsm_a_bcch_arfcn , tvb, curr_offset, 2, bcch_arfcn );
1333 curr_offset = curr_offset + 2;
1335 return(curr_offset - offset);
1339 * [3] 10.5.2.3 Cell Options (BCCH)
1341 static const value_string gsm_a_rr_dtx_bcch_vals[] = {
1342 { 0x00, "The MSs may use uplink discontinuous transmission" },
1343 { 0x01, "The MSs shall use uplink discontinuous transmission" },
1344 { 0x02, "The MSs shall not use uplink discontinuous transmission" },
1345 { 0x03, "Reserved" },
1348 static const value_string gsm_a_rr_radio_link_timeout_vals[] = {
1368 de_rr_cell_opt_bcch(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1370 proto_tree *subtree;
1372 guint32 curr_offset;
1374 curr_offset = offset;
1376 item = proto_tree_add_text(tree, tvb, curr_offset, 1, "%s",
1377 gsm_rr_elem_strings[DE_RR_CELL_OPT_BCCH].strptr);
1379 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CELL_OPT_BCCH]);
1381 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pwrc, tvb, (curr_offset<<3)+1, 1, FALSE);
1382 proto_tree_add_item(subtree, hf_gsm_a_rr_dtx_bcch, tvb, curr_offset, 1, FALSE);
1383 proto_tree_add_item(subtree, hf_gsm_a_rr_radio_link_timeout, tvb, curr_offset, 1, FALSE);
1385 curr_offset = curr_offset + 1;
1387 return(curr_offset - offset);
1391 * [3] 10.5.2.3a Cell Options (SACCH)
1393 static const value_string gsm_a_rr_dtx_sacch_vals[] = {
1394 { 0x00, "The MS may use uplink discontinuous transmission on a TCH-F. The MS shall not use uplink discontinuous transmission on TCH-H" },
1395 { 0x01, "The MS shall use uplink discontinuous transmission on a TCH-F. The MS shall not use uplink discontinuous transmission on TCH-H" },
1396 { 0x02, "The MS shall not use uplink discontinuous transmission on a TCH-F. The MS shall not use uplink discontinuous transmission on TCH-H" },
1397 { 0x03, "The MS shall use uplink discontinuous transmission on a TCH-F. The MS may use uplink discontinuous transmission on TCH-H" },
1398 { 0x04, "The MS may use uplink discontinuous transmission on a TCH-F. The MS may use uplink discontinuous transmission on TCH-H" },
1399 { 0x05, "The MS shall use uplink discontinuous transmission on a TCH-F. The MS shall use uplink discontinuous transmission on TCH-H" },
1400 { 0x06, "The MS shall not use uplink discontinuous transmission on a TCH-F. The MS shall use uplink discontinuous transmission on TCH-H" },
1401 { 0x07, "The MS may use uplink discontinuous transmission on a TCH-F. The MS shall use uplink discontinuous transmission on TCH-H" },
1405 de_rr_cell_opt_sacch(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1407 proto_tree *subtree;
1411 guint32 curr_offset;
1413 curr_offset = offset;
1415 oct = tvb_get_guint8(tvb, curr_offset);
1416 dtx = ((oct&0x80)>>5)|((oct&0x30)>>4); /* DTX is a split filed in bits 8, 6 and 5 */
1417 item = proto_tree_add_text(tree, tvb, curr_offset, 1, "%s",
1418 gsm_rr_elem_strings[DE_RR_CELL_OPT_SACCH].strptr);
1420 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CELL_OPT_SACCH]);
1422 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pwrc, tvb, (curr_offset<<3)+1, 1, FALSE);
1423 proto_tree_add_uint(subtree, hf_gsm_a_rr_dtx_sacch, tvb, curr_offset, 1, dtx);
1424 proto_tree_add_item(subtree, hf_gsm_a_rr_radio_link_timeout, tvb, curr_offset, 1, FALSE);
1426 curr_offset = curr_offset + 1;
1428 return(curr_offset - offset);
1432 * [3] 10.5.2.4 Cell Selection Parameters
1435 de_rr_cell_sel_param(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1437 proto_tree *subtree;
1440 guint32 curr_offset;
1442 curr_offset = offset;
1444 oct = tvb_get_guint8(tvb, curr_offset);
1445 item = proto_tree_add_text(tree, tvb, curr_offset, 2, "%s",
1446 gsm_rr_elem_strings[DE_RR_CELL_SEL_PARAM].strptr);
1448 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CELL_SEL_PARAM]);
1450 proto_tree_add_item(subtree, hf_gsm_a_rr_cell_reselect_hyst, tvb, curr_offset, 1, FALSE);
1451 proto_tree_add_item(subtree, hf_gsm_a_rr_ms_txpwr_max_cch, tvb, curr_offset, 1, FALSE);
1453 curr_offset = curr_offset + 1;
1455 proto_tree_add_item(subtree, hf_gsm_a_rr_acs, tvb, curr_offset, 1, FALSE);
1456 proto_tree_add_item(subtree, hf_gsm_a_rr_neci, tvb, curr_offset, 1, FALSE);
1457 proto_tree_add_item(subtree, hf_gsm_a_rr_rxlev_access_min, tvb, curr_offset, 1, FALSE);
1459 curr_offset = curr_offset + 1;
1461 return(curr_offset - offset);
1465 * [3] 10.5.2.4a MAC Mode and Channel Coding Requested
1466 * [3] 10.5.2.5 Channel Description
1469 de_rr_ch_dsc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1471 guint32 curr_offset;
1472 guint8 oct8,subchannel;
1473 guint16 arfcn, hsn, maio;
1474 proto_tree *subtree;
1478 curr_offset = offset;
1480 item = proto_tree_add_text(tree,tvb, curr_offset, 3, "%s", gsm_rr_elem_strings[DE_RR_CH_DSC].strptr);
1482 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CH_DSC]);
1485 oct8 = tvb_get_guint8(tvb, curr_offset);
1487 if ((oct8 & 0xf8) == 0x08)
1489 str = "TCH/F + ACCHs";
1490 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1491 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s",a_bigbuf,str);
1495 if ((oct8 & 0xf0) == 0x10)
1497 str = "TCH/H + ACCHs, Subchannel";
1498 subchannel = ((oct8 & 0x08)>>3);
1500 else if ((oct8 & 0xe0) == 0x20)
1502 str = "SDCCH/4 + SACCH/C4 or CBCH (SDCCH/4), Subchannel";
1503 subchannel = ((oct8 & 0x18)>>3);
1505 else if ((oct8 & 0xc0) == 0x40)
1507 str = "SDCCH/8 + SACCH/C8 or CBCH (SDCCH/8), Subchannel";
1508 subchannel = ((oct8 % 0x38)>>3);
1512 DISSECTOR_ASSERT_NOT_REACHED();
1515 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1516 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s %d",a_bigbuf,str,subchannel);
1519 other_decode_bitfield_value(a_bigbuf, oct8, 0x07, 8);
1520 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Timeslot: %d",a_bigbuf,(oct8 & 0x07));
1525 oct8 = tvb_get_guint8(tvb, curr_offset);
1526 other_decode_bitfield_value(a_bigbuf, oct8, 0xe0, 8);
1527 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Training Sequence: %d",a_bigbuf,((oct8 & 0xe0)>>5));
1530 if ((oct8 & 0x10) == 0x10)
1532 /* Hopping sequence */
1533 maio = ((oct8 & 0x0f)<<2) | ((tvb_get_guint8(tvb,curr_offset+1) & 0xc0) >> 6);
1534 hsn = (tvb_get_guint8(tvb,curr_offset+1) & 0x3f);
1537 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1538 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1539 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: MAIO %d",maio);
1540 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: HSN %d",hsn);
1545 arfcn = ((oct8 & 0x03) << 8) | tvb_get_guint8(tvb,curr_offset+1);
1548 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1549 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1550 other_decode_bitfield_value(a_bigbuf, oct8, 0x0c, 8);
1551 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Spare",a_bigbuf);
1552 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Single channel : ARFCN %d",arfcn);
1555 curr_offset = curr_offset + 2;
1557 return(curr_offset - offset);
1560 * [3] 10.5.2.5a Channel Description 2
1563 de_rr_ch_dsc2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1565 guint32 curr_offset;
1566 guint8 oct8,subchannel;
1567 guint16 arfcn, hsn, maio;
1568 proto_tree *subtree;
1572 curr_offset = offset;
1574 item = proto_tree_add_text(tree,tvb, curr_offset, 3, "%s", gsm_rr_elem_strings[DE_RR_CH_DSC2].strptr);
1576 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CH_DSC2]);
1579 oct8 = tvb_get_guint8(tvb, curr_offset);
1581 if ((oct8 & 0xf8) == 0x0)
1583 str = "TCH/F + FACCH/F and SACCH/M";
1584 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1585 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s",a_bigbuf,str);
1587 else if ((oct8 & 0xf8) == 0x08)
1589 str = "TCH/F + FACCH/F and SACCH/F";
1590 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1591 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s",a_bigbuf,str);
1593 else if ((oct8 & 0xf8) == 0xf0)
1595 str = "TCH/F + FACCH/F and SACCH/M + bi- and unidirectional channels";
1596 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1597 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s",a_bigbuf,str);
1601 if ((oct8 & 0xf0) == 0x10)
1603 str = "TCH/H + ACCHs, Subchannel";
1604 subchannel = ((oct8 & 0x08)>>3);
1606 else if ((oct8 & 0xe0) == 0x20)
1608 str = "SDCCH/4 + SACCH/C4 or CBCH (SDCCH/4), Subchannel";
1609 subchannel = ((oct8 & 0x18)>>3);
1611 else if ((oct8 & 0xc0) == 0x40)
1613 str = "SDCCH/8 + SACCH/C8 or CBCH (SDCCH/8), Subchannel";
1614 subchannel = ((oct8 % 0x38)>>3);
1616 else if ((oct8 & 0xc0) == 0x80)
1618 str = "TCH/F + FACCH/F and SACCH/M + bidirectional channels at timeslot";
1619 subchannel = ((oct8 % 0x38)>>3);
1621 else if ((oct8 & 0xe0) == 0xc0)
1623 str = "TCH/F + FACCH/F and SACCH/M + unidirectional channels at timeslot";
1624 subchannel = ((oct8 % 0x38)>>3);
1628 DISSECTOR_ASSERT_NOT_REACHED();
1630 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
1631 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s %d",a_bigbuf,str,subchannel);
1634 other_decode_bitfield_value(a_bigbuf, oct8, 0x07, 8);
1635 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Timeslot: %d",a_bigbuf,(oct8 & 0x07));
1640 oct8 = tvb_get_guint8(tvb, curr_offset);
1641 other_decode_bitfield_value(a_bigbuf, oct8, 0xe0, 8);
1642 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Training Sequence: %d",a_bigbuf,((oct8 & 0xe0)>>5));
1644 if ((oct8 & 0x10) == 0x10)
1646 /* Hopping sequence */
1647 maio = ((oct8 & 0x0f)<<2) | ((tvb_get_guint8(tvb,curr_offset+1) & 0xc0) >> 6);
1648 hsn = (tvb_get_guint8(tvb,curr_offset+1) & 0x3f);
1651 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1652 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1653 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: MAIO %d",maio);
1654 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: HSN %d",hsn);
1659 arfcn = ((oct8 & 0x03) << 8) | tvb_get_guint8(tvb,curr_offset+1);
1662 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1663 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1664 other_decode_bitfield_value(a_bigbuf, oct8, 0x0c, 8);
1665 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Spare",a_bigbuf);
1666 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Single channel : ARFCN %d",arfcn);
1669 curr_offset = curr_offset + 2;
1671 return(curr_offset - offset);
1675 * [3] 10.5.2.5c Channel Description 3
1678 de_rr_ch_dsc3(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1680 guint32 curr_offset;
1682 guint16 arfcn, hsn, maio;
1683 proto_tree *subtree;
1687 curr_offset = offset;
1689 item = proto_tree_add_text(tree,tvb, curr_offset, 3, "%s", gsm_rr_elem_strings[DE_RR_CH_DSC3].strptr);
1691 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CH_DSC3]);
1694 oct8 = tvb_get_guint8(tvb, curr_offset);
1695 other_decode_bitfield_value(a_bigbuf, oct8, 0xe0, 8);
1696 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Training Sequence: %d",a_bigbuf,((oct8 & 0xe0)>>5));
1698 if ((oct8 & 0x10) == 0x10)
1700 /* Hopping sequence */
1701 maio = ((oct8 & 0x0f)<<2) | ((tvb_get_guint8(tvb,curr_offset+1) & 0xc0) >> 6);
1702 hsn = (tvb_get_guint8(tvb,curr_offset+1) & 0x3f);
1705 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1706 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1707 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: MAIO %d",maio);
1708 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: HSN %d",hsn);
1713 arfcn = ((oct8 & 0x03) << 8) | tvb_get_guint8(tvb,curr_offset+1);
1716 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
1717 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
1718 other_decode_bitfield_value(a_bigbuf, oct8, 0x0c, 8);
1719 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Spare",a_bigbuf);
1720 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Single channel : ARFCN %d",arfcn);
1723 curr_offset = curr_offset + 2;
1725 return(curr_offset - offset);
1729 * [3] 10.5.2.6 Channel Mode
1732 static const value_string gsm_a_rr_channel_mode_vals[] = {
1733 { 0x00, "signalling only"},
1734 { 0x01, "speech full rate or half rate version 1(GSM FR or GSM HR)"},
1735 { 0x21, "speech full rate or half rate version 2(GSM EFR)"},
1736 { 0x41, "speech full rate or half rate version 3(FR AMR or HR AMR)"},
1737 { 0x81, "speech full rate or half rate version 4(OFR AMR-WB or OHR AMR-WB)"},
1738 { 0x82, "speech full rate or half rate version 5(FR AMR-WB )"},
1739 { 0x83, "speech full rate or half rate version 6(OHR AMR )"},
1740 { 0x61, "data, 43.5 kbit/s (downlink)+14.5 kbps (uplink)"},
1741 { 0x62, "data, 29.0 kbit/s (downlink)+14.5 kbps (uplink)"},
1742 { 0x64, "data, 43.5 kbit/s (downlink)+29.0 kbps (uplink)"},
1743 { 0x67, "data, 14.5 kbit/s (downlink)+43.5 kbps (uplink)"},
1744 { 0x65, "data, 14.5 kbit/s (downlink)+29.0 kbps (uplink)"},
1745 { 0x66, "data, 29.0 kbit/s (downlink)+43.5 kbps (uplink)"},
1746 { 0x27, "data, 43.5 kbit/s radio interface rate"},
1747 { 0x63, "data, 32.0 kbit/s radio interface rate"},
1748 { 0x43, "data, 29.0 kbit/s radio interface rate"},
1749 { 0x0f, "data, 14.5 kbit/s radio interface rate"},
1750 { 0x03, "data, 12.0 kbit/s radio interface rate"},
1751 { 0x0b, "data, 6.0 kbit/s radio interface rate"},
1752 { 0x13, "data, 3.6 kbit/s radio interface rate"},
1757 de_rr_ch_mode(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1759 guint32 curr_offset;
1761 curr_offset = offset;
1763 proto_tree_add_item(tree, hf_gsm_a_rr_channel_mode, tvb, curr_offset, 1, FALSE);
1765 curr_offset = curr_offset + 1;
1767 return(curr_offset - offset);
1770 * [3] 10.5.2.7 Channel Mode 2
1773 static const value_string gsm_a_rr_channel_mode2_vals[] = {
1774 { 0x00, "signalling only"},
1775 { 0x05, "speech half rate version 1(GSM HR)"},
1776 { 0x25, "speech half rate version 2(GSM EFR)"},
1777 { 0x45, "speech half rate version 3(HR AMR)"},
1778 { 0x85, "speech half rate version 4(OHR AMR-WB)"},
1779 { 0x06, "speech half rate version 6(OHR AMR )"},
1780 { 0x0f, "data, 6.0 kbit/s radio interface rate"},
1781 { 0x17, "data, 3.6 kbit/s radio interface rate"},
1786 de_rr_ch_mode2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1788 guint32 curr_offset;
1790 curr_offset = offset;
1792 proto_tree_add_item(tree, hf_gsm_a_rr_channel_mode2, tvb, curr_offset, 1, FALSE);
1794 curr_offset = curr_offset + 1;
1796 return(curr_offset - offset);
1799 * [3] 10.5.2.7a UTRAN Classmark information element
1802 de_rr_utran_cm(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
1804 guint32 curr_offset;
1805 tvbuff_t *rrc_irat_ho_info_tvb;
1806 static packet_info p_info;
1808 curr_offset = offset;
1811 rrc_irat_ho_info_tvb = tvb_new_subset(tvb, curr_offset, len, len);
1812 if (rrc_irat_ho_info_handle)
1813 call_dissector(rrc_irat_ho_info_handle, rrc_irat_ho_info_tvb, &p_info, tree);
1817 return(curr_offset - offset);
1821 * [3] 10.5.2.7b (void)
1825 * [3] 10.5.2.7c Classmark Enquiry Mask
1827 * 0 CLASSMARK CHANGE message is requested
1828 * 1 CLASSMARK CHANGE message is not requested
1830 * 000 UTRAN CLASSMARK CHANGE message including status on predefined configurations (i.e. Sequence Description) is requested
1831 * 111 UTRAN CLASSMARK CHANGE message including status on predefined configurations (i.e. Sequence Description) is not requested.
1832 * All other values shall not be sent. If received, they shall be interpreted as '000'.
1834 * 0 CDMA2000 CLASSMARK CHANGE message requested
1835 * 1 CDMA2000 CLASSMARK CHANGE message not requested.
1837 * 0 GERAN IU MODE CLASSMARK CHANGE message requested
1838 * 1 GERAN IU MODE CLASSMARK CHANGE message not requested.
1839 * Bits 2 - 1: spare(0).
1841 static const true_false_string gsm_a_msg_req_value = {
1842 "message is not requested",
1843 "message is requested"
1846 static const value_string gsm_a_rr_utran_cm_cng_msg_req_vals[] = {
1847 { 0x0, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1848 { 0x1, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1849 { 0x2, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1850 { 0x3, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1851 { 0x4, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1852 { 0x5, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1853 { 0x6, "message including status on predefined configurations (i.e. Sequence Description) is requested"},
1854 { 0x7, "message including status on predefined configurations (i.e. Sequence Description) is not requested."},
1858 de_rr_cm_enq_mask(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1860 guint32 curr_offset;
1862 curr_offset = offset;
1864 proto_tree_add_item(tree, hf_gsm_a_rr_cm_cng_msg_req, tvb, curr_offset, 1, FALSE);
1865 proto_tree_add_item(tree, hf_gsm_a_rr_utran_cm_cng_msg_req, tvb, curr_offset, 1, FALSE);
1866 proto_tree_add_item(tree, hf_gsm_a_rr_cdma200_cm_cng_msg_req, tvb, curr_offset, 1, FALSE);
1867 proto_tree_add_item(tree, hf_gsm_a_rr_geran_iu_cm_cng_msg_req, tvb, curr_offset, 1, FALSE);
1869 curr_offset = curr_offset + 1;
1871 return(curr_offset - offset);
1874 * [3] 10.5.2.8 Channel Needed
1876 static const value_string gsm_a_rr_channel_needed_vals[] = {
1877 { 0x00, "Any channel"},
1879 { 0x02, "TCH/F (Full rate)"},
1880 { 0x03, "TCH/H or TCH/F (Dual rate)"},
1884 de_rr_chnl_needed(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1886 proto_tree *subtree;
1888 guint32 curr_offset;
1891 curr_offset = offset;
1892 if (UPPER_NIBBLE==len)
1897 item = proto_tree_add_text(tree, tvb, curr_offset, 3, "%s",
1898 gsm_rr_elem_strings[DE_RR_CHNL_NEEDED].strptr);
1900 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CHNL_NEEDED]);
1902 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_chnl_needed_ch1, tvb, (curr_offset<<3)+bit_offset+2, 2, FALSE);
1903 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_chnl_needed_ch2, tvb, (curr_offset<<3)+bit_offset, 2, FALSE);
1905 curr_offset = curr_offset + 1;
1907 return(curr_offset - offset);
1910 * [3] 10.5.2.8a Channel Request Description
1911 * [3] 10.5.2.8b Channel Request Description 2
1914 * [3] 10.5.2.9 Cipher Mode Setting
1917 static const value_string gsm_a_rr_sc_vals[] = {
1918 { 0, "No ciphering"},
1919 { 1, "Start ciphering"},
1922 /* algorithm identifier
1928 de_rr_cip_mode_set(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
1930 guint32 curr_offset;
1934 curr_offset = offset;
1936 /* Cipher Mode Setting
1937 * Note: The coding of fields SC and algorithm identifier is defined in [44.018]
1938 * as part of the Cipher Mode Setting IE.
1940 if (UPPER_NIBBLE==len)
1945 proto_tree_add_bits_ret_val(tree, hf_gsm_a_rr_sc, tvb, (curr_offset<<3)+bit_offset+3, 1, &value, FALSE);
1946 if (value == 1){ /* Start ciphering */
1947 /* algorithm identifier */
1948 proto_tree_add_bits_item(tree, hf_gsm_a_algorithm_id, tvb, (curr_offset<<3)+bit_offset, 3, FALSE);
1950 curr_offset = curr_offset + 1;
1952 return(curr_offset - offset);
1955 * [3] 10.5.2.10 Cipher Response
1958 static const value_string gsm_a_rr_cr_vals[] = {
1959 { 0, "IMEISV shall not be included"},
1960 { 1, "IMEISV shall be included"},
1965 de_rr_cip_mode_resp(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
1967 guint32 curr_offset;
1970 curr_offset = offset;
1971 if (UPPER_NIBBLE==len)
1976 /* Cipher Mode Response
1977 * Note: The coding of field CR is defined in [44.018]
1978 * as part of the Cipher Mode Response IE.
1980 proto_tree_add_bits_item(tree, hf_gsm_a_rr_cr, tvb, (curr_offset<<3)+bit_offset+3, 1, FALSE);
1981 curr_offset = curr_offset + 1;
1983 return(curr_offset - offset);
1985 /* [3] 10.5.2.11 Control Channel Description */
1987 static const value_string gsm_a_rr_mscr_vals[] = {
1988 { 0, "MSC is Release '98 or older"},
1989 { 1, "MSC is Release '99 onwards"},
1993 static const value_string gsm_a_rr_att_vals[] = {
1994 { 0, "MSs in the cell are not allowed to apply IMSI attach and detach procedure"},
1995 { 1, "MSs in the cell shall apply IMSI attach and detach procedure"},
1999 static const value_string gsm_a_rr_ccch_conf_vals[] = {
2000 { 0, "1 basic physical channel used for CCCH, not combined with SDCCHs"},
2001 { 1, "1 basic physical channel used for CCCH, combined with SDCCHs"},
2002 { 2, "2 basic physical channels used for CCCH, not combined with SDCCHs"},
2004 { 4, "3 basic physical channels used for CCCH, not combined with SDCCHs"},
2006 { 6, "4 basic physical channels used for CCCH, not combined with SDCCHs"},
2011 static const value_string gsm_a_rr_cbq3_vals[] = {
2012 { 0, "Iu mode not supported"},
2013 { 1, "Iu mode capable MSs barred"},
2014 { 2, "Iu mode supported, cell not barred"},
2015 { 3, "Iu mode supported, cell not barred"},
2020 de_rr_ctrl_ch_desc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2022 proto_tree *subtree;
2025 guint32 curr_offset;
2027 curr_offset = offset;
2029 item = proto_tree_add_text(tree, tvb, curr_offset, 3, "%s",
2030 gsm_rr_elem_strings[DE_RR_CTRL_CH_DESC].strptr);
2032 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CTRL_CH_DESC]);
2034 proto_tree_add_item(subtree, hf_gsm_a_rr_mscr, tvb, curr_offset, 1, FALSE);
2035 proto_tree_add_item(subtree, hf_gsm_a_rr_att, tvb, curr_offset, 1, FALSE);
2036 proto_tree_add_item(subtree, hf_gsm_a_rr_bs_ag_blks_res, tvb, curr_offset, 1, FALSE);
2037 proto_tree_add_item(subtree, hf_gsm_a_rr_ccch_conf, tvb, curr_offset, 1, FALSE);
2039 curr_offset = curr_offset + 1;
2040 oct = tvb_get_guint8(tvb, curr_offset);
2042 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_cbq3, tvb, (curr_offset<<3)+1, 2, FALSE);
2043 proto_tree_add_uint(subtree, hf_gsm_a_rr_bs_pa_mfrms, tvb, curr_offset, 1, (oct&0x07)+2);
2045 curr_offset = curr_offset + 1;
2047 proto_tree_add_item(subtree, hf_gsm_a_rr_t3212, tvb, curr_offset, 1, FALSE);
2049 curr_offset = curr_offset + 1;
2051 return(curr_offset - offset);
2054 /* [3] 10.5.2.11a DTM Information Details
2057 * [3] 10.5.2.11b Dynamic ARFCN Mapping
2059 static const value_string gsm_a_rr_gsm_band_vals[] = {
2081 de_rr_dyn_arfcn_map(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2083 guint32 curr_offset;
2088 curr_offset = offset;
2089 bit_offset = curr_offset << 3;
2091 proto_tree_add_bits_ret_val(tree, hf_gsm_a_rr_dyn_arfcn_length, tvb, bit_offset, 8, &length, FALSE);
2092 value = tvb_get_bits8(tvb,bit_offset,1);
2094 while (value && length)
2096 proto_tree_add_bits_item(tree, hf_gsm_a_rr_gsm_band, tvb, bit_offset, 4, FALSE);
2098 proto_tree_add_bits_item(tree, hf_gsm_a_rr_arfcn_first, tvb, bit_offset, 10, FALSE);
2100 proto_tree_add_bits_item(tree, hf_gsm_a_rr_band_offset, tvb, bit_offset, 10, FALSE);
2102 proto_tree_add_bits_item(tree, hf_gsm_a_rr_arfcn_range, tvb, bit_offset, 7, FALSE);
2104 value = tvb_get_bits8(tvb,bit_offset,1);
2109 curr_offset = curr_offset + len;
2111 return(curr_offset - offset);
2114 * [3] 10.5.2.12 Frequency Channel Sequence
2117 de_rr_freq_ch_seq(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2119 guint32 curr_offset;
2122 curr_offset = offset;
2124 proto_tree_add_item(tree, hf_gsm_a_rr_lowest_arfcn, tvb, curr_offset, 1, FALSE);
2126 bit_offset = curr_offset << 3;
2127 for (i=0; i<16; i++)
2129 proto_tree_add_bits_item(tree, hf_gsm_a_rr_inc_skip_arfcn, tvb, bit_offset, 4, FALSE);
2133 curr_offset = curr_offset + 8;
2135 return(curr_offset - offset);
2139 * [3] 10.5.2.13 Frequency List
2142 * [3] 10.5.2.13 Frequency List
2144 * Bit Bit Bit Bit Bit format notation
2146 * 0 0 X X X bit map 0
2147 * 1 0 0 X X 1024 range
2148 * 1 0 1 0 0 512 range
2149 * 1 0 1 0 1 256 range
2150 * 1 0 1 1 0 128 range
2151 * 1 0 1 1 1 variable bit map
2153 /* The mask 0xce (1100 1110) will produce the result 0110 0111*/
2154 static const value_string gsm_a_rr_freq_list_format_id_vals[] = {
2155 { 0x00, "bit map 0"},
2156 { 0x02, "bit map 0"},
2157 { 0x04, "bit map 0"},
2158 { 0x06, "bit map 0"},
2159 { 0x08, "bit map 0"},
2160 { 0x0a, "bit map 0"},
2161 { 0x0c, "bit map 0"},
2162 { 0x0e, "bit map 0"},
2163 { 0x40, "1024 range"},
2164 { 0x41, "1024 range"},
2165 { 0x42, "1024 range"},
2166 { 0x43, "1024 range"},
2167 { 0x44, "512 range"},
2168 { 0x45, "256 range"},
2169 { 0x46, "128 range"},
2170 { 0x47, "variable bit map"},
2174 de_rr_freq_list(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2176 return dissect_arfcn_list(tvb, tree, offset, len, add_string, string_len);
2179 * [3] 10.5.2.14 Frequency Short List
2181 *The Frequency Short List information element is a type 3 information element of 10 octet length.
2183 * This element is encoded exactly as the Frequency List information element,
2184 * except that it has a fixed length instead of a variable length and does
2185 * not contain a length indicator and that it shall not be encoded in bitmap 0 format.
2189 de_rr_freq_short_list(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2191 return dissect_arfcn_list(tvb, tree, offset, 9, add_string, string_len);
2195 * [3] 10.5.2.14a Frequency Short List 2
2197 * The Frequency Short List information element is a type 3 information element of 8 octet length.
2199 * This element is encoded exactly as the Frequency List information element,
2200 * except that it has a fixed length instead of a variable length and does
2201 * not contain a length indicator and that it shall not be encoded in bitmap 0 format.
2204 de_rr_freq_short_list2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2206 return dissect_arfcn_list(tvb, tree, offset, 8, add_string, string_len);
2209 * [3] 10.5.2.14b Group Channel Description
2213 * [3] 10.5.2.14c GPRS Resumption
2215 static const true_false_string gsm_a_rr_gprs_resumption_ack_value = {
2216 "Resumption of GPRS services successfully acknowledged",
2217 "Resumption of GPRS services not successfully acknowledged"
2221 de_rr_gprs_resumption(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2223 guint32 curr_offset;
2225 curr_offset = offset;
2227 proto_tree_add_item(tree, hf_gsm_a_rr_gprs_resumption_ack, tvb, curr_offset, 1, FALSE);
2230 return (curr_offset - offset);
2234 * [3] 10.5.2.14d GPRS broadcast information
2238 de_rr_rest_oct_gprs_cell_options(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
2240 proto_tree *subtree, *subtree2;
2241 proto_item *item, *item2;
2242 gint curr_bit_offset, curr_bit_offset_sav;
2245 curr_bit_offset = bit_offset;
2247 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS].strptr);
2248 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS]);
2249 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nmo, tvb, curr_bit_offset, 2, FALSE);
2250 curr_bit_offset += 2;
2251 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_t3168, tvb, curr_bit_offset, 3, FALSE);
2252 curr_bit_offset += 3;
2253 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_t3192, tvb, curr_bit_offset, 3, FALSE);
2254 curr_bit_offset += 3;
2255 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_drx_timer_max, tvb, curr_bit_offset, 3, FALSE);
2256 curr_bit_offset += 3;
2257 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_access_burst_type, tvb, curr_bit_offset, 1, FALSE);
2258 curr_bit_offset += 1;
2259 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_control_ack_type, tvb, curr_bit_offset, 1, FALSE);
2260 curr_bit_offset += 1;
2261 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bs_cv_max, tvb, curr_bit_offset, 4, FALSE);
2262 curr_bit_offset += 4;
2263 if (tvb_get_bits8(tvb,curr_bit_offset,1))
2265 curr_bit_offset += 1;
2266 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pan_dec, tvb, curr_bit_offset, 3, FALSE);
2267 curr_bit_offset += 3;
2268 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pan_inc, tvb, curr_bit_offset, 3, FALSE);
2269 curr_bit_offset += 3;
2270 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pan_max, tvb, curr_bit_offset, 3, FALSE);
2271 curr_bit_offset += 3;
2274 curr_bit_offset += 1;
2275 if (tvb_get_bits8(tvb,curr_bit_offset,1))
2276 { /* Optional extension information */
2277 curr_bit_offset += 1;
2278 curr_bit_offset_sav = curr_bit_offset;
2279 item2 = proto_tree_add_text(subtree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS_EXT_INFO].strptr);
2280 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_CELL_OPTIONS_EXT_INFO]);
2281 value = tvb_get_bits8(tvb,curr_bit_offset,6);
2282 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 1, "Extension Length: %d", value);
2283 curr_bit_offset += 6;
2285 proto_item_set_len(item2,((curr_bit_offset+value-curr_bit_offset_sav)>>3)+1);
2286 if (tvb_get_bits8(tvb,curr_bit_offset,1))
2288 curr_bit_offset += 1;
2289 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_egprs_packet_channel_request, tvb, curr_bit_offset, 1, FALSE);
2290 curr_bit_offset += 1;
2291 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_bep_period, tvb, curr_bit_offset, 4, FALSE);
2292 curr_bit_offset += 4;
2296 curr_bit_offset += 1;
2298 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_pfc_feature_mode, tvb, curr_bit_offset, 1, FALSE);
2299 curr_bit_offset += 1;
2300 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_dtm_support, tvb, curr_bit_offset, 1, FALSE);
2301 curr_bit_offset += 1;
2302 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_bss_paging_coordination, tvb, curr_bit_offset, 1, FALSE);
2303 curr_bit_offset += 1;
2306 { /* Rel 4 extension */
2307 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_ccn_active, tvb, curr_bit_offset, 1, FALSE);
2308 curr_bit_offset += 1;
2309 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nw_ext_utbf, tvb, curr_bit_offset, 1, FALSE);
2310 curr_bit_offset += 1;
2313 { /* Rel 6 extension */
2314 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_multiple_tbf_capability, tvb, curr_bit_offset, 1, FALSE);
2315 curr_bit_offset += 1;
2316 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_ext_utbf_no_data, tvb, curr_bit_offset, 1, FALSE);
2317 curr_bit_offset += 1;
2318 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_dtm_enhancements_capability, tvb, curr_bit_offset, 1, FALSE);
2319 curr_bit_offset += 1;
2321 if (tvb_get_bits8(tvb,curr_bit_offset,1))
2323 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_dedicated_mode_mbms_notification_support, tvb, bit_offset, 1, FALSE);
2325 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_mnci_support, tvb, bit_offset, 1, FALSE);
2333 { /* Rel 7 extension */
2334 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_reduced_latency_access, tvb, bit_offset, 1, FALSE);
2340 curr_bit_offset += value;
2343 curr_bit_offset += 1;
2344 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
2346 return (curr_bit_offset - bit_offset);
2350 de_rr_rest_oct_gprs_power_control_parameters(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
2352 proto_tree *subtree;
2354 gint curr_bit_offset;
2356 curr_bit_offset = bit_offset;
2358 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_POWER_CONTROL_PARAMS].strptr);
2359 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_POWER_CONTROL_PARAMS]);
2360 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_alpha, tvb, curr_bit_offset, 4, FALSE);
2361 curr_bit_offset += 4;
2362 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_t_avg_w, tvb, curr_bit_offset, 5, FALSE);
2363 curr_bit_offset += 5;
2364 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_t_avg_t, tvb, curr_bit_offset, 5, FALSE);
2365 curr_bit_offset += 5;
2366 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_pc_meas_chan, tvb, curr_bit_offset, 1, FALSE);
2367 curr_bit_offset += 1;
2368 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_n_avg_i, tvb, curr_bit_offset, 4, FALSE);
2369 curr_bit_offset += 4;
2370 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
2372 return (curr_bit_offset - bit_offset);
2376 de_rr_gprs_broadcast_info(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len , gchar *add_string _U_, int string_len _U_)
2378 guint32 curr_offset;
2381 curr_offset = offset;
2382 bit_offset = curr_offset << 3;
2384 bit_offset += de_rr_rest_oct_gprs_cell_options(tvb, tree, bit_offset);
2385 bit_offset += de_rr_rest_oct_gprs_power_control_parameters(tvb, tree, bit_offset);
2388 return (curr_offset - offset);
2392 * [3] 10.5.2.15 Handover Reference
2395 de_rr_ho_ref(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2397 proto_tree *subtree;
2399 guint32 curr_offset;
2401 curr_offset = offset;
2404 proto_tree_add_text(tree,
2405 tvb, curr_offset, 1, "%s",
2406 gsm_rr_elem_strings[DE_RR_HO_REF].strptr);
2408 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_HO_REF]);
2410 /* Handover reference value */
2411 proto_tree_add_item(subtree, hf_gsm_a_rr_ho_ref_val, tvb, curr_offset, 1, FALSE);
2413 curr_offset = curr_offset + 1;
2415 return(curr_offset - offset);
2418 * [3] 10.5.2.16 IA Rest Octets
2422 de_rr_ia_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2424 proto_tree *subtree;
2426 guint32 curr_offset;
2428 len = tvb_length_remaining(tvb,offset);
2432 curr_offset = offset;
2435 proto_tree_add_text(tree,
2436 tvb, curr_offset, len, "%s",
2437 gsm_rr_elem_strings[DE_RR_IA_REST_OCT].strptr);
2439 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_IA_REST_OCT]);
2441 proto_tree_add_text(subtree,tvb, curr_offset, len ,"Data(Not decoded)");
2443 curr_offset = curr_offset + len;
2445 return curr_offset-offset;
2449 * [3] 10.5.2.17 IAR Rest Octets
2453 de_rr_iar_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2455 proto_tree *subtree;
2457 guint32 curr_offset;
2460 curr_offset = offset;
2463 proto_tree_add_text(tree,
2464 tvb, curr_offset, 3, "%s",
2465 gsm_rr_elem_strings[DE_RR_IAR_REST_OCT].strptr);
2467 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_IAR_REST_OCT]);
2469 proto_tree_add_text(subtree,tvb, curr_offset, len ,"Data(Not decoded)");
2471 curr_offset = curr_offset + len;
2473 return curr_offset-offset;
2477 * [3] 10.5.2.18 IAX Rest Octets
2480 de_rr_iax_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2482 proto_tree *subtree;
2484 guint32 curr_offset;
2486 len = tvb_length_remaining(tvb,offset);
2490 curr_offset = offset;
2493 proto_tree_add_text(tree,
2494 tvb, curr_offset, len, "%s",
2495 gsm_rr_elem_strings[DE_RR_IAX_REST_OCT].strptr);
2497 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_IAX_REST_OCT]);
2499 proto_tree_add_text(subtree,tvb, curr_offset, len ,"Data(Not decoded)");
2501 curr_offset = curr_offset + len;
2503 return curr_offset-offset;
2507 * [3] 10.5.2.19 L2 Pseudo Length
2510 de_rr_l2_pseudo_len(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2512 proto_tree *subtree;
2514 guint32 curr_offset;
2516 curr_offset = offset;
2518 item = proto_tree_add_text(tree,tvb, curr_offset, 1, "%s", gsm_rr_elem_strings[DE_RR_L2_PSEUDO_LEN].strptr);
2520 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_L2_PSEUDO_LEN]);
2522 /* L2 Pseudo Length value */
2523 proto_tree_add_item(subtree, hf_gsm_a_rr_L2_pseudo_len, tvb, curr_offset, 1, FALSE);
2525 curr_offset = curr_offset + 1;
2527 return(curr_offset - offset);
2531 * [3] 10.5.2.20 Measurement Results
2533 static const true_false_string gsm_a_rr_dtx_vals = {
2538 static const value_string gsm_a_rr_rxlev_vals [] = {
2540 {1, "-110 <= x < -109 dBm"},
2541 {2, "-109 <= x < -108 dBm"},
2542 {3, "-108 <= x < -107 dBm"},
2543 {4, "-107 <= x < -106 dBm"},
2544 {5, "-106 <= x < -105 dBm"},
2545 {6, "-105 <= x < -104 dBm"},
2546 {7, "-104 <= x < -103 dBm"},
2547 {8, "-103 <= x < -102 dBm"},
2548 {9, "-102 <= x < -101 dBm"},
2549 {10, "-101 <= x < -100 dBm"},
2550 {11, "-100 <= x < -99 dBm"},
2551 {12, "-99 <= x < -98 dBm"},
2552 {13, "-98 <= x < -97 dBm"},
2553 {14, "-97 <= x < -96 dBm"},
2554 {15, "-96 <= x < -95 dBm"},
2555 {16, "-95 <= x < -94 dBm"},
2556 {17, "-94 <= x < -93 dBm"},
2557 {18, "-93 <= x < -92 dBm"},
2558 {19, "-92 <= x < -91 dBm"},
2559 {20, "-91 <= x < -90 dBm"},
2560 {21, "-90 <= x < -89 dBm"},
2561 {22, "-89 <= x < -88 dBm"},
2562 {23, "-88 <= x < -87 dBm"},
2563 {24, "-87 <= x < -86 dBm"},
2564 {25, "-86 <= x < -85 dBm"},
2565 {26, "-85 <= x < -84 dBm"},
2566 {27, "-84 <= x < -83 dBm"},
2567 {28, "-83 <= x < -82 dBm"},
2568 {29, "-82 <= x < -81 dBm"},
2569 {30, "-81 <= x < -80 dBm"},
2570 {31, "-80 <= x < -79 dBm"},
2571 {32, "-79 <= x < -78 dBm"},
2572 {33, "-78 <= x < -77 dBm"},
2573 {34, "-77 <= x < -76 dBm"},
2574 {35, "-76 <= x < -75 dBm"},
2575 {36, "-75 <= x < -74 dBm"},
2576 {37, "-74 <= x < -73 dBm"},
2577 {38, "-73 <= x < -72 dBm"},
2578 {39, "-72 <= x < -71 dBm"},
2579 {40, "-71 <= x < -70 dBm"},
2580 {41, "-70 <= x < -69 dBm"},
2581 {42, "-69 <= x < -68 dBm"},
2582 {43, "-68 <= x < -67 dBm"},
2583 {44, "-67 <= x < -66 dBm"},
2584 {45, "-66 <= x < -65 dBm"},
2585 {46, "-65 <= x < -64 dBm"},
2586 {47, "-64 <= x < -63 dBm"},
2587 {48, "-63 <= x < -62 dBm"},
2588 {49, "-62 <= x < -61 dBm"},
2589 {50, "-61 <= x < -60 dBm"},
2590 {51, "-60 <= x < -59 dBm"},
2591 {52, "-59 <= x < -58 dBm"},
2592 {53, "-58 <= x < -57 dBm"},
2593 {54, "-57 <= x < -56 dBm"},
2594 {55, "-56 <= x < -55 dBm"},
2595 {56, "-55 <= x < -54 dBm"},
2596 {57, "-54 <= x < -53 dBm"},
2597 {58, "-53 <= x < -52 dBm"},
2598 {59, "-52 <= x < -51 dBm"},
2599 {60, "-51 <= x < -50 dBm"},
2600 {61, "-50 <= x < -49 dBm"},
2601 {62, "-49 <= x < -48 dBm"},
2606 static const true_false_string gsm_a_rr_mv_vals = {
2607 "The measurement results are valid",
2608 "The measurement results are not valid"
2611 static const value_string gsm_a_rr_rxqual_vals [] = {
2612 {0, "BER < 0.2%, Mean value 0.14%"},
2613 {1, "0.2% <= BER < 0.4%, Mean value 0.28%"},
2614 {2, "0.4% <= BER < 0.8%, Mean value 0.57%"},
2615 {3, "0.8% <= BER < 1.6%, Mean value 1.13%"},
2616 {4, "1.6% <= BER < 3.2%, Mean value 2.26%"},
2617 {5, "3.2% <= BER < 6.4%, Mean value 4.53%"},
2618 {6, "6.4% <= BER < 12.8%, Mean value 9.05%"},
2619 {7, "BER > 12.8%, Mean value 18.10%"},
2622 static const value_string gsm_a_rr_ncell_vals [] = {
2623 {0, "No neighbour cell measurement result"},
2624 {1, "1 neighbour cell measurement result"},
2625 {2, "2 neighbour cell measurement result"},
2626 {3, "3 neighbour cell measurement result"},
2627 {4, "4 neighbour cell measurement result"},
2628 {5, "5 neighbour cell measurement result"},
2629 {6, "6 neighbour cell measurement result"},
2630 {7, "Neighbour cell information not available for serving cell"},
2634 de_rr_meas_res(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2636 proto_tree *subtree;
2638 guint32 curr_offset;
2642 curr_offset = offset;
2645 proto_tree_add_text(tree,
2646 tvb, curr_offset, 16, "%s",
2647 gsm_rr_elem_strings[DE_RR_MEAS_RES].strptr);
2648 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_MEAS_RES]);
2652 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_ba_used, tvb, curr_offset<<3, 1, FALSE);
2654 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_dtx_used, tvb, (curr_offset<<3)+1, 1, FALSE);
2655 /* RXLEV-FULL-SERVING-CELL */
2656 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxlev_full_serv_cell, tvb, (curr_offset<<3)+2, 6, FALSE);
2661 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_3g_ba_used, tvb, curr_offset<<3, 1, FALSE);
2663 proto_tree_add_item(subtree, hf_gsm_a_rr_meas_valid, tvb, curr_offset, 1, FALSE);
2664 /* RXLEV-SUB-SERVING-CELL */
2665 proto_tree_add_item(subtree, hf_gsm_a_rr_rxlev_sub_serv_cell, tvb, curr_offset, 1, FALSE);
2670 /* RXQUAL-FULL-SERVING-CELL */
2671 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxqual_full_serv_cell, tvb, (curr_offset<<3)+1, 3, FALSE);
2673 /* RXQUAL-SUB-SERVING-CELL */
2674 proto_tree_add_item(subtree, hf_gsm_a_rr_rxqual_sub_serv_cell, tvb, curr_offset, 1, FALSE);
2676 bit_offset = (curr_offset << 3) + 7;
2677 proto_tree_add_bits_ret_val(subtree, hf_gsm_a_rr_no_ncell_m, tvb, bit_offset, 3, &no_ncell_m, FALSE);
2679 if (no_ncell_m == 7) /* No neighbour cell information available) */
2683 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxlev_ncell, tvb, bit_offset, 6, FALSE);
2685 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bcch_freq_ncell, tvb, bit_offset, 5, FALSE);
2687 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bsic_ncell, tvb, bit_offset, 6, FALSE);
2696 * [3] 10.5.2.20a GPRS Measurement Results
2699 * [3] 10.5.2.21 Mobile Allocation
2702 de_rr_mob_all(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2704 guint32 curr_offset;
2709 curr_offset = offset;
2711 item = proto_tree_add_text(tree, tvb, curr_offset, len, "Bitmap of increasing ARFCNs included in the Mobile Allocation: ");
2712 for(i=len; i>0; i--)
2714 value = tvb_get_guint8(tvb,curr_offset+i-1);
2717 proto_item_append_text(item,"%d",(value>>j)&0x01);
2721 curr_offset = curr_offset + len;
2722 return(curr_offset - offset);
2726 * [3] 10.5.2.21a Mobile Time Difference
2729 de_rr_mob_time_diff(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2731 guint32 curr_offset;
2733 curr_offset = offset;
2735 proto_tree_add_item(tree, hf_gsm_a_rr_mobile_time_difference, tvb, curr_offset, len, FALSE);
2737 curr_offset = curr_offset + len;
2738 return(curr_offset - offset);
2742 * [3] 10.5.2.21aa MultiRate configuration
2744 /* Multirate speech version Octet 3 Bits 8 7 6 */
2745 static const value_string multirate_speech_ver_vals[] = {
2746 { 1, "Adaptive Multirate speech version 1"},
2747 { 2, "Adaptive Multirate speech version 2"},
2750 /* Bit 5 NSCB: Noise Suppression Control Bit */
2751 static const value_string NSCB_vals[] = {
2752 { 0, "Noise Suppression can be used (default)"},
2753 { 1, "Noise Suppression shall be turned off"},
2756 /* Bit 4 ICMI: Initial Codec Mode Indicator */
2757 static const value_string ICMI_vals[] = {
2758 { 0, "The initial codec mode is defined by the implicit rule provided in 3GPP TS 05.09"},
2759 { 1, "The initial codec mode is defined by the Start Mode field"},
2763 Table 10.5.2.21aa.2: Set of adaptive multirate codec modes field (octet 4)
2764 for the Multirate speech version 1
2766 static const true_false_string gsm_a_rr_set_of_amr_codec_modes = {
2767 "is part of the subset",
2768 "is not part of the subset"
2771 static const value_string gsm_a_rr_amr_threshold_vals[] = {
2839 static const value_string gsm_a_rr_amr_hysteresis_vals[] = {
2860 de_rr_multirate_conf(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2862 guint32 curr_offset;
2864 gint bit_offset, remaining_length, nb_of_params;
2866 curr_offset = offset;
2868 proto_tree_add_item(tree, hf_gsm_a_rr_multirate_speech_ver, tvb, curr_offset, 1, FALSE);
2869 proto_tree_add_item(tree, hf_gsm_a_rr_NCSB, tvb, curr_offset, 1, FALSE);
2870 proto_tree_add_item(tree, hf_gsm_a_rr_ICMI, tvb, curr_offset, 1, FALSE);
2871 /* The initial codec mode is coded as in 3GPP TS 45.009 */
2872 proto_tree_add_item(tree, hf_gsm_a_rr_start_mode, tvb, curr_offset, 1, FALSE);
2873 oct = ( tvb_get_guint8(tvb,curr_offset) &0xe0 ) >> 5;
2877 /* Adaptive Multirate speech version 1 */
2878 /* Set of AMR codec modes */
2879 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b8, tvb, curr_offset, 1, FALSE);
2880 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b7, tvb, curr_offset, 1, FALSE);
2881 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b6, tvb, curr_offset, 1, FALSE);
2882 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b5, tvb, curr_offset, 1, FALSE);
2883 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b4, tvb, curr_offset, 1, FALSE);
2884 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b3, tvb, curr_offset, 1, FALSE);
2885 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b2, tvb, curr_offset, 1, FALSE);
2886 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v1_b1, tvb, curr_offset, 1, FALSE);
2889 remaining_length = len-2;
2892 /* Adaptive Multirate speech version 2 */
2893 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v2_b5, tvb, curr_offset, 1, FALSE);
2894 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v2_b4, tvb, curr_offset, 1, FALSE);
2895 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v2_b3, tvb, curr_offset, 1, FALSE);
2896 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v2_b2, tvb, curr_offset, 1, FALSE);
2897 proto_tree_add_item(tree, hf_gsm_a_rr_set_of_amr_codec_modes_v2_b1, tvb, curr_offset, 1, FALSE);
2900 remaining_length = len-2;
2903 proto_tree_add_text(tree,tvb,offset,1,"Unknown version");
2904 proto_tree_add_text(tree,tvb, curr_offset, len-1 ,"Data(Not decoded)");
2905 remaining_length = 0;
2909 if (remaining_length)
2911 bit_offset = (curr_offset<<3) + 2;
2912 nb_of_params = remaining_length - 1;
2913 while (nb_of_params)
2915 proto_tree_add_bits_item(tree, hf_gsm_a_rr_amr_threshold, tvb, bit_offset, 6, FALSE);
2917 proto_tree_add_bits_item(tree, hf_gsm_a_rr_amr_hysteresis, tvb, bit_offset, 4, FALSE);
2923 curr_offset = offset + len;
2924 return(curr_offset - offset);
2928 * [3] 10.5.2.21b Multislot Allocation
2931 de_rr_mult_all(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2933 guint32 curr_offset;
2935 curr_offset = offset;
2937 proto_tree_add_text(tree,tvb, curr_offset, len ,"Data(Not decoded)");
2939 curr_offset = curr_offset + len;
2940 return(curr_offset - offset);
2944 * [3] 10.5.2.21c NC mode
2948 * [3] 10.5.2.22 Neighbour Cell Description
2950 static const value_string gsm_a_rr_ext_ind_vals[] = {
2951 { 0, "The information element carries the complete BA"},
2952 { 1, "The information element carries only a part of the BA"},
2956 de_rr_neigh_cell_desc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2958 guint32 curr_offset;
2960 curr_offset = offset;
2962 proto_tree_add_item(tree, hf_gsm_a_rr_ext_ind, tvb, curr_offset, 1, FALSE);
2963 proto_tree_add_bits_item(tree, hf_gsm_a_rr_ba_ind, tvb, (curr_offset<<3)+3, 1, FALSE);
2965 return dissect_arfcn_list(tvb, tree, offset, 16, add_string, string_len);
2969 * [3] 10.5.2.22a Neighbour Cell Description 2
2972 de_rr_neigh_cell_desc2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2974 guint32 curr_offset;
2976 curr_offset = offset;
2978 proto_tree_add_bits_item(tree, hf_gsm_a_rr_multiband_reporting, tvb, (curr_offset<<3)+1, 2, FALSE);
2979 proto_tree_add_bits_item(tree, hf_gsm_a_rr_ba_ind, tvb, (curr_offset<<3)+3, 1, FALSE);
2981 return dissect_arfcn_list(tvb, tree, offset, 16, add_string, string_len);
2985 * [3] 10.5.2.22b (void)
2986 * [3] 10.5.2.22c NT/N Rest Octets
2990 * [3] 10.5.2.23 P1 Rest Octets
2993 de_rr_p1_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2995 proto_tree *subtree;
2996 proto_item *item, *item2;
2997 guint32 curr_offset, value;
2998 gint bit_offset, bit_offset_sav, i;
3000 curr_offset = offset;
3001 bit_offset = curr_offset << 3;
3002 len = tvb_length_remaining(tvb,offset);
3004 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
3005 gsm_rr_elem_strings[DE_RR_P1_REST_OCT].strptr);
3007 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_P1_REST_OCT]);
3009 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3012 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_pch, tvb, bit_offset, 2, FALSE);
3014 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_status_pch, tvb, bit_offset, 1, FALSE);
3019 for (i=1; i<=2; i++)
3021 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3024 item2 = proto_tree_add_bits_item(subtree, hf_gsm_a_call_prio, tvb, bit_offset, 3, FALSE);
3026 proto_item_append_text(item2, " for Mobile Identity %d", i);
3031 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3032 { /* Group Call Information */
3034 bit_offset_sav = bit_offset;
3036 if (tvb_get_bits8(tvb,bit_offset,1))
3037 { /* Group Channel Description */
3039 if (tvb_get_bits8(tvb,bit_offset,1))
3040 { /* Hopping case */
3042 if (tvb_get_bits8(tvb,bit_offset,1))
3049 value = tvb_get_bits8(tvb,bit_offset,8);
3050 bit_offset += 8 + (value<<3);
3058 proto_tree_add_text(subtree,tvb, bit_offset_sav>>3, (bit_offset-bit_offset_sav)>>3,"Group Call Information: Data(Not decoded)");
3062 for (i=1; i<=2; i++)
3064 item2 = proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Packet Page Indication %d: ", i);
3065 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3066 proto_item_append_text(item2, "Packet paging procedure");
3068 proto_item_append_text(item2, "Paging procedure for RR connection establishment");
3071 if (((curr_offset + len)<<3) - bit_offset > 0)
3073 /* There is still room left in the Rest Octets IE */
3074 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3075 { /* Additions in release 6 */
3077 proto_tree_add_text(subtree, tvb, bit_offset>>3, -1,"Additions in Release 6: Data(Not decoded)");
3083 curr_offset = curr_offset + len;
3085 return (curr_offset - offset);
3089 * [3] 10.5.2.24 P2 Rest Octets
3092 de_rr_p2_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3095 proto_tree *subtree;
3096 proto_item *item, *item2;
3097 guint32 curr_offset;
3100 curr_offset = offset;
3101 bit_offset = curr_offset << 3;
3102 len = tvb_length_remaining(tvb,offset);
3104 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
3105 gsm_rr_elem_strings[DE_RR_P2_REST_OCT].strptr);
3107 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_P2_REST_OCT]);
3109 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3112 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_chnl_needed_ch3, tvb, bit_offset, 2, FALSE);
3117 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3120 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_pch, tvb, bit_offset, 2, FALSE);
3122 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_status_pch, tvb, bit_offset, 1, FALSE);
3127 for (i=1; i<=3; i++)
3129 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3132 item2 = proto_tree_add_bits_item(subtree, hf_gsm_a_call_prio, tvb, bit_offset, 3, FALSE);
3134 proto_item_append_text(item2, " for Mobile Identity %d", i);
3139 item2 = proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Packet Page Indication 3: ");
3140 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3141 proto_item_append_text(item2, "Packet paging procedure");
3143 proto_item_append_text(item2, "Paging procedure for RR connection establishment");
3145 if (((curr_offset + len)<<3) - bit_offset > 0)
3147 /* There is still room left in the Rest Octets IE */
3148 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3149 { /* Additions in release 6 */
3151 proto_tree_add_text(subtree, tvb, bit_offset>>3, -1,"Additions in Release 6: Data(Not decoded)");
3157 curr_offset = curr_offset + len;
3159 return (curr_offset - offset);
3163 * [3] 10.5.2.25 P3 Rest Octets
3166 de_rr_p3_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3168 proto_tree *subtree;
3169 proto_item *item, *item2;
3170 guint32 curr_offset;
3173 curr_offset = offset;
3174 bit_offset = curr_offset << 3;
3177 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
3178 gsm_rr_elem_strings[DE_RR_P3_REST_OCT].strptr);
3180 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_P3_REST_OCT]);
3182 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3185 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_chnl_needed_ch3, tvb, bit_offset, 2, FALSE);
3187 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_chnl_needed_ch4, tvb, bit_offset, 2, FALSE);
3192 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3195 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_pch, tvb, bit_offset, 2, FALSE);
3197 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nln_status_pch, tvb, bit_offset, 1, FALSE);
3202 for (i=1; i<=4; i++)
3204 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3207 item2 = proto_tree_add_bits_item(subtree, hf_gsm_a_call_prio, tvb, bit_offset, 3, FALSE);
3209 proto_item_append_text(item2, " for Mobile Identity %d", i);
3215 curr_offset = curr_offset + len;
3217 return (curr_offset - offset);
3221 * [3] 10.5.2.25a Packet Channel Description C V 3
3224 de_rr_packet_ch_desc(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3226 guint32 curr_offset;
3228 guint16 arfcn, hsn, maio;
3229 proto_tree *subtree;
3233 curr_offset = offset;
3235 item = proto_tree_add_text(tree,tvb,curr_offset,3, "%s", gsm_rr_elem_strings[DE_RR_PACKET_CH_DESC].strptr);
3236 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_PACKET_CH_DESC]);
3239 oct8 = tvb_get_guint8(tvb, curr_offset);
3241 str = "Spare bits (ignored by receiver)";
3242 other_decode_bitfield_value(a_bigbuf, oct8, 0xf8, 8);
3243 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = %s",a_bigbuf,str);
3245 other_decode_bitfield_value(a_bigbuf, oct8, 0x07, 8);
3246 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Timeslot: %d",a_bigbuf,(oct8 & 0x07));
3251 oct8 = tvb_get_guint8(tvb, curr_offset);
3252 other_decode_bitfield_value(a_bigbuf, oct8, 0xe0, 8);
3253 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Training Sequence: %d",a_bigbuf,((oct8 & 0xe0)>>5));
3255 if ((oct8 & 0x10) == 0x10)
3257 /* Hopping sequence */
3258 maio = ((oct8 & 0x0f)<<2) | ((tvb_get_guint8(tvb,curr_offset+1) & 0xc0) >> 6);
3259 hsn = (tvb_get_guint8(tvb,curr_offset+1) & 0x3f);
3262 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
3263 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
3264 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: MAIO %d",maio);
3265 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Hopping channel: HSN %d",hsn);
3270 arfcn = ((oct8 & 0x03) << 8) | tvb_get_guint8(tvb,curr_offset+1);
3272 other_decode_bitfield_value(a_bigbuf, oct8, 0x10, 8);
3273 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Hopping channel: %s",a_bigbuf,str);
3274 other_decode_bitfield_value(a_bigbuf, oct8, 0x0c, 8);
3275 proto_tree_add_text(subtree,tvb, curr_offset, 1,"%s = Spare",a_bigbuf);
3276 proto_tree_add_text(subtree,tvb, curr_offset, 2,"Single channel : ARFCN %d",arfcn);
3279 curr_offset = curr_offset + 2;
3280 return(curr_offset - offset);
3284 * [3] 10.5.2.25b Dedicated mode or TBF
3287 static const value_string gsm_a_rr_dedicated_mode_or_tbf_vals[] = {
3288 { 0, "This message assigns a dedicated mode resource"},
3289 { 1, "This message assigns an uplink TBF or is the second message of two in a two-message assignment of an uplink or downlink TBF"},
3291 { 3, "This message assigns a downlink TBF to the mobile station identified in the IA Rest Octets IE"},
3293 { 5, "This message is the first message of two in a two-message assignment of an uplink TBF"},
3295 { 7, "This message is the first message of two in a two-message assignment of a downlink TBF to the mobile station identified in the IA Rest Octets IE"},
3299 de_rr_ded_mod_or_tbf(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3301 proto_tree *subtree;
3303 guint32 curr_offset;
3305 curr_offset = offset;
3308 proto_tree_add_text(tree,
3309 tvb, curr_offset, 1, "%s",
3310 gsm_rr_elem_strings[DE_RR_DED_MOD_OR_TBF].strptr);
3312 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_DED_MOD_OR_TBF]);
3314 proto_tree_add_item(subtree, hf_gsm_a_rr_dedicated_mode_or_tbf, tvb, curr_offset, 1, FALSE);
3318 return(curr_offset - offset);
3321 * [3] 10.5.2.25c RR Packet Uplink Assignment
3322 * [3] 10.5.2.25d RR Packet Downlink Assignment
3325 * [3] 10.5.2.26 Page Mode
3328 static const value_string gsm_a_rr_page_mode_vals[] = {
3329 { 0, "Normal paging"},
3330 { 1, "Extended paging"},
3331 { 2, "Paging reorganization"},
3332 { 3, "Same as before"},
3336 de_rr_page_mode(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3338 proto_tree *subtree;
3340 guint32 curr_offset;
3342 curr_offset = offset;
3345 proto_tree_add_text(tree,
3346 tvb, curr_offset, 1, "%s",
3347 gsm_rr_elem_strings[DE_RR_PAGE_MODE].strptr);
3349 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_PAGE_MODE]);
3351 proto_tree_add_item(subtree, hf_gsm_a_rr_page_mode, tvb, curr_offset, 1, FALSE);
3355 return(curr_offset - offset);
3358 * [3] 10.5.2.26a (void)
3359 * [3] 10.5.2.26b (void)
3360 * [3] 10.5.2.26c (void)
3361 * [3] 10.5.2.26d (void)
3364 * [3] 10.5.2.27 NCC Permitted
3367 de_rr_ncc_perm(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3369 proto_tree *subtree;
3371 guint32 curr_offset;
3373 curr_offset = offset;
3375 item = proto_tree_add_text(tree, tvb, curr_offset, 1, "%s",
3376 gsm_rr_elem_strings[DE_RR_NCC_PERM].strptr);
3378 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_NCC_PERM]);
3380 proto_tree_add_item(subtree, hf_gsm_a_rr_ncc_permitted, tvb, curr_offset, 1, FALSE);
3382 curr_offset = curr_offset + 1;
3384 return(curr_offset - offset);
3387 * [3] 10.5.2.28 Power Command
3390 * ATC (Access Type Control) (octet 2)Bit 8
3391 * 0 Sending of Handover access is mandatory
3392 * 1 Sending of Handover access is optional
3394 static const true_false_string gsm_a_rr_pow_cmd_atc_value = {
3395 "Sending of Handover access is optional",
3396 "Sending of Handover access is mandatory"
3399 * The EPC mode field (octet 2) indicates whether the assigned channel(s)
3400 * shall be in enhanced power control (EPC) mode. It is only valid for channels
3401 * on which EPC may be used. It is coded as follows:
3403 static const true_false_string gsm_a_rr_pow_cmd_epc_value = {
3404 "Channel(s) in EPC mode",
3405 "Channel(s) not in EPC mode"
3409 * The FPC_EPC field (octet 2) has different interpretation depending
3410 * on the channel mode of the assigned channel (s) and the value
3411 * of the EPC mode field.
3412 * If the channel mode is such that fast power control (FPC) may be
3413 * used, the FPC_EPC field indicates whether Fast Measurement
3414 * Reporting and Power Control mechanism is used.
3415 * It is coded as follows:
3416 * Value 0 FPC not in use
3418 * If the channel mode is such that EPC may be used and the EPC mode
3419 * field indicates that the channel is in EPC mode, the FPC_EPC
3420 * field indicates whether EPC shall be used for uplink power control.
3421 * It is coded as follows:
3422 * Value 0 EPC not in use for uplink power control
3423 * 1 EPC in use for uplink power control
3426 static const true_false_string gsm_a_rr_pow_cmd_fpcepc_value = {
3427 "FPC in use/EPC in use for uplink power control",
3428 "FPC not in use/C not in use for uplink power control"
3432 * Power level (octet 2)The power level field is coded as the binaryRepresentation
3433 * of the "power control level", see 3GPP TS 3GPP TS 45.005. This value shall be used
3434 * by the mobile station According to 3GPP TS 45.008.Range: 0 to 31.
3438 de_rr_pow_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3440 proto_tree *subtree;
3442 guint32 curr_offset;
3444 curr_offset = offset;
3447 proto_tree_add_text(tree,
3448 tvb, curr_offset, 1, "%s",
3449 gsm_rr_elem_strings[DE_RR_POW_CMD].strptr);
3451 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_POW_CMD]);
3453 proto_tree_add_item(subtree, hf_gsm_a_b8spare, tvb, curr_offset, 1, FALSE);
3455 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_epc, tvb, curr_offset, 1, FALSE);
3457 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_fpcepc, tvb, curr_offset, 1, FALSE);
3459 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_powlev, tvb, curr_offset, 1, FALSE);
3461 curr_offset = curr_offset + 1;
3463 return(curr_offset - offset);
3467 * [3] 10.5.2.28a Power Command and access type
3470 de_rr_pow_cmd_and_acc_type(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3472 proto_tree *subtree;
3474 guint32 curr_offset;
3476 curr_offset = offset;
3479 proto_tree_add_text(tree,
3480 tvb, curr_offset, 1, "%s",
3481 gsm_rr_elem_strings[DE_RR_POW_CMD_AND_ACC_TYPE].strptr);
3483 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_POW_CMD_AND_ACC_TYPE]);
3486 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_atc, tvb, curr_offset, 1, FALSE);
3488 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_epc, tvb, curr_offset, 1, FALSE);
3490 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_fpcepc, tvb, curr_offset, 1, FALSE);
3492 proto_tree_add_item(subtree, hf_gsm_a_rr_pow_cmd_powlev, tvb, curr_offset, 1, FALSE);
3494 curr_offset = curr_offset + 1;
3496 return(curr_offset - offset);
3499 * [3] 10.5.2.29 RACH Control Parameters
3502 static const value_string gsm_a_rr_max_retrans_vals[] = {
3503 { 0, "Maximum 1 retransmission"},
3504 { 1, "Maximum 2 retransmissions"},
3505 { 2, "Maximum 4 retransmissions"},
3506 { 3, "Maximum 7 retransmissions"},
3510 static const value_string gsm_a_rr_tx_integer_vals[] = {
3511 { 0, "3 slots used to spread transmission"},
3512 { 1, "4 slots used to spread transmission"},
3513 { 2, "5 slots used to spread transmission"},
3514 { 3, "6 slots used to spread transmission"},
3515 { 4, "7 slots used to spread transmission"},
3516 { 5, "8 slots used to spread transmission"},
3517 { 6, "9 slots used to spread transmission"},
3518 { 7, "10 slots used to spread transmission"},
3519 { 8, "11 slots used to spread transmission"},
3520 { 9, "12 slots used to spread transmission"},
3521 { 10, "14 slots used to spread transmission"},
3522 { 11, "16 slots used to spread transmission"},
3523 { 12, "20 slots used to spread transmission"},
3524 { 13, "25 slots used to spread transmission"},
3525 { 14, "32 slots used to spread transmission"},
3526 { 15, "50 slots used to spread transmission"},
3529 static const value_string gsm_a_rr_cell_barr_access_vals[] = {
3530 { 0, "The cell is not barred"},
3531 { 1, "The cell is barred"},
3534 static const value_string gsm_a_rr_re_vals[] = {
3535 { 0, "Call Reestablishment allowed in the cell"},
3536 { 1, "Call Reestablishment not allowed in the cell"},
3541 de_rr_rach_ctrl_param(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3543 proto_tree *subtree;
3545 guint32 curr_offset;
3547 curr_offset = offset;
3549 item = proto_tree_add_text(tree, tvb, curr_offset, 3, "%s",
3550 gsm_rr_elem_strings[DE_RR_RACH_CTRL_PARAM].strptr);
3552 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_RACH_CTRL_PARAM]);
3554 proto_tree_add_item(subtree, hf_gsm_a_rr_max_retrans, tvb, curr_offset, 1, FALSE);
3555 proto_tree_add_item(subtree, hf_gsm_a_rr_tx_integer, tvb, curr_offset, 1, FALSE);
3556 proto_tree_add_item(subtree, hf_gsm_a_rr_cell_barr_access, tvb, curr_offset, 1, FALSE);
3557 proto_tree_add_item(subtree, hf_gsm_a_rr_re, tvb, curr_offset, 1, FALSE);
3558 curr_offset = curr_offset + 1;
3560 proto_tree_add_item(subtree, hf_gsm_a_rr_acc, tvb, curr_offset, 2, FALSE);
3562 curr_offset = curr_offset + 2;
3564 return(curr_offset - offset);
3567 * [3] 10.5.2.30 Request Reference M V 3
3569 static guint16 reduced_frame_number(guint16 fn)
3571 /* great care needed with signed/unsigned - -1 in unsigned is 0xffff, which mod(26) is not what you think !!! */
3575 t1 = (fn >> 11) & 0x1f;
3576 t2 = (fn >> 0) & 0x1f;
3577 t3 = (fn >> 5) & 0x3f;
3583 frame = 51*(unsigned)t+(unsigned)t3+51*26*t1;
3589 de_rr_req_ref(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3591 proto_tree *subtree;
3593 guint32 curr_offset;
3597 curr_offset = offset;
3600 proto_tree_add_text(tree,
3601 tvb, curr_offset, 3, "%s",
3602 gsm_rr_elem_strings[DE_RR_REQ_REF].strptr);
3604 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_REQ_REF]);
3606 proto_tree_add_item(subtree, hf_gsm_a_rr_ra, tvb, curr_offset, 1, FALSE);
3608 fn = tvb_get_ntohs(tvb,curr_offset);
3609 rfn = reduced_frame_number(fn);
3610 proto_tree_add_item(subtree, hf_gsm_a_rr_T1prim, tvb, curr_offset, 1, FALSE);
3611 proto_tree_add_item(subtree, hf_gsm_a_rr_T3, tvb, curr_offset, 2, FALSE);
3613 proto_tree_add_item(subtree, hf_gsm_a_rr_T2, tvb, curr_offset, 1, FALSE);
3615 item = proto_tree_add_uint(subtree, hf_gsm_a_rr_rfn, tvb, curr_offset-2, 2, rfn);
3616 PROTO_ITEM_SET_GENERATED(item);
3618 return(curr_offset - offset);
3624 de_rr_cause(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3626 guint32 curr_offset;
3628 curr_offset = offset;
3630 proto_tree_add_item(tree, hf_gsm_a_rr_RR_cause, tvb, curr_offset, 1, FALSE);
3634 return(curr_offset - offset);
3638 * [3] 10.5.2.32 SI 1 Rest Octets
3640 static const value_string gsm_a_rr_nch_position_vals[] = {
3641 { 0, "No of blocks = 1 and Number of first block = 0"},
3642 { 1, "No of blocks = 1 and Number of first block = 1"},
3643 { 2, "No of blocks = 1 and Number of first block = 2"},
3644 { 3, "No of blocks = 1 and Number of first block = 3"},
3645 { 4, "No of blocks = 1 and Number of first block = 4"},
3646 { 5, "No of blocks = 1 and Number of first block = 5"},
3647 { 6, "No of blocks = 1 and Number of first block = 6"},
3648 { 7, "No of blocks = 1 and Number of first block = 0"},
3649 { 8, "No of blocks = 2 and Number of first block = 1"},
3650 { 9, "No of blocks = 2 and Number of first block = 2"},
3651 {10, "No of blocks = 2 and Number of first block = 3"},
3652 {11, "No of blocks = 2 and Number of first block = 4"},
3653 {12, "No of blocks = 2 and Number of first block = 5"},
3654 {13, "No of blocks = 3 and Number of first block = 0"},
3655 {14, "No of blocks = 3 and Number of first block = 1"},
3656 {15, "No of blocks = 3 and Number of first block = 2"},
3657 {16, "No of blocks = 3 and Number of first block = 3"},
3658 {17, "No of blocks = 3 and Number of first block = 4"},
3659 {18, "No of blocks = 4 and Number of first block = 0"},
3660 {19, "No of blocks = 4 and Number of first block = 1"},
3661 {20, "No of blocks = 4 and Number of first block = 2"},
3662 {21, "No of blocks = 4 and Number of first block = 3"},
3663 {22, "No of blocks = 5 and Number of first block = 0"},
3664 {23, "No of blocks = 5 and Number of first block = 1"},
3665 {24, "No of blocks = 5 and Number of first block = 2"},
3666 {25, "No of blocks = 6 and Number of first block = 0"},
3667 {26, "No of blocks = 6 and Number of first block = 1"},
3668 {27, "No of blocks = 7 and Number of first block = 0"},
3677 de_rr_si1_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
3679 proto_tree *subtree;
3681 guint32 curr_offset;
3685 curr_offset = offset;
3686 bit_offset = curr_offset << 3;
3688 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
3689 gsm_rr_elem_strings[DE_RR_SI1_REST_OCT].strptr);
3691 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI1_REST_OCT]);
3693 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3696 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nch_position, tvb, bit_offset, 5, FALSE);
3701 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "NCH position: not present");
3704 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3705 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Band Indicator: 1900");
3707 proto_tree_add_text(subtree,tvb, bit_offset>>3, 1, "Band Indicator: 1800");
3710 curr_offset = curr_offset + len;
3712 return curr_offset-offset;
3716 * [3] 10.5.2.33 SI 2bis Rest Octets
3720 * [3] 10.5.2.33a SI 2ter Rest Octets
3722 static const value_string gsm_a_rr_qsearch_x_vals[] = {
3742 static const value_string gsm_a_rr_xdd_qoffset_vals[] = {
3743 { 0, "always select a cell if acceptable"},
3762 static const value_string gsm_a_rr_fdd_qmin_vals[] = {
3774 static const value_string gsm_a_rr_fdd_qmin_offset_vals[] = {
3786 static const value_string gsm_a_rr_fdd_rscpmin_vals[] = {
3807 de_rr_si2ter_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
3809 proto_tree *subtree, *subtree2;
3810 proto_item *item, *item2;
3811 guint32 curr_offset;
3812 gint bit_offset, bit_offset_sav;
3816 curr_offset = offset;
3817 bit_offset = curr_offset<<3;
3819 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
3820 gsm_rr_elem_strings[DE_RR_SI2TER_REST_OCT].strptr);
3822 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI2TER_REST_OCT]);
3824 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3827 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2ter_mp_change_mark, tvb, bit_offset, 1, FALSE);
3829 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2ter_3g_change_mark, tvb, bit_offset, 1, FALSE);
3831 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2ter_index, tvb, bit_offset, 3, FALSE);
3833 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2ter_count, tvb, bit_offset, 3, FALSE);
3835 value = tvb_get_bits8(tvb,bit_offset,1);
3838 { /* UTRAN FDD Description */
3839 bit_offset_sav = bit_offset;
3840 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_FDD_DESC].strptr);
3841 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_FDD_DESC]);
3842 bit_offset += 2; /* skip '01' bits */
3843 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_uarfcn, tvb, bit_offset, 14, FALSE);
3845 value = tvb_get_bits8(tvb,bit_offset,1);
3849 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_bandwidth_fdd, tvb, bit_offset, 3, FALSE);
3852 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
3854 value = tvb_get_bits8(tvb,bit_offset,1);
3857 { /* UTRAN TDD Description */
3858 bit_offset_sav = bit_offset;
3859 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_TDD_DESC].strptr);
3860 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_TDD_DESC]);
3861 bit_offset += 2; /* skip '01' bits */
3862 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_uarfcn, tvb, bit_offset, 14, FALSE);
3864 value = tvb_get_bits8(tvb,bit_offset,1);
3868 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_bandwidth_tdd, tvb, bit_offset, 3, FALSE);
3871 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
3873 value = tvb_get_bits8(tvb,bit_offset,1);
3876 { /* 3G Measurement Parameters Description */
3877 bit_offset_sav = bit_offset;
3878 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC].strptr);
3879 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC]);
3880 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_qsearch_i, tvb, bit_offset, 4, FALSE);
3882 value = tvb_get_bits8(tvb,bit_offset,1);
3886 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qoffset, tvb, bit_offset, 4, FALSE);
3888 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qmin, tvb, bit_offset, 3, FALSE);
3891 value = tvb_get_bits8(tvb,bit_offset,1);
3895 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_qoffset, tvb, bit_offset, 4, FALSE);
3898 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
3900 if (((curr_offset + len)<<3) - bit_offset > 0)
3902 /* There is still room left in the Rest Octets IE */
3903 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
3904 { /* Additions in release R5 */
3906 value = tvb_get_bits8(tvb,bit_offset,1);
3909 { /* 3G Additional Measurement Parameters Description */
3910 bit_offset_sav = bit_offset;
3911 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC].strptr);
3912 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC]);
3913 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qmin_offset, tvb, bit_offset, 3, FALSE);
3915 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_rscpmin, tvb, bit_offset, 4, FALSE);
3917 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
3927 proto_tree_add_text(subtree,tvb, curr_offset, len ,"Empty");
3930 curr_offset = curr_offset + len;
3932 return curr_offset-offset;
3936 * [3] 10.5.2.33b SI 2quater Rest Octets
3938 static const true_false_string gsm_a_rr_gsm_report_type_value = {
3939 "The MS shall use the Measurement Report message for reporting",
3940 "The MS shall use the Enhanced Measurement Report message for reporting if at least one BSIC is allocated to each BA (list) frequency. Otherwise, the Measurement Report message shall be used"
3943 static const true_false_string gsm_a_rr_frequency_scrolling_value = {
3944 "Next BSIC in the structure relates to the subsequent frequency in the BA(list)",
3945 "Next BSIC in the structure relates to the same frequency in the BA(list)"
3948 static const true_false_string gsm_a_rr_rep_priority_value = {
3949 "High reporting priority",
3950 "Normal reporting priority"
3953 static const true_false_string gsm_a_rr_report_type_value = {
3954 "The MS shall use the PACKET MEASUREMENT REPORT message for reporting",
3955 "The MS shall use the PACKET ENHANCED MEASUREMENT REPORT message for reporting"
3958 static const true_false_string gsm_a_rr_reporting_rate_value = {
3959 "Reduced reporting rate allowed",
3960 "Normal reporting rate"
3963 static const true_false_string gsm_a_rr_invalid_bsic_reporting_value = {
3964 "Report on cells with invalid BSIC and allowed NCC part of BSIC is allowed",
3965 "Report on cells with invalid BSIC and allowed NCC part of BSIC is not allowed"
3968 static const value_string gsm_a_rr_scale_ord_vals[] = {
3969 { 0, "An offset of 0 dB shall be used for the reported RXLEV values"},
3970 { 1, "An offset of 10 dB shall be used for the reported RXLEV values"},
3971 { 2, "An automatic offset shall be used for the reported RXLEV values"},
3975 static const value_string gsm_a_rr_xxx_reporting_offset_vals[] = {
3976 { 0, "Apply an offset of 0 dB to the reported value when prioritising the cells for reporting"},
3977 { 1, "Apply an offset of 6 dB to the reported value when prioritising the cells for reporting"},
3978 { 2, "Apply an offset of 12 dB to the reported value when prioritising the cells for reporting"},
3979 { 3, "Apply an offset of 18 dB to the reported value when prioritising the cells for reporting"},
3980 { 4, "Apply an offset of 24 dB to the reported value when prioritising the cells for reporting"},
3981 { 5, "Apply an offset of 30 dB to the reported value when prioritising the cells for reporting"},
3982 { 6, "Apply an offset of 36 dB to the reported value when prioritising the cells for reporting"},
3983 { 7, "Apply an offset of 42 dB to the reported value when prioritising the cells for reporting"},
3987 static const value_string gsm_a_rr_xxx_reporting_threshold_vals[] = {
3988 { 0, "Apply priority reporting if the reported value is above 0 dB"},
3989 { 1, "Apply priority reporting if the reported value is above 6 dB"},
3990 { 2, "Apply priority reporting if the reported value is above 12 dB"},
3991 { 3, "Apply priority reporting if the reported value is above 18 dB"},
3992 { 4, "Apply priority reporting if the reported value is above 24 dB"},
3993 { 5, "Apply priority reporting if the reported value is above 30 dB"},
3994 { 6, "Apply priority reporting if the reported value is above 36 dB"},
3995 { 7, "Never apply priority reporting"},
3999 static const value_string gsm_a_rr_network_control_order_vals[] = {
4007 static const value_string gsm_a_rr_nc_non_drx_period_vals[] = {
4008 { 0, "No non-DRX mode after a measurement report has been sent"},
4019 static const value_string gsm_a_rr_nc_reporting_period_x_vals[] = {
4031 static const true_false_string gsm_a_rr_qsearch_c_initial_value = {
4036 static const true_false_string gsm_a_rr_fdd_rep_quant_value = {
4041 static const true_false_string gsm_a_rr_3g_search_prio_value = {
4042 "3G cells may be searched when BSIC decoding is required",
4043 "3G cells may not be searched when BSIC decoding is required"
4046 static const true_false_string gsm_a_rr_3g_ccn_active_value = {
4047 "CCN towards 3G cells is enabled in the cell",
4048 "CCN towards 3G cells is disabled in the cell"
4052 de_rr_si2quater_meas_info_utran_fdd_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
4054 proto_tree *subtree, *subtree2;
4055 proto_item *item, *item2;
4056 gint curr_bit_offset, idx;
4057 gint xdd_cell_info, wsize, nwi, jwi, w[64], i, iused, xdd_indic0;
4060 curr_bit_offset = bit_offset;
4062 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_FDD_DESC].strptr);
4063 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_FDD_DESC]);
4064 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4065 curr_bit_offset += 1;
4068 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bandwidth_fdd, tvb, curr_bit_offset, 3, FALSE);
4069 curr_bit_offset += 3;
4071 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4072 curr_bit_offset += 1;
4075 curr_bit_offset += 1; /* skip a 0 bit */
4076 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_uarfcn, tvb, curr_bit_offset, 14, FALSE);
4077 curr_bit_offset += 14;
4078 xdd_indic0 = tvb_get_bits8(tvb,curr_bit_offset,1);
4079 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "FDD Indic0: %d", xdd_indic0);
4080 curr_bit_offset += 1;
4081 idx = tvb_get_bits8(tvb,curr_bit_offset,5);
4082 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "Nr of FDD Cells : %d", idx);
4083 curr_bit_offset += 5;
4084 idx = convert_n_to_p[idx];
4085 item2 = proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, (idx>>3)+1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_FDD_DESC].strptr);
4086 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_FDD_CELL_INFORMATION_FIELD]);
4087 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, (idx>>3)+1, "Field is %d bits long", idx);
4090 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Scrambling Code: %d", 0);
4091 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Diversity: %d", 0);
4102 w[i] = tvb_get_bits16(tvb, curr_bit_offset, wsize, FALSE);
4103 curr_bit_offset += wsize;
4120 curr_bit_offset += idx;
4124 for (i=1; i <= iused; i++)
4126 xdd_cell_info = f_k(i, w, 1024);
4127 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Scrambling Code: %d", xdd_cell_info & 0x01FF);
4128 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Diversity: %d", (xdd_cell_info >> 9) & 0x01);
4131 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4132 curr_bit_offset += 1;
4134 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4136 return (curr_bit_offset - bit_offset);
4140 de_rr_si2quater_meas_info_utran_tdd_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
4142 proto_tree *subtree, *subtree2;
4143 proto_item *item, *item2;
4144 gint curr_bit_offset, idx;
4145 gint xdd_cell_info, wsize, nwi, jwi, w[64], i, iused, xdd_indic0;
4148 curr_bit_offset = bit_offset;
4150 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_TDD_DESC].strptr);
4151 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_UTRAN_TDD_DESC]);
4152 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4153 curr_bit_offset += 1;
4156 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bandwidth_tdd, tvb, curr_bit_offset, 3, FALSE);
4157 curr_bit_offset += 3;
4159 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4160 curr_bit_offset += 1;
4163 curr_bit_offset += 1; /* skip a 0 bit */
4164 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_tdd_uarfcn, tvb, curr_bit_offset, 14, FALSE);
4165 curr_bit_offset += 14;
4166 xdd_indic0 = tvb_get_bits8(tvb,curr_bit_offset,1);
4167 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "TDD Indic0: %d", xdd_indic0);
4168 curr_bit_offset += 1;
4169 idx = tvb_get_bits8(tvb,curr_bit_offset,5);
4170 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "Nr of TDD Cells : %d", idx);
4171 curr_bit_offset += 5;
4172 idx = convert_n_to_q[idx];
4173 item2 = proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, (idx>>3)+1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_UTRAN_TDD_DESC].strptr);
4174 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_TDD_CELL_INFORMATION_FIELD]);
4175 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, (idx>>3)+1, "Field is %d bits long", idx);
4178 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Cell Parameter: %d", 0);
4179 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Sync Case TSTD: %d", 0);
4180 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Diversity TDD: %d", 0);
4191 w[i] = tvb_get_bits16(tvb, curr_bit_offset, wsize, FALSE);
4192 curr_bit_offset += wsize;
4209 curr_bit_offset += idx;
4213 for (i=1; i <= iused; i++)
4215 xdd_cell_info = f_k(i, w, 512);
4216 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Cell Parameter: %d", xdd_cell_info & 0x07F);
4217 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Sync Case TSTD: %d", (xdd_cell_info >> 7) & 0x01);
4218 proto_tree_add_text(subtree2,tvb, curr_bit_offset>>3, 0, "Diversity TDD: %d", (xdd_cell_info >> 8) & 0x01);
4221 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4222 curr_bit_offset += 1;
4224 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4226 return (curr_bit_offset - bit_offset);
4230 de_rr_rtd_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset, rr_rest_octets_elem_idx_t id)
4232 proto_tree *subtree;
4234 gint curr_bit_offset, idx;
4237 curr_bit_offset = bit_offset;
4239 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[id].strptr);
4240 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[id]);
4241 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4242 curr_bit_offset += 1;
4245 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4246 curr_bit_offset += 1;
4249 idx = tvb_get_bits8(tvb,curr_bit_offset,5);
4250 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "BA Index Start RTD: %d", idx);
4251 curr_bit_offset += 5;
4255 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4256 curr_bit_offset += 1;
4259 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "RTD index %d: %d TDMA frame(s) modulo 51 TDMA frames", idx, tvb_get_bits8(tvb,curr_bit_offset,6));
4260 curr_bit_offset += 6;
4261 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4262 curr_bit_offset += 1;
4264 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4265 curr_bit_offset += 1;
4269 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4270 curr_bit_offset += 1;
4273 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "RTD index %d: %d TDMA frame(s) modulo 51 TDMA frames", idx, tvb_get_bits8(tvb,curr_bit_offset,6));
4274 curr_bit_offset += 6;
4275 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4276 curr_bit_offset += 1;
4280 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4281 curr_bit_offset += 1;
4284 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4285 curr_bit_offset += 1;
4288 idx = tvb_get_bits8(tvb,curr_bit_offset,5);
4289 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "BA Index Start RTD: %d", idx);
4290 curr_bit_offset += 5;
4294 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4295 curr_bit_offset += 1;
4298 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 2, "RTD index %d: %d/64 TDMA frame(s) modulo 51 TDMA frames", idx, tvb_get_bits16(tvb,curr_bit_offset,12,FALSE));
4299 curr_bit_offset += 12;
4300 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4301 curr_bit_offset += 1;
4303 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4304 curr_bit_offset += 1;
4308 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4309 curr_bit_offset += 1;
4312 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 2, "RTD index %d: %d/64 TDMA frame(s) modulo 51 TDMA frames", idx, tvb_get_bits16(tvb,curr_bit_offset,12,FALSE));
4313 curr_bit_offset += 12;
4314 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4315 curr_bit_offset += 1;
4319 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4321 return (curr_bit_offset - bit_offset);
4325 de_rr_bsic_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset, rr_rest_octets_elem_idx_t id)
4327 proto_tree *subtree;
4329 gint curr_bit_offset, idx;
4332 curr_bit_offset = bit_offset;
4333 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[id].strptr);
4334 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[id]);
4335 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4336 curr_bit_offset += 1;
4339 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "BA Index Start BSIC: %d", tvb_get_bits8(tvb,curr_bit_offset,5));
4340 curr_bit_offset += 5;
4342 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bsic, tvb, bit_offset, 6, FALSE);
4343 curr_bit_offset += 6;
4344 idx = tvb_get_bits8(tvb,curr_bit_offset,7);
4345 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "Number Remaining BSIC: %d", idx);
4346 curr_bit_offset += 7;
4349 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_frequency_scrolling, tvb, curr_bit_offset, 1, FALSE);
4350 curr_bit_offset += 1;
4351 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bsic, tvb, bit_offset, 6, FALSE);
4352 curr_bit_offset += 6;
4355 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4357 return(curr_bit_offset - bit_offset);
4361 de_rr_report_priority_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset, rr_rest_octets_elem_idx_t id)
4363 proto_tree *subtree;
4365 gint curr_bit_offset, idx;
4367 curr_bit_offset = bit_offset;
4369 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[id].strptr);
4370 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[id]);
4371 idx = tvb_get_bits8(tvb,curr_bit_offset,7);
4372 proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, 1, "Number Cells: %d", idx);
4373 curr_bit_offset += 7;
4376 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rep_priority, tvb, curr_bit_offset, 1, FALSE);
4377 curr_bit_offset += 1;
4380 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4382 return(curr_bit_offset - bit_offset);
4386 de_rr_meas_param_desc(tvbuff_t *tvb, proto_tree *tree, gint bit_offset, rr_rest_octets_elem_idx_t id)
4388 proto_tree *subtree;
4390 gint curr_bit_offset;
4393 curr_bit_offset = bit_offset;
4394 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[id].strptr);
4395 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[id]);
4396 if (id == DE_RR_REST_OCTETS_GPRS_MEAS_PARAM_DESC)
4398 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_report_type, tvb, curr_bit_offset, 1, FALSE);
4399 curr_bit_offset += 1;
4400 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_reporting_rate, tvb, curr_bit_offset, 1, FALSE);
4401 curr_bit_offset +=1;
4402 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_invalid_bsic_reporting, tvb, curr_bit_offset, 1, FALSE);
4403 curr_bit_offset +=1;
4405 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4406 curr_bit_offset += 1;
4409 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_multiband_reporting, tvb, curr_bit_offset, 2, FALSE);
4410 curr_bit_offset += 2;
4412 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4413 curr_bit_offset += 1;
4416 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_serving_band_reporting, tvb, curr_bit_offset, 2, FALSE);
4417 curr_bit_offset += 2;
4419 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_scale_ord, tvb, curr_bit_offset, 2, FALSE);
4420 curr_bit_offset += 2;
4421 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4422 curr_bit_offset += 1;
4425 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_900_reporting_offset, tvb, curr_bit_offset, 3, FALSE);
4426 curr_bit_offset += 3;
4427 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_900_reporting_threshold, tvb, curr_bit_offset, 3, FALSE);
4428 curr_bit_offset += 3;
4430 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4431 curr_bit_offset += 1;
4434 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_1800_reporting_offset, tvb, curr_bit_offset, 3, FALSE);
4435 curr_bit_offset += 3;
4436 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_1800_reporting_threshold, tvb, curr_bit_offset, 3, FALSE);
4437 curr_bit_offset += 3;
4439 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4440 curr_bit_offset += 1;
4443 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_400_reporting_offset, tvb, curr_bit_offset, 3, FALSE);
4444 curr_bit_offset += 3;
4445 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_400_reporting_threshold, tvb, curr_bit_offset, 3, FALSE);
4446 curr_bit_offset += 3;
4448 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4449 curr_bit_offset += 1;
4452 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_1900_reporting_offset, tvb, curr_bit_offset, 3, FALSE);
4453 curr_bit_offset += 3;
4454 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_1900_reporting_threshold, tvb, curr_bit_offset, 3, FALSE);
4455 curr_bit_offset += 3;
4457 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4458 curr_bit_offset += 1;
4461 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_850_reporting_offset, tvb, curr_bit_offset, 3, FALSE);
4462 curr_bit_offset += 3;
4463 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_850_reporting_threshold, tvb, curr_bit_offset, 3, FALSE);
4464 curr_bit_offset += 3;
4466 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4468 return(curr_bit_offset - bit_offset);
4472 de_rr_3g_add_meas_param_desc2(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
4474 proto_tree *subtree;
4476 gint curr_bit_offset;
4479 curr_bit_offset = bit_offset;
4480 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC2].strptr);
4481 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC2]);
4482 value = tvb_get_bits8(tvb,curr_bit_offset,1);
4483 curr_bit_offset += 1;
4486 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_reporting_threshold_2, tvb, curr_bit_offset, 6, FALSE);
4487 curr_bit_offset += 6;
4489 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4491 return(curr_bit_offset - bit_offset);
4495 de_rr_si2quater_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
4497 proto_tree *subtree, *subtree2, *subtree3;
4498 proto_item *item, *item2, *item3;
4499 guint32 curr_offset;
4500 gint bit_offset, bit_offset_sav, idx;
4504 curr_offset = offset;
4505 bit_offset = curr_offset<<3;
4507 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
4508 gsm_rr_elem_strings[DE_RR_SI2QUATER_REST_OCT].strptr);
4510 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI2QUATER_REST_OCT]);
4512 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_ba_ind, tvb, bit_offset, 1, FALSE);
4514 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_3g_ba_ind, tvb, bit_offset, 1, FALSE);
4516 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_mp_change_mark, tvb, bit_offset, 1, FALSE);
4518 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2quater_index, tvb, bit_offset, 4, FALSE);
4520 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2quater_count, tvb, bit_offset, 4, FALSE);
4522 value = tvb_get_bits8(tvb,bit_offset,1);
4525 { /* Measurement Parameters Description */
4526 bit_offset_sav = bit_offset;
4527 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_MEAS_PARAM_DESC].strptr);
4528 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_MEAS_PARAM_DESC]);
4529 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_gsm_report_type, tvb, bit_offset, 1, FALSE);
4531 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_serving_band_reporting, tvb, bit_offset, 2, FALSE);
4533 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4535 value = tvb_get_bits8(tvb,bit_offset,1);
4538 { /* GPRS Real Time Difference Description */
4539 bit_offset += de_rr_rtd_desc(tvb, subtree, bit_offset, DE_RR_REST_OCTETS_GPRS_RTD_DESC);
4542 value = tvb_get_bits8(tvb,bit_offset,1);
4545 { /* GPRS BSIC Description */
4546 bit_offset += de_rr_bsic_desc(tvb, subtree, bit_offset, DE_RR_REST_OCTETS_GPRS_BSIC_DESC);
4548 value = tvb_get_bits8(tvb,bit_offset,1);
4551 { /* GPRS Report Priority Description */
4552 bit_offset += de_rr_report_priority_desc(tvb, subtree, bit_offset, DE_RR_REST_OCTETS_GPRS_REPORT_PRIO_DESC);
4554 value = tvb_get_bits8(tvb,bit_offset,1);
4557 { /* GPRS Measurement Parameters Description */
4558 bit_offset += de_rr_meas_param_desc(tvb, subtree, bit_offset, DE_RR_REST_OCTETS_GPRS_MEAS_PARAM_DESC);
4560 value = tvb_get_bits8(tvb,bit_offset,1);
4563 { /* NC Measurement Parameters */
4564 bit_offset_sav = bit_offset;
4565 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_NC_MEAS_PARAM].strptr);
4566 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_NC_MEAS_PARAM]);
4567 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_network_control_order, tvb, bit_offset, 2, FALSE);
4569 value = tvb_get_bits8(tvb,bit_offset,1);
4573 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nc_non_drx_period, tvb, bit_offset, 3, FALSE);
4575 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nc_reporting_period_i, tvb, bit_offset, 3, FALSE);
4577 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nc_reporting_period_t, tvb, bit_offset, 3, FALSE);
4580 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4582 value = tvb_get_bits8(tvb,bit_offset,1);
4585 { /* SI 2quater Extension Information */
4586 bit_offset_sav = bit_offset;
4587 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_SI2Q_EXT_INFO].strptr);
4588 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_SI2Q_EXT_INFO]);
4589 idx = tvb_get_bits8(tvb,bit_offset,8);
4590 proto_tree_add_text(subtree2,tvb, bit_offset>>3, 1, "Extension Length: %d", idx);
4592 proto_item_set_len(item2,((bit_offset+idx+1-bit_offset_sav)>>3)+1);
4593 value = tvb_get_bits8(tvb,bit_offset,1);
4596 { /* CCN Support Description */
4597 bit_offset_sav = bit_offset;
4598 item3 = proto_tree_add_text(subtree2, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_CCN_SUPPORT_DESC].strptr);
4599 subtree3 = proto_item_add_subtree(item3, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_CCN_SUPPORT_DESC]);
4600 value = tvb_get_bits8(tvb,bit_offset,7);
4601 proto_tree_add_text(subtree3,tvb, bit_offset>>3, 1, "Number Cells: %d", value);
4604 item2 = proto_tree_add_text(subtree3,tvb, bit_offset>>3, (value>>3)+1, "CCN Supported: ");
4607 proto_item_append_text(item2,"%d",tvb_get_bits8(tvb,bit_offset,1));
4612 proto_item_set_len(item3,((bit_offset+-bit_offset_sav)>>3)+1);
4616 value = tvb_get_bits8(tvb,bit_offset,1);
4619 { /* 3G Neighbour Cell Description */
4620 bit_offset_sav = bit_offset;
4621 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_NEIGH_CELL_DESC].strptr);
4622 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_NEIGH_CELL_DESC]);
4623 value = tvb_get_bits8(tvb,bit_offset,1);
4627 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_index_start_3g, tvb, bit_offset, 7, FALSE);
4630 value = tvb_get_bits8(tvb,bit_offset,1);
4634 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_absolute_index_start_emr, tvb, bit_offset, 7, FALSE);
4637 value = tvb_get_bits8(tvb,bit_offset,1);
4640 { /* UTRAN FDD Description */
4641 bit_offset += de_rr_si2quater_meas_info_utran_fdd_desc(tvb, subtree2, bit_offset);
4643 value = tvb_get_bits8(tvb,bit_offset,1);
4646 { /* UTRAN TDD Description */
4647 bit_offset += de_rr_si2quater_meas_info_utran_tdd_desc(tvb, subtree2, bit_offset);
4649 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4651 value = tvb_get_bits8(tvb,bit_offset,1);
4654 { /* 3G Measurement Parameters Description */
4655 bit_offset_sav = bit_offset;
4656 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC].strptr);
4657 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC]);
4658 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_qsearch_i, tvb, bit_offset, 4, FALSE);
4660 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_qsearch_c_initial, tvb, bit_offset, 1, FALSE);
4662 value = tvb_get_bits8(tvb,bit_offset,1);
4666 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qoffset, tvb, bit_offset, 4, FALSE);
4668 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_rep_quant, tvb, bit_offset, 1, FALSE);
4670 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
4672 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qmin, tvb, bit_offset, 3, FALSE);
4675 value = tvb_get_bits8(tvb,bit_offset,1);
4679 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_qoffset, tvb, bit_offset, 4, FALSE);
4681 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
4684 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4686 value = tvb_get_bits8(tvb,bit_offset,1);
4689 { /* GPRS 3G Measurement Parameters Description */
4690 bit_offset_sav = bit_offset;
4691 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_3G_MEAS_PARAM_DESC].strptr);
4692 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_3G_MEAS_PARAM_DESC]);
4693 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_qsearch_p, tvb, bit_offset, 4, FALSE);
4695 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_3g_search_prio, tvb, bit_offset, 1, FALSE);
4697 value = tvb_get_bits8(tvb,bit_offset,1);
4701 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_rep_quant, tvb, bit_offset, 1, FALSE);
4703 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
4706 value = tvb_get_bits8(tvb,bit_offset,1);
4710 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_reporting_offset, tvb, bit_offset, 3, FALSE);
4712 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_reporting_threshold, tvb, bit_offset, 3, FALSE);
4715 value = tvb_get_bits8(tvb,bit_offset,1);
4719 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
4722 value = tvb_get_bits8(tvb,bit_offset,1);
4726 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_reporting_offset, tvb, bit_offset, 3, FALSE);
4728 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_tdd_reporting_threshold, tvb, bit_offset, 3, FALSE);
4731 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4733 if (((curr_offset + len)<<3) - bit_offset > 0)
4735 /* There is still room left in the Rest Octets IE */
4736 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
4737 { /* Additions in Rel-5 */
4739 value = tvb_get_bits8(tvb,bit_offset,1);
4742 { /* 3G Additional Measurement Parameters Description */
4743 bit_offset_sav = bit_offset;
4744 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC].strptr);
4745 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_ADD_MEAS_PARAM_DESC]);
4746 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_qmin_offset, tvb, bit_offset, 3, FALSE);
4748 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_fdd_rscpmin, tvb, bit_offset, 4, FALSE);
4750 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
4752 value = tvb_get_bits8(tvb,bit_offset,1);
4755 { /* 3G Additional Measurement Parameters Description 2 */
4756 bit_offset += de_rr_3g_add_meas_param_desc2(tvb, subtree, bit_offset);
4758 if (((curr_offset + len)<<3) - bit_offset > 0)
4760 /* There is still room left in the Rest Octets IE */
4761 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
4762 { /* Additions in Rel-6 */
4764 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_3g_ccn_active, tvb, bit_offset, 1, FALSE);
4766 if (((curr_offset + len)<<3) - bit_offset > 0)
4768 /* There is still room left in the Rest Octets IE */
4769 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
4770 { /* Additions in Rel-7 */
4772 value = tvb_get_bits8(tvb,bit_offset,1);
4776 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_700_reporting_offset, tvb, bit_offset, 3, FALSE);
4778 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_700_reporting_threshold, tvb, bit_offset, 3, FALSE);
4781 value = tvb_get_bits8(tvb,bit_offset,1);
4785 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_810_reporting_offset, tvb, bit_offset, 3, FALSE);
4787 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_810_reporting_threshold, tvb, bit_offset, 3, FALSE);
4799 else bit_offset += 1;
4802 curr_offset = curr_offset + len;
4804 return curr_offset-offset;
4808 * [3] 10.5.2.34 SI 3 Rest Octets
4810 static const value_string gsm_a_rr_temporary_offset_vals[] = {
4822 static const value_string gsm_a_rr_cell_reselect_offset_vals[] = {
4890 static const value_string gsm_a_rr_penalty_time_vals[] = {
4922 {31, "Cell Reselect Offset is subtracted from C2 and Temporary Offset is ignored"},
4927 de_rr_rest_oct_opt_sel_param(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
4929 proto_tree *subtree;
4931 gint curr_bit_offset;
4933 curr_bit_offset = bit_offset;
4935 if (gsm_a_rr_is_bit_high(tvb,curr_bit_offset) == TRUE)
4936 { /* Selection Parameters */
4937 curr_bit_offset += 1;
4938 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_OPTIONAL_SEL_PARAM].strptr);
4939 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_OPTIONAL_SEL_PARAM]);
4940 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_cbq, tvb, curr_bit_offset, 1, FALSE);
4941 curr_bit_offset += 1;
4942 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_cell_reselect_offset, tvb, curr_bit_offset, 6, FALSE);
4943 curr_bit_offset += 6;
4944 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_temporary_offset, tvb, curr_bit_offset, 3, FALSE);
4945 curr_bit_offset += 3;
4946 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_penalty_time, tvb, curr_bit_offset, 5, FALSE);
4947 curr_bit_offset += 5;
4948 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
4951 curr_bit_offset += 1;
4953 return (curr_bit_offset - bit_offset);
4956 static const value_string gsm_a_rr_si13_position_vals[] = {
4957 { 0, "SYSTEM INFORMATION TYPE 13 message is sent on BCCH Norm"},
4958 { 1, "SYSTEM INFORMATION TYPE 13 message is sent on BCCH Ext"},
4963 de_rr_rest_oct_gprs_indicator(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
4965 proto_tree *subtree;
4967 gint curr_bit_offset;
4969 curr_bit_offset = bit_offset;
4971 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, 1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_INDICATOR].strptr);
4972 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_INDICATOR]);
4973 proto_tree_add_text(subtree, tvb, curr_bit_offset>>3, 1, "RA Colour: %d",tvb_get_bits8(tvb,curr_bit_offset,3));
4974 curr_bit_offset += 3;
4975 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si13_position, tvb, curr_bit_offset, 1, FALSE);
4976 curr_bit_offset += 1;
4978 return (curr_bit_offset - bit_offset);
4981 static const value_string gsm_a_rr_power_offset_vals[] = {
4989 static const true_false_string gsm_a_rr_si2quater_position_value = {
4990 "SYSTEM INFORMATION TYPE 2 quater message is sent on BCCH Ext",
4991 "SYSTEM INFORMATION TYPE 2 quater message is sent on BCCH Norm"
4994 static const true_false_string gsm_a_rr_si13alt_position_value = {
4995 "If Iu mode is supported in the cell, SYSTEM INFORMATION TYPE 13alt message is sent on BCCH Ext",
4996 "If Iu mode is supported in the cell, SYSTEM INFORMATION TYPE 13alt message is sent on BCCH Norm"
5000 de_rr_si3_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
5002 proto_tree *subtree;
5004 guint32 curr_offset;
5006 gboolean gprs_indicator;
5009 curr_offset = offset;
5010 bit_offset = curr_offset << 3;
5012 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
5013 gsm_rr_elem_strings[DE_RR_SI3_REST_OCT].strptr);
5015 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI3_REST_OCT]);
5017 bit_offset += de_rr_rest_oct_opt_sel_param(tvb, subtree, bit_offset);
5019 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5020 { /* Optional Power Offset */
5022 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_power_offset, tvb, bit_offset, 2, FALSE);
5027 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5028 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "SYSTEM INFORMATION TYPE 2ter message is available");
5030 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "SYSTEM INFORMATION TYPE 2ter message is not available");
5032 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5033 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Early Classmark Sending is allowed");
5035 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Early Classmark Sending is forbidden");
5037 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5038 { /* Scheduling if and where */
5040 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Where: %d",tvb_get_bits8(tvb,bit_offset,3));
5045 gprs_indicator = gsm_a_rr_is_bit_high(tvb,bit_offset);
5046 if (gprs_indicator == TRUE)
5047 { /* GPRS indicator */
5049 bit_offset += de_rr_rest_oct_gprs_indicator(tvb, subtree, bit_offset);
5053 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5054 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "3G Early Classmark Sending Restriction: The sending of UTRAN,CDMA2000 and GERAN IU MODE CLASSMARK CHANGE messages are controlled by the Early Classmark Sending Control parameter");
5056 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "3G Early Classmark Sending Restriction: Neither UTRAN, CDMA2000 nor GERAN IU MODE CLASSMARK CHANGE message shall be sent with the Early classmark sending");
5058 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5059 { /* SI2quater Indicator */
5061 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2quater_position, tvb, bit_offset, 1, FALSE);
5066 if (gprs_indicator == FALSE)
5068 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si13alt_position, tvb, bit_offset, 1, FALSE);
5072 curr_offset = curr_offset + len;
5074 return curr_offset-offset;
5078 * [3] 10.5.2.32 SI 4 Rest Octets
5080 static const value_string gsm_a_rr_prio_thr_vals[] = {
5092 static const value_string gsm_a_rr_lsa_offset_vals[] = {
5105 de_rr_si4_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
5107 proto_tree *subtree, *subtree2, *subtree3;
5108 proto_item *item, *item2, *item3;
5109 guint32 curr_offset;
5110 gint bit_offset, bit_offset_sav, bit_offset_sav2;
5113 len = tvb_length_remaining(tvb,offset);
5117 curr_offset = offset;
5118 bit_offset = curr_offset << 3;
5120 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
5121 gsm_rr_elem_strings[DE_RR_SI4_REST_OCT].strptr);
5123 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI4_REST_OCT]);
5125 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_SI4_REST_OCTETS_O].strptr);
5127 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_SI4_REST_OCTETS_O]);
5129 bit_offset += de_rr_rest_oct_opt_sel_param(tvb, subtree2, bit_offset);
5131 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5132 { /* Optional Power Offset */
5134 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_power_offset, tvb, bit_offset, 2, FALSE);
5139 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5142 bit_offset += de_rr_rest_oct_gprs_indicator(tvb, subtree2, bit_offset);
5146 proto_item_set_len(item2,(bit_offset>>3)+1-curr_offset);
5147 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5148 { /* SI4 Rest Octets_S */
5150 bit_offset_sav = bit_offset;
5151 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_SI4_REST_OCTETS_S].strptr);
5152 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_SI4_REST_OCTETS_S]);
5153 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5154 { /* LSA Parameters */
5156 bit_offset_sav2 = bit_offset;
5157 item3 = proto_tree_add_text(subtree2, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_LSA_PARAMETERS].strptr);
5158 subtree3 = proto_item_add_subtree(item3, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_LSA_PARAMETERS]);
5159 proto_tree_add_bits_item(subtree3, hf_gsm_a_rr_prio_thr, tvb, bit_offset, 3, FALSE);
5161 proto_tree_add_bits_item(subtree3, hf_gsm_a_rr_lsa_offset, tvb, bit_offset, 3, FALSE);
5163 value = tvb_get_bits8(tvb,bit_offset,1);
5167 proto_tree_add_text(subtree3, tvb, bit_offset>>3, 2, "MCC: %d", tvb_get_bits16(tvb,bit_offset,12,FALSE));
5169 proto_tree_add_text(subtree3, tvb, bit_offset>>3, 2, "MNC: %d", tvb_get_bits16(tvb,bit_offset,12,FALSE));
5172 proto_item_set_len(item2,((bit_offset-bit_offset_sav2)>>3)+1);
5176 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5177 { /* Cell Identity */
5179 value = tvb_get_bits16(tvb, bit_offset, 16, FALSE);
5180 proto_tree_add_uint(subtree2, hf_gsm_a_bssmap_cell_ci, tvb, bit_offset>>3, 2, value);
5185 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5186 { /* LSA ID information */
5188 bit_offset_sav2 = bit_offset;
5189 item3 = proto_tree_add_text(subtree2, tvb, bit_offset>>3, len, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_LSA_ID_INFO].strptr);
5190 subtree3 = proto_item_add_subtree(item3, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_LSA_ID_INFO]);
5193 value = tvb_get_bits8(tvb,bit_offset,1);
5197 proto_tree_add_text(subtree3, tvb, bit_offset>>3, 3, "Short LSA ID: %d",tvb_get_bits16(tvb,bit_offset,10,FALSE));
5202 proto_tree_add_text(subtree3, tvb, bit_offset>>3, 3, "LSA ID: %d",tvb_get_bits32(tvb,bit_offset,24,FALSE));
5205 value = tvb_get_bits8(tvb,bit_offset,1);
5211 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5214 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_cbq3, tvb, (curr_offset<<3)+1, 2, FALSE);
5219 value = tvb_get_bits8(tvb,bit_offset,1);
5223 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si13alt_position, tvb, bit_offset, 1, FALSE);
5226 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
5229 { /* Break indicator */
5231 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5232 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Break Indicator: Additional parameters \"SI4 Rest Octets_S\" are sent in SYSTEM INFORMATION TYPE 7 and 8");
5234 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Break Indicator: Additional parameters \"SI4 Rest Octets_S\" are not sent in SYSTEM INFORMATION TYPE 7 and 8");
5238 curr_offset = curr_offset + len;
5240 return curr_offset-offset;
5244 * [3] 10.5.2.35a SI 6 Rest Octets
5246 static const true_false_string gsm_a_rr_paging_channel_restructuring_value = {
5247 "Paging channel is restructured",
5248 "Paging channel is not restructured"
5251 static const true_false_string gsm_a_rr_vbs_vgcs_inband_notifications_value = {
5252 "The mobile shall be notified on incoming high priority VBS/VGCS calls through NOTIFICATION/FACCH, the mobile need not to inspect the NCH",
5253 "The network does not provide notification on FACCH so that the mobile should inspect the NCH for notifications"
5256 static const true_false_string gsm_a_rr_vbs_vgcs_inband_pagings_value = {
5257 "The mobile shall be notified on incoming high priority point-to-point calls through NOTIFICATION/FACCH, the mobile need not to inspect the PCH",
5258 "The network does not provide paging information on FACCH so that the mobile should inspect the PCH for pagings"
5261 static const value_string gsm_a_rr_max_lapdm_vals[] = {
5262 { 0, "Any message segmented in up to 5 LAPDm frames"},
5263 { 1, "Any message segmented in up to 6 LAPDm frames"},
5264 { 2, "Any message segmented in up to 7 LAPDm frames"},
5265 { 3, "Any message segmented in up to 8 LAPDm frames"},
5266 { 4, "Any message segmented in up to 9 LAPDm frames"},
5267 { 5, "Any message segmented in up to 10 LAPDm frames"},
5268 { 6, "Any message segmented in up to 11 LAPDm frames"},
5269 { 7, "Any message segmented in up to 12 LAPDm frames"},
5273 static const true_false_string gsm_a_rr_dedicated_mode_mbms_notification_support_value = {
5274 "The cell supports the Dedicated Mode MBMS Notification procedures",
5275 "The cell does not support the Dedicated Mode MBMS Notification procedures"
5278 static const true_false_string gsm_a_rr_mnci_support_value = {
5279 "The cell supports the distribution of MBMS NEIGHBOURING CELL INFORMATION messages",
5280 "The cell does not support the distribution of MBMS NEIGHBOURING CELL INFORMATION messages"
5284 de_rr_si6_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
5286 proto_tree *subtree, *subtree2;
5287 proto_item *item, *item2;
5288 guint32 curr_offset;
5289 gint bit_offset, bit_offset_sav;
5293 curr_offset = offset;
5294 bit_offset = curr_offset << 3;
5296 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
5297 gsm_rr_elem_strings[DE_RR_SI6_REST_OCT].strptr);
5299 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI6_REST_OCT]);
5301 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5302 { /* PCH and NCH Info */
5304 bit_offset_sav = bit_offset;
5305 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_PCH_AND_NCH_INFO].strptr);
5306 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_PCH_AND_NCH_INFO]);
5307 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_paging_channel_restructuring, tvb, bit_offset, 1, FALSE);
5309 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nln_sacch, tvb, bit_offset, 2, FALSE);
5311 value = tvb_get_bits8(tvb,bit_offset,1);
5315 proto_tree_add_bits_item(subtree2, hf_gsm_a_call_prio, tvb, bit_offset, 3, FALSE);
5318 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_nln_status_sacch, tvb, bit_offset, 1, FALSE);
5320 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
5324 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5325 { /* VBS/VGCS options */
5327 bit_offset_sav = bit_offset;
5328 item2 = proto_tree_add_text(subtree, tvb,bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_VBS_VGCS_OPTIONS].strptr);
5329 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_VBS_VGCS_OPTIONS]);
5330 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_vbs_vgcs_inband_notifications, tvb, bit_offset, 1, FALSE);
5332 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_vbs_vgcs_inband_pagings, tvb, bit_offset, 1, FALSE);
5334 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
5338 value = gsm_a_rr_is_bit_high(tvb,bit_offset);
5341 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "DTM is supported in the serving cell");
5343 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rac, tvb, bit_offset, 8, FALSE);
5345 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_max_lapdm, tvb, bit_offset, 3, FALSE);
5350 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "DTM is not supported in the serving cell");
5353 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5354 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Band Indicator: 1900");
5356 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Band Indicator: 1800");
5358 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5361 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_gprs_ms_txpwr_max_ccch, tvb, bit_offset, 5, FALSE);
5366 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5367 { /* MBMS Procedures */
5369 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_dedicated_mode_mbms_notification_support, tvb, bit_offset, 1, FALSE);
5371 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_mnci_support, tvb, bit_offset, 1, FALSE);
5376 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5377 { /* Additions in Release 7 */
5379 value = tvb_get_bits8(tvb,bit_offset,1);
5383 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_amr_config, tvb, bit_offset, 4, FALSE);
5390 curr_offset = curr_offset + len;
5392 return curr_offset-offset;
5395 /* [3] 10.5.2.36 SI 7 Rest Octets
5396 * [3] 10.5.2.37 SI 8 Rest Octets
5397 * [3] 10.5.2.37a SI 9 Rest Octets
5401 * [3] 10.5.2.37b SI 13 Rest Octets
5403 static const value_string gsm_a_rr_si_change_field_vals[] = {
5404 { 0, "Update of unspecified SI message or SI messages"},
5405 { 1, "Update of SI1 message"},
5406 { 2, "Update of SI2, SI2 bis or SI2 ter message or any instance of SI2quater messages"},
5407 { 3, "Update of SI3, SI4, SI7, SI8, SI16 or SI17 message"},
5408 { 4, "Update of SI9 message"},
5409 { 5, "Update of SI18 or SI20 message"},
5410 { 6, "Update of SI19 message"},
5411 { 7, "Update of SI15 message"},
5412 { 8, "Update of SI2n message"},
5413 { 9, "Update of unknown SI message type"},
5414 { 10, "Update of unknown SI message type"},
5415 { 11, "Update of unknown SI message type"},
5416 { 12, "Update of unknown SI message type"},
5417 { 13, "Update of unknown SI message type"},
5418 { 14, "Update of unknown SI message type"},
5419 { 15, "Update of unknown SI message type"},
5423 static const value_string gsm_a_rr_psi1_repeat_period_vals[] = {
5424 { 0, "1 multiframe"},
5425 { 1, "2 multiframes"},
5426 { 2, "3 multiframes"},
5427 { 3, "4 multiframes"},
5428 { 4, "5 multiframes"},
5429 { 5, "6 multiframes"},
5430 { 6, "7 multiframes"},
5431 { 7, "8 multiframes"},
5432 { 8, "9 multiframes"},
5433 { 9, "10 multiframes"},
5434 { 10, "11 multiframes"},
5435 { 11, "12 multiframes"},
5436 { 12, "13 multiframes"},
5437 { 13, "14 multiframes"},
5438 { 14, "15 multiframes"},
5439 { 15, "16 multiframes"},
5443 static const value_string gsm_a_rr_pbcch_pb_vals[] = {
5463 static const true_false_string gsm_a_rr_spgc_ccch_sup_value = {
5464 "SPLIT_PG_CYCLE is supported on CCCH in this cell",
5465 "SPLIT_PG_CYCLE is not supported on CCCH in this cell"
5468 static const value_string gsm_a_rr_priority_access_thr_vals[] = {
5469 { 0, "Packet access is not allowed in the cell"},
5470 { 1, "Packet access is not allowed in the cell"},
5471 { 2, "Packet access is not allowed in the cell"},
5472 { 3, "Packet access is allowed for priority level 1"},
5473 { 4, "Packet access is allowed for priority level 1 to 2"},
5474 { 5, "Packet access is allowed for priority level 1 to 3"},
5475 { 6, "Packet access is allowed for priority level 1 to 4"},
5476 { 7, "Packet access is allowed for priority level 1 to 4"},
5481 de_rr_rest_oct_gprs_mobile_allocation(tvbuff_t *tvb, proto_tree *tree, gint bit_offset)
5483 proto_tree *subtree;
5485 gint curr_bit_offset;
5489 curr_bit_offset = bit_offset;
5491 item = proto_tree_add_text(tree, tvb, curr_bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_GPRS_MOBILE_ALLOC].strptr);
5492 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_GPRS_MOBILE_ALLOC]);
5493 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_hsn, tvb, curr_bit_offset, 6, FALSE);
5494 curr_bit_offset += 6;
5495 while (tvb_get_bits8(tvb,curr_bit_offset,1))
5497 curr_bit_offset += 1;
5498 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rfl_number, tvb, curr_bit_offset, 4, FALSE);
5499 curr_bit_offset += 4;
5501 curr_bit_offset += 1;
5502 if (tvb_get_bits8(tvb,curr_bit_offset,1))
5504 curr_bit_offset += 1;
5505 while (tvb_get_bits8(tvb,curr_bit_offset,1))
5507 curr_bit_offset += 1;
5508 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_arfcn_index, tvb, curr_bit_offset, 6, FALSE);
5509 curr_bit_offset += 6;
5511 curr_bit_offset += 1;
5515 curr_bit_offset += 1;
5516 proto_tree_add_bits_ret_val(subtree, hf_gsm_a_rr_ma_length, tvb, curr_bit_offset, 6, &ma_length, FALSE);
5517 curr_bit_offset += 6;
5518 value = (gint)ma_length + 1;
5519 item = proto_tree_add_text(subtree,tvb, curr_bit_offset>>3, (value>>3)+1, "MA Bitmap: ");
5522 proto_item_append_text(item,"%d",tvb_get_bits8(tvb,curr_bit_offset,1));
5523 curr_bit_offset += 1;
5527 proto_item_set_len(item,((curr_bit_offset-bit_offset)>>3)+1);
5529 return (curr_bit_offset - bit_offset);
5532 static const value_string gsm_a_rr_nmo_vals[] = {
5533 { 0, "Network Mode of Operation I"},
5534 { 1, "Network Mode of Operation II"},
5535 { 2, "Network Mode of Operation III"},
5540 static const value_string gsm_a_rr_t3168_vals[] = {
5552 static const value_string gsm_a_rr_t3192_vals[] = {
5564 static const value_string gsm_a_rr_drx_timer_max_vals[] = {
5576 static const true_false_string gsm_a_rr_access_burst_type_value = {
5577 "11-bit format shall be used",
5578 "8-bit format shall be used"
5581 static const true_false_string gsm_a_rr_control_ack_type_value = {
5582 "Default format is RLC/MAC control block",
5583 "Default format is four access bursts"
5586 static const value_string gsm_a_rr_pan_max_vals[] = {
5587 { 0, "maximum value allowed for counter N3102 is 4"},
5588 { 1, "maximum value allowed for counter N3102 is 8"},
5589 { 2, "maximum value allowed for counter N3102 is 12"},
5590 { 3, "maximum value allowed for counter N3102 is 16"},
5591 { 4, "maximum value allowed for counter N3102 is 20"},
5592 { 5, "maximum value allowed for counter N3102 is 24"},
5593 { 6, "maximum value allowed for counter N3102 is 28"},
5594 { 7, "maximum value allowed for counter N3102 is 32"},
5598 static const true_false_string gsm_a_rr_egprs_packet_channel_request_value = {
5599 "Use two phase packet access with PACKET CHANNEL REQUEST message for uplink TBF establishment on the PRACH",
5600 "Use EGPRS PACKET CHANNEL REQUEST message for uplink TBF establishment on the PRACH"
5603 static const value_string gsm_a_rr_bep_period_vals[] = {
5623 static const true_false_string gsm_a_rr_pfc_feature_mode_value = {
5624 "The network supports packet flow context procedures",
5625 "The network does not support packet flow context procedures"
5628 static const true_false_string gsm_a_rr_dtm_support_value = {
5629 "The cell supports DTM procedures",
5630 "The cell does not support DTM procedures"
5633 static const true_false_string gsm_a_rr_bss_paging_coordination_value = {
5634 "The cell supports Circuit-Switched paging coordination",
5635 "The cell does not support Circuit-Switched paging coordination"
5638 static const true_false_string gsm_a_rr_ccn_active_value = {
5639 "CCN is enabled in the cell",
5640 "CCN is disabled in the cell"
5643 static const true_false_string gsm_a_rr_nw_ext_utbf_value = {
5644 "The extended uplink TBF mode is supported by the network",
5645 "The extended uplink TBF mode is not supported by the network"
5648 static const true_false_string gsm_a_rr_multiple_tbf_capability_value = {
5649 "The cell supports multiple TBF procedures",
5650 "The cell does not support multiple TBF procedures"
5653 static const true_false_string gsm_a_rr_ext_utbf_no_data_value = {
5654 "The mobile station may refrain from sending a PACKET UPLINK DUMMY CONTROL BLOCK message when there is no other RLC/MAC block ready to send in an uplink radio block allocated by the network",
5655 "The mobile station shall send a PACKET UPLINK DUMMY CONTROL BLOCK message when there is no other RLC/MAC block ready to send in an uplink radio block allocated by the network"
5658 static const true_false_string gsm_a_rr_dtm_enhancements_capability_value = {
5659 "The cell supports enhanced DTM CS establishment and enhanced DTM CS release procedures",
5660 "The cell does not support enhanced DTM CS establishment and enhanced DTM CS release procedures"
5663 static const true_false_string gsm_a_rr_reduced_latency_access_value = {
5664 "The cell supports \"One Phase Access Request by Reduced Latency MS\"",
5665 "The cell does not support \"One Phase Access Request by Reduced Latency MS\""
5668 static const value_string gsm_a_rr_alpha_vals[] = {
5688 static const value_string gsm_a_rr_t_avg_x_vals[] = {
5689 { 0, "2^(0/2) / 6 multiframes"},
5690 { 1, "2^(1/2) / 6 multiframes"},
5691 { 2, "2^(2/2) / 6 multiframes"},
5692 { 3, "2^(3/2) / 6 multiframes"},
5693 { 4, "2^(4/2) / 6 multiframes"},
5694 { 5, "2^(5/2) / 6 multiframes"},
5695 { 6, "2^(6/2) / 6 multiframes"},
5696 { 7, "2^(7/2) / 6 multiframes"},
5697 { 8, "2^(8/2) / 6 multiframes"},
5698 { 9, "2^(9/2) / 6 multiframes"},
5699 { 10, "2^(10/2) / 6 multiframes"},
5700 { 11, "2^(11/2) / 6 multiframes"},
5701 { 12, "2^(12/2) / 6 multiframes"},
5702 { 13, "2^(13/2) / 6 multiframes"},
5703 { 14, "2^(14/2) / 6 multiframes"},
5704 { 15, "2^(15/2) / 6 multiframes"},
5705 { 16, "2^(16/2) / 6 multiframes"},
5706 { 17, "2^(17/2) / 6 multiframes"},
5707 { 18, "2^(18/2) / 6 multiframes"},
5708 { 19, "2^(19/2) / 6 multiframes"},
5709 { 20, "2^(20/2) / 6 multiframes"},
5710 { 21, "2^(21/2) / 6 multiframes"},
5711 { 22, "2^(22/2) / 6 multiframes"},
5712 { 23, "2^(23/2) / 6 multiframes"},
5713 { 24, "2^(24/2) / 6 multiframes"},
5714 { 25, "2^(25/2) / 6 multiframes"},
5715 { 26, "2^(25/2) / 6 multiframes"},
5716 { 27, "2^(25/2) / 6 multiframes"},
5717 { 28, "2^(25/2) / 6 multiframes"},
5718 { 29, "2^(25/2) / 6 multiframes"},
5719 { 30, "2^(25/2) / 6 multiframes"},
5720 { 31, "2^(25/2) / 6 multiframes"},
5724 static const true_false_string gsm_a_rr_pc_meas_chan_value = {
5725 "Downlink measurements for power control shall be made on PDCH",
5726 "Downlink measurements for power control shall be made on BCCH"
5729 static const value_string gsm_a_rr_n_avg_i_vals[] = {
5749 static const true_false_string gsm_a_rr_sgsnr_value = {
5750 "SGSN is Release '99 onwards",
5751 "SGSN is Release '98 or older"
5754 static const true_false_string gsm_a_rr_si_status_ind_value = {
5755 "The network supports the PACKET SI STATUS message",
5756 "The network does not support the PACKET SI STATUS message"
5759 static const value_string gsm_a_rr_lb_ms_txpwr_max_cch_vals[] = {
5795 static const value_string gsm_a_rr_si2n_support_vals[] = {
5796 { 0, "SI2n is not supported"},
5797 { 1, "SI2n is supported on PACCH"},
5798 { 2, "SI2n is supported on PACCH and broadcast on BCCH"},
5799 { 3, "SI2n is supported on PACCH and broadcast on BCCH Ext"},
5804 de_rr_si13_rest_oct(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
5806 proto_tree *subtree, *subtree2;
5807 proto_item *item, *item2;
5808 guint32 curr_offset;
5809 gint bit_offset, bit_offset_sav;
5813 curr_offset = offset;
5814 bit_offset = curr_offset << 3;
5816 item = proto_tree_add_text(tree, tvb, curr_offset, len, "%s",
5817 gsm_rr_elem_strings[DE_RR_SI13_REST_OCT].strptr);
5819 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_SI13_REST_OCT]);
5821 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5824 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bcch_change_mark, tvb, bit_offset, 3, FALSE);
5826 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si_change_field, tvb, bit_offset, 4, FALSE);
5828 value = tvb_get_bits8(tvb,bit_offset,1);
5832 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si13_change_mark, tvb, bit_offset, 2, FALSE);
5834 bit_offset += de_rr_rest_oct_gprs_mobile_allocation(tvb, subtree, bit_offset);
5836 value = tvb_get_bits8(tvb,bit_offset,1);
5839 { /* PBCCH present in the cell */
5840 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_psi1_repeat_period, tvb, bit_offset, 4, FALSE);
5842 bit_offset_sav = bit_offset;
5843 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_PBCCH_DESC].strptr);
5844 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_PBCCH_DESC]);
5845 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_pbcch_pb, tvb, bit_offset, 4, FALSE);
5847 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_pbcch_tsc, tvb, bit_offset, 3, FALSE);
5849 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_pbcch_tn, tvb, bit_offset, 3, FALSE);
5851 value = tvb_get_bits8(tvb,bit_offset,1);
5855 proto_tree_add_text(subtree2, tvb, bit_offset>>3, 1, "MAIO: %d", tvb_get_bits8(tvb,bit_offset,6));
5860 value = tvb_get_bits8(tvb,bit_offset,1);
5864 proto_tree_add_bits_item(subtree2, hf_gsm_a_rr_arfcn, tvb, bit_offset, 10, FALSE);
5868 proto_tree_add_text(subtree2, tvb, bit_offset>>3, 1, "PBCCH shall use the BCCH carrier");
5870 proto_item_set_len(item2,((bit_offset-bit_offset_sav)>>3)+1);
5873 { /* PBCCH not present in the cell */
5874 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rac, tvb, bit_offset, 8, FALSE);
5876 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_spgc_ccch_sup, tvb, bit_offset, 1, FALSE);
5878 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_priority_access_thr, tvb, bit_offset, 3, FALSE);
5880 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_network_control_order, tvb, bit_offset, 2, FALSE);
5882 bit_offset += de_rr_rest_oct_gprs_cell_options(tvb, subtree, bit_offset);
5883 bit_offset += de_rr_rest_oct_gprs_power_control_parameters(tvb, subtree, bit_offset);
5885 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5886 { /* Additions in release 99 */
5888 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_sgsnr, tvb, bit_offset, 1, FALSE);
5890 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5891 { /* Additions in release Rel-4 */
5893 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si_status_ind, tvb, bit_offset, 1, FALSE);
5895 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
5896 { /* Additions in release Rel-6 */
5898 value = tvb_get_bits8(tvb,bit_offset,1);
5902 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_lb_ms_txpwr_max_cch, tvb, bit_offset, 5, FALSE);
5905 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_si2n_support, tvb, bit_offset, 2, FALSE);
5920 proto_tree_add_text(subtree,tvb, curr_offset, len ,"Empty");
5923 curr_offset = curr_offset + len;
5925 return curr_offset-offset;
5928 /* [3] 10.5.2.37c (void)
5929 * [3] 10.5.2.37d (void)
5930 * [3] 10.5.2.37e SI 16 Rest Octets
5931 * [3] 10.5.2.37f SI 17 Rest Octets
5932 * [3] 10.5.2.37g SI 19 Rest Octets
5933 * [3] 10.5.2.37h SI 18 Rest Octets
5934 * [3] 10.5.2.37i SI 20 Rest Octets
5937 * [3] 10.5.2.38 Starting Time
5940 de_rr_starting_time(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
5943 guint32 curr_offset;
5946 curr_offset = offset;
5948 fn = tvb_get_ntohs(tvb,curr_offset);
5949 rfn = reduced_frame_number(fn);
5950 proto_tree_add_item(tree, hf_gsm_a_rr_T1prim, tvb, curr_offset, 1, FALSE);
5951 proto_tree_add_item(tree, hf_gsm_a_rr_T3, tvb, curr_offset, 2, FALSE);
5953 proto_tree_add_item(tree, hf_gsm_a_rr_T2, tvb, curr_offset, 1, FALSE);
5955 item = proto_tree_add_uint(tree, hf_gsm_a_rr_rfn, tvb, curr_offset-2, 2, rfn);
5956 PROTO_ITEM_SET_GENERATED(item);
5957 return(curr_offset - offset);
5960 * [3] 10.5.2.39 Synchronization Indication
5963 * ROT: Report Observed Time Difference (Octet1 bit 3) */
5965 static const true_false_string sm_a_rr_sync_ind_rot_value = {
5966 "Mobile Time Difference IE shall be included in the HANDOVER COMPLETE message",
5967 "Mobile Time Difference IE shall not be included in the HANDOVER COMPLETE message"
5970 /* SI: Synchronization indication (octet 1)Bit2 1 */
5972 static const value_string gsm_a_rr_sync_ind_si_vals[] = {
5973 { 0, "Non-synchronized"},
5974 { 1, "Synchronized"},
5975 { 2, "Pre-synchronised"},
5976 { 3, "Pseudo-synchronised"},
5979 /* NCI: Normal cell indication (octet 1, bit 4) */
5981 static const true_false_string gsm_a_rr_sync_ind_nci_value = {
5982 "Out of range timing advance shall trigger a handover failure procedure",
5983 "Out of range timing advance is ignored"
5986 de_rr_sync_ind(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
5988 guint32 curr_offset;
5990 curr_offset = offset;
5993 proto_tree_add_item(tree, hf_gsm_a_rr_sync_ind_nci, tvb, curr_offset, 1, FALSE);
5995 proto_tree_add_item(tree, hf_gsm_a_rr_sync_ind_rot, tvb, curr_offset, 1, FALSE);
5997 proto_tree_add_item(tree, hf_gsm_a_rr_sync_ind_si, tvb, curr_offset, 1, FALSE);
5999 curr_offset = curr_offset + 1;
6001 return(curr_offset - offset);
6005 * [3] 10.5.2.40 Timing Advance
6008 de_rr_timing_adv(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6010 guint32 curr_offset;
6012 curr_offset = offset;
6014 proto_tree_add_item(tree, hf_gsm_a_rr_timing_adv, tvb, curr_offset, 1, FALSE);
6015 curr_offset = curr_offset + 1;
6017 return(curr_offset - offset);
6021 * [3] 10.5.2.41 Time Difference
6024 de_rr_time_diff(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6026 guint32 curr_offset;
6028 curr_offset = offset;
6030 proto_tree_add_item(tree, hf_gsm_a_rr_time_diff, tvb, curr_offset, 1, FALSE);
6031 curr_offset = curr_offset + 1;
6033 return(curr_offset - offset);
6036 * [3] 10.5.2.41a TLLI
6037 * The TLLI is encoded as a binary number with a length of 4 octets. TLLI is defined in 3GPP TS 23.003
6040 de_rr_tlli(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6042 guint32 curr_offset;
6044 curr_offset = offset;
6046 proto_tree_add_item(tree, hf_gsm_a_rr_tlli, tvb, curr_offset, 4, FALSE);
6047 curr_offset = curr_offset + 4;
6049 return(curr_offset - offset);
6053 * [3] 10.5.2.42 TMSI/P-TMSI
6056 de_rr_tmsi_ptmsi(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6058 proto_tree *subtree;
6060 guint32 curr_offset;
6062 curr_offset = offset;
6064 item = proto_tree_add_text(tree, tvb, curr_offset, 3, "%s",
6065 gsm_rr_elem_strings[DE_RR_TMSI_PTMSI].strptr);
6067 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_TMSI_PTMSI]);
6069 proto_tree_add_item(subtree, hf_gsm_a_rr_tmsi_ptmsi, tvb, curr_offset, 4, FALSE);
6070 curr_offset = curr_offset + 4;
6072 return(curr_offset - offset);
6076 * [3] 10.5.2.42a VGCS target mode Indication
6079 Target mode (octet 3)
6082 0 1 group transmit mode
6083 Other values are reserved for future use.
6085 static const value_string gsm_a_rr_target_mode_vals[] _U_ = {
6086 { 0, "Dedicated mode"},
6087 { 1, "Group transmit mode"},
6091 de_rr_vgcs_tar_mode_ind(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6093 guint32 curr_offset;
6095 curr_offset = offset;
6097 proto_tree_add_item(tree, hf_gsm_a_rr_target_mode, tvb, curr_offset, 1, FALSE);
6098 proto_tree_add_item(tree, hf_gsm_a_rr_group_cipher_key_number, tvb, curr_offset, 1, FALSE);
6099 curr_offset = curr_offset + 1;
6101 return(curr_offset - offset);
6105 * [3] 10.5.2.42b VGCS Ciphering Parameters
6108 de_rr_vgcs_cip_par(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6110 guint32 curr_offset;
6112 curr_offset = offset;
6114 proto_tree_add_text(tree,tvb, curr_offset, len ,"Data(Not decoded)");
6116 curr_offset = curr_offset + 2;
6118 return(curr_offset - offset);
6121 * [3] 10.5.2.43 Wait Indication
6124 de_rr_wait_ind(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6126 guint32 curr_offset;
6128 curr_offset = offset;
6130 proto_tree_add_item(tree, hf_gsm_a_rr_wait_indication, tvb, curr_offset, 1, FALSE);
6132 curr_offset = curr_offset + 1;
6134 return(curr_offset - offset);
6138 * [3] 10.5.2.44 SI10 rest octets $(ASCI)$
6142 * [3] 10.5.2.45 Extended Measurement Results
6145 de_rr_ext_meas_result(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
6147 guint32 curr_offset;
6151 curr_offset = offset;
6153 bit_offset = curr_offset << 3;
6155 proto_tree_add_bits_item(tree, hf_gsm_a_rr_seq_code, tvb,bit_offset, 1, FALSE);
6157 proto_tree_add_bits_item(tree, hf_gsm_a_rr_dtx_used, tvb, bit_offset, 1, FALSE);
6159 for (i=0; i<21; i++)
6161 value = tvb_get_bits8(tvb,bit_offset,6);
6162 proto_tree_add_text(tree, tvb, bit_offset>>3, 1, "RXLEV carrier %d: %s (%d)",i,gsm_a_rr_rxlev_vals[value].strptr,value);
6166 curr_offset = offset + len;
6168 return(curr_offset - offset);
6172 * [3] 10.5.2.46 Extended Measurement Frequency List
6175 de_rr_ext_meas_freq_list(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6177 guint32 curr_offset;
6179 curr_offset = offset;
6181 proto_tree_add_bits_item(tree, hf_gsm_a_rr_seq_code, tvb,(curr_offset<<3)+3, 1, FALSE);
6183 return dissect_arfcn_list(tvb, tree, offset, 16, add_string, string_len);
6187 * [3] 10.5.2.47 Suspension Cause
6189 /*Suspension cause value (octet 2)*/
6190 static const value_string gsm_a_rr_suspension_cause_vals[] = {
6191 { 0, "Emergency call, mobile originating call or call re-establishment"},
6192 { 1, "Location Area Update"},
6193 { 2, "MO Short message service"},
6194 { 3, "Other procedure which can be completed with an SDCCH"},
6195 { 4, "MO Voice broadcast or group call"},
6196 { 5, "Mobile terminating CS connection"},
6197 { 6, "DTM not supported in the cell"},
6201 de_rr_sus_cau(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6203 guint32 curr_offset;
6205 curr_offset = offset;
6207 proto_tree_add_item(tree, hf_gsm_a_rr_suspension_cause, tvb, curr_offset, 1, FALSE);
6209 curr_offset = curr_offset + 1;
6211 return(curr_offset - offset);
6214 * [3] 10.5.2.48 APDU ID
6215 * [3] 10.5.2.49 APDU Flags
6216 * [3] 10.5.2.50 APDU Data
6220 * [3] 10.5.2.51 Handover To UTRAN Command
6223 de_rr_ho_to_utran_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
6225 guint32 curr_offset;
6226 tvbuff_t *rrc_irat_ho_to_utran_cmd_tvb;
6227 static packet_info p_info;
6229 curr_offset = offset;
6232 rrc_irat_ho_to_utran_cmd_tvb = tvb_new_subset(tvb, curr_offset, len, len);
6233 if (rrc_irat_ho_to_utran_cmd_handle)
6234 call_dissector(rrc_irat_ho_to_utran_cmd_handle, rrc_irat_ho_to_utran_cmd_tvb, &p_info, tree);
6238 return(curr_offset - offset);
6243 * [3] 10.5.2.52 Handover To cdma2000 Command
6244 * [3] 10.5.2.53 (void)
6245 * [3] 10.5.2.54 (void)
6246 * [3] 10.5.2.55 (void)
6247 * [3] 10.5.2.56 3G Target Cell
6250 * 10.5.2.57 Service Support
6252 static const true_false_string gsm_a_rr_MBMS_multicast_value = {
6253 "mobile station requires notification of multicast MBMS services",
6254 "mobile station does not require notification of multicast MBMS services"
6256 static const true_false_string gsm_a_rr_MBMS_broadcast_value = {
6257 "mobile station requires notification of broadcast MBMS services",
6258 "mobile station does not require notification of broadcast MBMS services"
6261 de_rr_serv_sup(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6263 guint32 curr_offset;
6265 curr_offset = offset;
6267 * 0 mobile station does not require notification of broadcast MBMS services
6268 * 1 mobile station requires notification of broadcast MBMS services
6270 * 0 mobile station does not require notification of multicast MBMS services
6271 * 1 mobile station requires notification of multicast MBMS services
6273 /* MBMS Multicast */
6274 proto_tree_add_item(tree, hf_gsm_a_rr_MBMS_multicast, tvb, curr_offset, 1, FALSE);
6276 /* MBMS Broadcast */
6277 proto_tree_add_item(tree, hf_gsm_a_rr_MBMS_broadcast, tvb, curr_offset, 1, FALSE);
6280 return(curr_offset - offset);
6284 * [3] 10.5.2.59 Dedicated Service Information
6287 Last Segment (octet 2)
6289 0 mobile station shall not perform Service Information Sending procedure on new cell.
6290 1 mobile station shall perform Service Information Sending procedure on new cell.
6292 static const true_false_string gsm_a_rr_last_segment_value = {
6293 "Mobile station shall perform Service Information Sending procedure on new cell.",
6294 "mobile station shall not perform Service Information Sending procedure on new cell."
6297 de_rr_ded_serv_inf(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6299 guint32 curr_offset;
6301 curr_offset = offset;
6303 proto_tree_add_item(tree, hf_gsm_a_rr_last_segment, tvb, curr_offset, 1, FALSE);
6305 curr_offset = curr_offset + 3;
6307 return(curr_offset - offset);
6311 * [3] 10.5.2.69 Carrier Indication
6313 static const true_false_string gsm_a_rr_carrier_ind_value = {
6319 de_rr_carrier_ind(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
6321 proto_tree *subtree;
6323 guint32 curr_offset;
6325 curr_offset = offset;
6327 item = proto_tree_add_text(tree, tvb, curr_offset, 3, "%s",
6328 gsm_rr_elem_strings[DE_RR_CARRIER_IND].strptr);
6330 subtree = proto_item_add_subtree(item, ett_gsm_rr_elem[DE_RR_CARRIER_IND]);
6332 proto_tree_add_item(tree, hf_gsm_a_rr_carrier_ind, tvb, curr_offset, 1, FALSE);
6336 return(curr_offset - offset);
6339 guint8 (*rr_elem_fcn[])(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len, gchar *add_string, int string_len) = {
6340 /* Radio Resource Management Information Elements 10.5.2, most are from 10.5.1 */
6342 de_rr_ba_range, /* [3] 10.5.2.1a BA Range */
6343 de_rr_cell_ch_dsc, /* [3] 10.5.2.1b Cell Channel Description */
6344 de_rr_ba_list_pref, /* [3] 10.5.2.1c BA List Pref */
6345 de_rr_utran_freq_list, /* [3] 10.5.2.1d UTRAN Frequency List */
6346 de_rr_cell_select_indic, /* [3] 10.5.2.1e Cell selection indicator after release of all TCH and SDCCH IE */
6347 de_rr_cell_dsc, /* 10.5.2.2 RR Cell Description */
6348 de_rr_cell_opt_bcch, /* [3] 10.5.2.3 Cell Options (BCCH) */
6349 de_rr_cell_opt_sacch, /* [3] 10.5.2.3a Cell Options (SACCH) */
6350 de_rr_cell_sel_param, /* [3] 10.5.2.4 Cell Selection Parameters */
6352 * [3] 10.5.2.4a (void)
6354 de_rr_ch_dsc, /* [3] 10.5.2.5 Channel Description */
6355 de_rr_ch_dsc2, /* [3] 10.5.2.5a RR Channel Description 2 */
6356 de_rr_ch_dsc3, /* [3] 10.5.2.5c RR Channel Description 3 */
6357 de_rr_ch_mode, /* [3] 10.5.2.6 Channel Mode */
6358 de_rr_ch_mode2, /* [3] 10.5.2.7 Channel Mode 2 */
6359 de_rr_utran_cm, /* [3] 10.5.2.7a UTRAN Classmark */
6360 /* [3] 10.5.2.7b (void) */
6362 de_rr_cm_enq_mask, /* [3] 10.5.2.7c Classmark Enquiry Mask */
6363 /* [3] 10.5.2.7d GERAN Iu Mode Classmark information element */
6364 de_rr_chnl_needed, /* [3] 10.5.2.8 Channel Needed
6365 * [3] 10.5.2.8a (void)
6366 * [3] 10.5.2.8b Channel Request Description 2 */
6368 de_rr_cip_mode_set, /* [3] 10.5.2.9 Cipher Mode Setting */
6369 de_rr_cip_mode_resp, /* [3] 10.5.2.10 Cipher Response */
6370 de_rr_ctrl_ch_desc, /* [3] 10.5.2.11 Control Channel Description */
6371 /* [3] 10.5.2.11a DTM Information Details */
6372 de_rr_dyn_arfcn_map, /* [3] 10.5.2.11b Dynamic ARFCN Mapping */
6373 de_rr_freq_ch_seq, /* [3] 10.5.2.12 Frequency Channel Sequence */
6374 de_rr_freq_list, /* [3] 10.5.2.13 Frequency List */
6375 de_rr_freq_short_list, /* [3] 10.5.2.14 Frequency Short List */
6376 de_rr_freq_short_list2, /* [3] 10.5.2.14a Frequency Short List 2 */
6377 /* [3] 10.5.2.14b Group Channel Description */
6378 de_rr_gprs_resumption, /* [3] 10.5.2.14c GPRS Resumption */
6379 de_rr_gprs_broadcast_info, /* [3] 10.5.2.14d GPRS broadcast information */
6380 /* [3] 10.5.2.14e Enhanced DTM CS Release Indication */
6381 de_rr_ho_ref, /* 10.5.2.15 Handover Reference */
6382 de_rr_ia_rest_oct, /* [3] 10.5.2.16 IA Rest Octets */
6383 de_rr_iar_rest_oct, /* [3] 10.5.2.17 IAR Rest Octets */
6384 de_rr_iax_rest_oct, /* [3] 10.5.2.18 IAX Rest Octets */
6385 de_rr_l2_pseudo_len, /*[3] 10.5.2.19 L2 Pseudo Length */
6386 de_rr_meas_res, /* [3] 10.5.2.20 Measurement Results */
6390 de_rr_mob_all, /* [3] 10.5.2.21 Mobile Allocation */
6391 de_rr_mob_time_diff, /* [3] 10.5.2.21a Mobile Time Difference */
6392 de_rr_multirate_conf, /* [3] 10.5.2.21aa MultiRate configuration */
6394 de_rr_mult_all, /* [3] 10.5.2.21b Multislot Allocation */
6396 * [3] 10.5.2.21c (void)
6398 de_rr_neigh_cell_desc, /* [3] 10.5.2.22 Neighbour Cell Description */
6399 de_rr_neigh_cell_desc2, /* [3] 10.5.2.22a Neighbour Cell Description 2 */
6401 * [3] 10.5.2.22b (void)
6402 * [3] 10.5.2.22c NT/N Rest Octets */
6403 de_rr_p1_rest_oct, /* [3] 10.5.2.23 P1 Rest Octets */
6404 de_rr_p2_rest_oct, /* [3] 10.5.2.24 P2 Rest Octets */
6405 de_rr_p3_rest_oct, /* [3] 10.5.2.25 P3 Rest Octets */
6406 de_rr_packet_ch_desc, /* [3] 10.5.2.25a Packet Channel Description */
6407 de_rr_ded_mod_or_tbf, /* [3] 10.5.2.25b Dedicated mode or TBF */
6408 /* [3] 10.5.2.25c RR Packet Uplink Assignment
6409 * [3] 10.5.2.25d RR Packet Downlink Assignment
6411 de_rr_page_mode, /* [3] 10.5.2.26 Page Mode */
6413 * [3] 10.5.2.26a (void)
6414 * [3] 10.5.2.26b (void)
6415 * [3] 10.5.2.26c (void)
6416 * [3] 10.5.2.26d (void)
6418 de_rr_ncc_perm, /* [3] 10.5.2.27 NCC Permitted */
6419 de_rr_pow_cmd, /* 10.5.2.28 Power Command */
6420 de_rr_pow_cmd_and_acc_type, /* 10.5.2.28a Power Command and access type */
6421 de_rr_rach_ctrl_param, /* [3] 10.5.2.29 RACH Control Parameters */
6422 de_rr_req_ref, /* [3] 10.5.2.30 Request Reference */
6423 de_rr_cause, /* 10.5.2.31 RR Cause */
6424 de_rr_sync_ind, /* 10.5.2.39 Synchronization Indication */
6425 de_rr_si1_rest_oct, /* [3] 10.5.2.32 SI1 Rest Octets */
6426 /* [3] 10.5.2.33 SI 2bis Rest Octets */
6427 de_rr_si2ter_rest_oct, /* [3] 10.5.2.33a SI 2ter Rest Octets */
6428 de_rr_si2quater_rest_oct, /* [3] 10.5.2.33b SI 2quater Rest Octets */
6429 de_rr_si3_rest_oct, /* [3] 10.5.2.34 SI3 Rest Octets */
6430 de_rr_si4_rest_oct, /* [3] 10.5.2.35 SI4 Rest Octets */
6431 de_rr_si6_rest_oct, /* [3] 10.5.2.35b SI6 Rest Octets */
6432 /* [3] 10.5.2.36 SI 7 Rest Octets
6433 * [3] 10.5.2.37 SI 8 Rest Octets
6434 * [3] 10.5.2.37a SI 9 Rest Octets
6436 de_rr_si13_rest_oct, /* [3] 10.5.2.37a SI13 Rest Octets */
6437 /* [3] 10.5.2.37c (void)
6438 * [3] 10.5.2.37d (void)
6439 * [3] 10.5.2.37e SI 16 Rest Octets
6440 * [3] 10.5.2.37f SI 17 Rest Octets
6441 * [3] 10.5.2.37g SI 19 Rest Octets
6442 * [3] 10.5.2.37h SI 18 Rest Octets
6443 * [3] 10.5.2.37i SI 20 Rest Octets */
6444 de_rr_starting_time, /* [3] 10.5.2.38 Starting Time */
6445 de_rr_timing_adv, /* [3] 10.5.2.40 Timing Advance */
6446 de_rr_time_diff, /* [3] 10.5.2.41 Time Difference */
6447 de_rr_tlli, /* [3] 10.5.2.41a TLLI */
6448 de_rr_tmsi_ptmsi, /* [3] 10.5.2.42 TMSI/P-TMSI */
6449 de_rr_vgcs_tar_mode_ind, /* [3] 10.5.2.42a VGCS target mode Indication */
6451 de_rr_vgcs_cip_par, /* [3] 10.5.2.42b VGCS Ciphering Parameters */
6452 de_rr_wait_ind, /* [3] 10.5.2.43 Wait Indication */
6453 /* [3] 10.5.2.44 SI10 rest octets $(ASCI)$ */
6454 de_rr_ext_meas_result, /* [3] 10.5.2.45 Extended Measurement Results */
6455 de_rr_ext_meas_freq_list, /* [3] 10.5.2.46 Extended Measurement Frequency List */
6456 de_rr_sus_cau, /* [3] 10.5.2.47 Suspension Cause */
6457 /* [3] 10.5.2.48 APDU ID
6458 * [3] 10.5.2.49 APDU Flags
6459 * [3] 10.5.2.50 APDU Data */
6460 de_rr_ho_to_utran_cmd, /* [3] 10.5.2.51 Handover To UTRAN Command */
6461 /* [3] 10.5.2.52 Handover To cdma2000 Command
6462 * [3] 10.5.2.53 (void)
6463 * [3] 10.5.2.54 (void)
6464 * [3] 10.5.2.55 (void)
6465 * [3] 10.5.2.56 3G Target Cell
6466 * 10.5.2.57 Service Support */
6467 de_rr_serv_sup, /* 10.5.2.57 Service Support */
6469 * 10.5.2.58 MBMS p-t-m Channel Description
6471 de_rr_ded_serv_inf, /* [3] 10.5.2.59 Dedicated Service Information */
6473 * 10.5.2.60 MPRACH Description
6474 * 10.5.2.61 Restriction Timer
6475 * 10.5.2.62 MBMS Session Identity
6476 * 10.5.2.63 Reduced group or broadcast call reference
6477 * 10.5.2.64 Talker Priority status
6478 * 10.5.2.65 Talker Identity
6480 * 10.5.2.67 PS Cause
6481 * 10.5.2.68 VGCS AMR Configuration
6483 de_rr_carrier_ind, /* 10.5.2.69 Carrier Indication */
6487 /* MESSAGE FUNCTIONS */
6490 * 9.1.1 Additional Assignment
6493 dtap_rr_add_ass(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6495 guint32 curr_offset;
6499 curr_offset = offset;
6502 /* Channel Description 10.5.2.5 M V 3 */
6503 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
6505 /* Mobile Allocation 10.5.2.21 C TLV 3-10 */
6506 ELEM_OPT_TLV(0x72, GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, "");
6508 /* Starting Time 10.5.2.38 O TV 3 */
6509 ELEM_OPT_TV(0x7c, GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
6511 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6515 * 9.1.2 Assignment command
6518 dtap_rr_ass_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6520 guint32 curr_offset;
6524 curr_offset = offset;
6527 /* Channel Description 2 10.5.2.5a M V 3 */
6528 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2);
6530 /* Power Command 10.5.2.28 M V 1 */
6531 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_POW_CMD);
6533 /* 05 Frequency List 10.5.2.13 C TLV 4-132 */
6534 ELEM_OPT_TLV(0x05, GSM_A_PDU_TYPE_RR, DE_RR_FREQ_LIST, " - Frequency List, after time");
6536 /* 62 Cell Channel Description 10.5.2.1b O TV 17 */
6537 ELEM_OPT_TV(0x62, GSM_A_PDU_TYPE_RR, DE_RR_CELL_CH_DSC, "");
6539 /* 10 Multislot Allocation 10.5.2.21b C TLV 3-12 */
6540 ELEM_OPT_TLV(0x10,GSM_A_PDU_TYPE_RR, DE_RR_MULT_ALL, " - Description of the multislot configuration");
6542 /* 63 Channel Mode 10.5.2.6 O TV 2 */
6543 ELEM_OPT_TV(0x63,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of the First Channel(Channel Set 1)");
6545 /* 11 Channel Mode 10.5.2.6 O TV 2 */
6546 ELEM_OPT_TV(0x11,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 2");
6548 /* 13 Channel Mode 10.5.2.6 O TV 2 */
6549 ELEM_OPT_TV(0x13,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 3");
6551 /* 14 Channel Mode 10.5.2.6 O TV 2 */
6552 ELEM_OPT_TV(0x14,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 4");
6554 /* 15 Channel Mode 10.5.2.6 O TV 2 */
6555 ELEM_OPT_TV(0x15,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 5");
6557 /* 16 Channel Mode 10.5.2.6 O TV 2 */
6558 ELEM_OPT_TV(0x16,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 6");
6560 /* 17 Channel Mode 10.5.2.6 O TV 2 */
6561 ELEM_OPT_TV(0x17,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 7");
6563 /* 18 Channel Mode 10.5.2.6 O TV 2 */
6564 ELEM_OPT_TV(0x18,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 8");
6566 /* 64 Channel Description 10.5.2.5 O TV 4 */
6567 ELEM_OPT_TV(0x64,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC, "Description of the Second Channel, after time");
6569 /* 66 Channel Mode 2 10.5.2.7 O TV 2 */
6570 ELEM_OPT_TV(0x66,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE2, " - Mode of the Second Channel");
6572 /* 72 Mobile Allocation 10.5.2.21 C TLV 3-10 */
6573 ELEM_OPT_TLV(0x72,GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, " - Mobile Allocation, after time");
6575 /* 7C Starting Time 10.5.2.38 O TV 3 */
6576 ELEM_OPT_TV(0x7C,GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
6578 /* 19 Frequency List 10.5.2.13 C TLV 4-132 */
6579 ELEM_OPT_TLV(0x19, GSM_A_PDU_TYPE_RR, DE_RR_FREQ_LIST, " - Frequency List, before time");
6581 /* 1C Channel Description 2 10.5.2.5a O TV 4 */
6582 ELEM_OPT_TV(0x1c,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2, " - Description of the First Channel, before time");
6584 /* 1D Channel Description 10.5.2.5 O TV 4 */
6585 ELEM_OPT_TV(0x1d,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC, " - Description of the Second Channel, before time");
6587 /* 1E Frequency channel sequence 10.5.2.12 C TV 10 */
6588 ELEM_OPT_TV(0x1e,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_CH_SEQ, " - Frequency channel sequence before time");
6590 /* 21 Mobile Allocation 10.5.2.21 C TLV 3-10 */
6591 ELEM_OPT_TLV(0x21,GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, " - Mobile Allocation, before time");
6593 /* 9- Cipher Mode Setting 10.5.2.9 O TV 1 */
6594 ELEM_OPT_TV_SHORT(0x90,GSM_A_PDU_TYPE_RR, DE_RR_CIP_MODE_SET, "");
6595 /* 01 VGCS target mode Indication VGCS target mode Indication 10.5.2.42a O TLV 3 */
6596 ELEM_OPT_TLV(0x01,GSM_A_PDU_TYPE_RR, DE_RR_VGCS_TAR_MODE_IND, "");
6598 /* 03 Multi-Rate configuration, MultiRate configuration 10.5.2.21aa O TLV 4-8 */
6599 ELEM_OPT_TLV(0x03,GSM_A_PDU_TYPE_RR, DE_RR_MULTIRATE_CONF, "");
6601 /* 04 VGCS Ciphering Parameters VGCS Ciphering Parameters 10.5.2.42b O TLV 3-15 */
6602 ELEM_OPT_TLV(0x04,GSM_A_PDU_TYPE_RR, DE_RR_VGCS_CIP_PAR, "");
6604 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6609 * 9.1.3 Assignment complete
6612 dtap_rr_ass_comp(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6614 guint32 curr_offset;
6618 curr_offset = offset;
6621 /* RR Cause RR Cause 10.5.2.31 M V 1 */
6622 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
6624 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6629 * 9.1.4 Assignment failure
6632 dtap_rr_ass_fail(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6634 guint32 curr_offset;
6638 curr_offset = offset;
6641 /* RR Cause RR Cause 10.5.2.31 M V 1 */
6642 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
6644 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6649 * 9.1.5 Channel Mode Modify
6652 dtap_rr_ch_mode_mod(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6654 guint32 curr_offset;
6658 curr_offset = offset;
6661 /* Channel Description 2 10.5.2.5a M V 3 */
6662 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2);
6664 /* Channel Mode 10.5.2.6 M V 1 */
6665 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE);
6667 /* 01 VGCS target mode Indication VGCS target mode Indication 10.5.2.42a O TLV 3 */
6668 ELEM_OPT_TLV(0x01,GSM_A_PDU_TYPE_RR, DE_RR_VGCS_TAR_MODE_IND, "");
6670 /* 03 Multi-Rate configuration, MultiRate configuration 10.5.2.21aa O TLV 4-8 */
6671 ELEM_OPT_TLV(0x03,GSM_A_PDU_TYPE_RR, DE_RR_MULTIRATE_CONF, "");
6673 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6678 * 9.1.6 Channel Mode Modify Acknowledge
6681 dtap_rr_ch_mode_mod_ack(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6683 guint32 curr_offset;
6687 curr_offset = offset;
6690 /* Channel Description 2 10.5.2.5a M V 3 */
6691 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2);
6693 /* Channel Mode 10.5.2.6 M V 1 */
6694 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE);
6696 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6701 * 9.1.7 Channel Release
6704 dtap_rr_ch_rel(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6706 guint32 curr_offset;
6710 curr_offset = offset;
6713 /* RR Cause RR Cause 10.5.2.31 M V 1 */
6714 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
6716 /* 73 BA Range BA Range 10.5.2.1a O TLV 6-7 */
6717 ELEM_OPT_TLV(0x73, GSM_A_PDU_TYPE_RR, DE_RR_BA_RANGE, "");
6719 /* 74 Group Channel Description Group Channel Description 10.5.2.14b O TLV 5-13 */
6720 /* ELEM_OPT_TLV(0x74, GSM_A_PDU_TYPE_RR, DE_GRP_CH_DESC, ""); */
6722 /* 8x Group Cipher Key Number Group Cipher Key Number 10.5.1.10 C TV 1 */
6723 /* ELEM_OPT_TV_SHORT(0x80, GSM_A_PDU_TYPE_RR, DE_GRP_CIP_KEY_NUM, ""); */
6725 /* Cx GPRS Resumption GPRS Resumption 10.5.2.14c O TV 1 */
6726 ELEM_OPT_TV_SHORT(0xC0, GSM_A_PDU_TYPE_RR, DE_RR_GPRS_RESUMPTION, "");
6728 /* 75 BA List Pref BA List Pref 10.5.2.1c O TLV 3-? */
6729 ELEM_OPT_TLV(0x75, GSM_A_PDU_TYPE_RR, DE_RR_BA_LIST_PREF, "");
6731 /* 76 UTRAN Freq List 10.5.2.1d O TLV 3-? */
6732 ELEM_OPT_TLV(0x76, GSM_A_PDU_TYPE_RR, DE_RR_UTRAN_FREQ_LIST, "");
6734 /* 62 Cell Channel Description Cell Channel Description 10.5.2.1b O TV 17 */
6735 ELEM_OPT_TV(0x62, GSM_A_PDU_TYPE_RR, DE_RR_CELL_CH_DSC, "");
6737 /* 62 Cell selection indicator after release of all TCH and SDCCH 10.5.2.1e O TLV 4-? */
6738 ELEM_OPT_TLV(0x77, GSM_A_PDU_TYPE_RR, DE_RR_CELL_SELECT_INDIC, "");
6740 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6745 * 9.1.8 Channel Request
6747 /* This message is NOT follow the basic format, and is only found on RACH - ignored here */
6750 * 9.1.9 Ciphering Mode Command
6753 dtap_rr_cip_mode_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6755 guint32 curr_offset;
6759 curr_offset = offset;
6761 lower_nibble = FALSE;
6763 /* Ciphering Mode Setting 10.5.2.9 M V 0.5 */
6764 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_CIP_MODE_SET);
6765 /* Cipher Response 10.5.2.10 M V 0.5 */
6766 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_CIP_MODE_RESP);
6768 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6772 * 9.1.10 Ciphering Mode Complete
6775 dtap_rr_cip_mode_cpte(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6777 guint32 curr_offset;
6781 curr_offset = offset;
6783 lower_nibble = FALSE;
6785 /* Mobile Equipment Identity 10.5.1.4 O TLV */
6786 ELEM_OPT_TLV(0x17, GSM_A_PDU_TYPE_COMMON, DE_MID, "Mobile Equipment Identity");
6788 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6793 * 9.1.11 Classmark change
6796 dtap_rr_mm_cm_change(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6798 guint32 curr_offset;
6802 curr_offset = offset;
6805 /* Mobile Station Classmark 2 10.5.1.6 M LV 4 */
6806 ELEM_MAND_LV(GSM_A_PDU_TYPE_COMMON, DE_MS_CM_2, "");
6807 /* 20 Mobile Station Classmark 3 10.5.1.7 C TLV 3-34 */
6808 ELEM_OPT_TLV(0x20, GSM_A_PDU_TYPE_COMMON, DE_MS_CM_3, "");
6810 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6815 * 9.1.11 UTRAN Classmark Change
6818 dtap_rr_utran_classmark_change(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6820 guint32 curr_offset;
6824 curr_offset = offset;
6827 /* UTRAN Classmark 10.5.2.7a M LV 2-? */
6828 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_UTRAN_CM, "");
6830 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6834 * 9.1.12 Classmark enquiry
6837 dtap_rr_cm_enq(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6839 guint32 curr_offset;
6843 curr_offset = offset;
6846 /* 10 Classmark Enquiry Mask 10.5.2.7c O TLV 3 */
6847 ELEM_OPT_TLV(0x10, GSM_A_PDU_TYPE_RR, DE_RR_CM_ENQ_MASK, "");
6849 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6854 * 9.1.12b Configuration change command
6857 dtap_rr_conf_change_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6859 guint32 curr_offset;
6863 curr_offset = offset;
6866 /* Multislot Allocation 10.5.2.21b M LV 2-11 */
6867 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_MULT_ALL, "");
6869 /* Channel Mode 10.5.2.6 O TV 2 */
6870 ELEM_OPT_TV(0x63,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 1");
6872 /* Channel Mode 10.5.2.6 O TV 2 */
6873 ELEM_OPT_TV(0x11,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 2");
6875 /* Channel Mode 10.5.2.6 O TV 2 */
6876 ELEM_OPT_TV(0x13,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 3");
6878 /* Channel Mode 10.5.2.6 O TV 2 */
6879 ELEM_OPT_TV(0x14,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 4");
6881 /* Channel Mode 10.5.2.6 O TV 2 */
6882 ELEM_OPT_TV(0x15,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 5");
6884 /* Channel Mode 10.5.2.6 O TV 2 */
6885 ELEM_OPT_TV(0x16,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 6");
6887 /* Channel Mode 10.5.2.6 O TV 2 */
6888 ELEM_OPT_TV(0x17,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 7");
6890 /* Channel Mode 10.5.2.6 O TV 2 */
6891 ELEM_OPT_TV(0x18,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 8");
6893 EXTRANEOUS_DATA_CHECK(len, curr_offset - offset);
6897 * 9.1.12c Configuration change acknowledge
6902 * 9.1.12d Configuration change reject
6905 dtap_rr_conf_change_rej(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6907 guint32 curr_offset;
6911 curr_offset = offset;
6914 /* RR Cause 10.5.2.31 M V 1 */
6915 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
6917 EXTRANEOUS_DATA_CHECK(curr_len, 0);
6922 * 9.1.13 Frequency Redefinition
6925 dtap_rr_freq_redef(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6927 guint32 curr_offset;
6931 curr_offset = offset;
6934 /* Channel Description 10.5.2.5 M V 3 */
6935 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
6937 /* Mobile Allocation 10.5.2.21 M LV 1-9 */
6938 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, "");
6940 /* Starting Time 10.5.2.38 M V 2 */
6941 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
6943 /* Cell Channel Description 10.5.2.1b O TV 17 */
6944 ELEM_OPT_TV(0x62,GSM_A_PDU_TYPE_RR, DE_RR_CELL_CH_DSC, "");
6946 /* Carrier Indication 10.5.2.69 O TV 1 */
6947 ELEM_OPT_TV_SHORT(0x90,GSM_A_PDU_TYPE_RR, DE_RR_CARRIER_IND,"");
6949 /* Mobile Allocation 10.5.2.21 O TLV 1-9 */
6950 ELEM_OPT_TLV(0x11, GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, " - Mobile Allocation C2");
6952 /* Channel Description 3 10.5.2.5c O TV 3 */
6953 ELEM_OPT_TV(0x12,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC3, " - Channel Description C2");
6955 EXTRANEOUS_DATA_CHECK(len, curr_offset - offset);
6959 * 9.1.13b GPRS suspension request
6962 dtap_rr_gprs_sus_req(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6964 guint32 curr_offset;
6967 curr_offset = offset;
6970 /* TLLI 10.5.2.41a M V 4 */
6971 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TLLI);
6973 /* Routeing Area Identification 10.5.5.15 M V 6 */
6974 ELEM_MAND_V(GSM_A_PDU_TYPE_GM, DE_RAI);
6975 /* Suspension cause 10.5.2.47 M V 1 */
6976 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SUS_CAU);
6978 /* 01 Service Support 10.5.2.57 O TV 2 */
6979 ELEM_OPT_TV_SHORT(0x01,GSM_A_PDU_TYPE_RR, DE_RR_SERV_SUP,"");
6981 EXTRANEOUS_DATA_CHECK(len, curr_offset - offset);
6986 * 9.1.14 Handover Access
6988 /* This message is NOT follow the basic format, and is only found on DCH during initial handover access */
6990 /* 3GPP TS 24.008 version 4.7.0 Release 4
6994 dtap_rr_ho_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
6996 guint32 curr_offset;
6999 curr_offset = offset;
7002 /* Mandatory Elemets
7003 * Cell description 10.5.2.2
7005 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_DSC);
7007 /* Description of the first channel,after time
7008 * Channel Description 2 10.5.2.5a
7010 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2);
7012 /* Handover Reference 10.5.2.15 */
7013 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_HO_REF);
7015 /* Power Command and Access type 10.5.2.28a */
7016 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_POW_CMD_AND_ACC_TYPE);
7018 /* optional elements */
7020 /* Synchronization Indication 10.5.2.39 */
7021 ELEM_OPT_TV_SHORT(0xD0,GSM_A_PDU_TYPE_RR, DE_RR_SYNC_IND,"");
7023 /* Frequency Short List 10.5.2.14 */
7024 ELEM_OPT_TV(0x02,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_SHORT_LIST," - Frequency Short List, after time");
7026 /* Frequency List 10.5.2.13 */
7027 ELEM_OPT_TLV(0x05, GSM_A_PDU_TYPE_RR, DE_RR_FREQ_LIST, " - Frequency List, after time");
7029 /* Cell Channel Description 10.5.2.1b */
7030 ELEM_OPT_TV(0x62,GSM_A_PDU_TYPE_RR, DE_RR_CELL_CH_DSC, "");
7032 /* Multislot Allocation 10.5.2.21b */
7033 ELEM_OPT_TLV(0x10,GSM_A_PDU_TYPE_RR, DE_RR_MULT_ALL, "");
7035 /* Mode of the First Channel(Channel Set 1)) Channel Mode 10.5.2.6*/
7036 ELEM_OPT_TV(0x63,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of the First Channel(Channel Set 1))");
7038 /* Mode of Channel Set 2 Channel Mode 10.5.2.6*/
7039 ELEM_OPT_TV(0x11,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 2");
7041 /* Mode of Channel Set 3 Channel Mode 10.5.2.6*/
7042 ELEM_OPT_TV(0x13,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 3");
7044 /* Mode of Channel Set 4 Channel Mode 10.5.2.6*/
7045 ELEM_OPT_TV(0x14,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 4");
7047 /* Mode of Channel Set 5 Channel Mode 10.5.2.6*/
7048 ELEM_OPT_TV(0x15,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 5");
7050 /* Mode of Channel Set 6 Channel Mode 10.5.2.6*/
7051 ELEM_OPT_TV(0x16,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 6");
7053 /* Mode of Channel Set 7 Channel Mode 10.5.2.6*/
7054 ELEM_OPT_TV(0x17,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 7");
7056 /* Mode of Channel Set 8 Channel Mode 10.5.2.6*/
7057 ELEM_OPT_TV(0x18,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE, " - Mode of Channel Set 8");
7059 /* Description of the Second Channel, after time, Channel Description 10.5.2.5 */
7060 ELEM_OPT_TV(0x64,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC, " - Description of the Second Channel, after time");
7062 /* Mode of the Second Channel, Channel Mode 2 10.5.2.7 */
7063 ELEM_OPT_TV(0x66,GSM_A_PDU_TYPE_RR, DE_RR_CH_MODE2, " - Mode of the Second Channel");
7065 /* Frequency Channel Sequence, after time, Frequency Channel Sequence 10.5.2.12 */
7066 ELEM_OPT_TV(0x69,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_CH_SEQ, " - Frequency Channel Sequence, after time");
7068 /* Mobile Allocation, after time, Mobile Allocation 10.5.2.21 */
7069 ELEM_OPT_TLV(0x72,GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, " - Mobile Allocation, after time");
7071 /* Starting Time 10.5.2.38 */
7072 ELEM_OPT_TV(0x7C,GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
7074 /* Real Time Difference, Time Difference 10.5.2.41 */
7075 ELEM_OPT_TV(0x7B,GSM_A_PDU_TYPE_RR, DE_RR_TIME_DIFF, " - Real Time Difference");
7077 /* Timing Advance, Timing Advance 10.5.2.40 */
7078 ELEM_OPT_TV(0x7D,GSM_A_PDU_TYPE_RR, DE_RR_TIMING_ADV, "");
7080 /* Frequency Short List, before time, Frequency Short List 10.5.2.14 */
7081 ELEM_OPT_TV(0x12,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_SHORT_LIST, " - Frequency Short List, before time");
7083 /* Frequency List, before time, Frequency List 10.5.2.13 */
7084 ELEM_OPT_TLV(0x19,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_LIST, " - Frequency List, before time");
7086 /* Description of the First Channel, before time, Channel Description 2 10.5.2.5a*/
7087 ELEM_OPT_TV(0x1c,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC2, " - Description of the First Channel, before time");
7089 /* Description of the Second Channel, before time, Channel Description 10.5.2.5*/
7090 ELEM_OPT_TV(0x1d,GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC, " - Description of the Second Channel, before time");
7092 /* Frequency channel sequence before time, Frequency channel sequence 10.5.2.12*/
7093 ELEM_OPT_TV(0x1e,GSM_A_PDU_TYPE_RR, DE_RR_FREQ_CH_SEQ, " - Frequency channel sequence before time");
7095 /* Mobile Allocation, before time, Mobile Allocation 10.5.2.21 */
7096 ELEM_OPT_TLV(0x21,GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, " - Mobile Allocation, before time");
7098 /* Cipher Mode Setting, Cipher Mode Setting 10.5.2.9 */
7099 ELEM_OPT_TV_SHORT(0x90,GSM_A_PDU_TYPE_RR, DE_RR_CIP_MODE_SET, "");
7101 /* VGCS target mode Indication, VGCS target mode Indication 10.5.2.42a */
7102 ELEM_OPT_TLV(0x01,GSM_A_PDU_TYPE_RR, DE_RR_VGCS_TAR_MODE_IND, "");
7104 /* Multi-Rate configuration, MultiRate configuration 10.5.2.21a */
7105 ELEM_OPT_TLV(0x03,GSM_A_PDU_TYPE_RR, DE_RR_MULTIRATE_CONF, "");
7107 /* Dynamic ARFCN Mapping, Dynamic ARFCN Mapping 10.5.2.11b */
7108 ELEM_OPT_TLV(0x76,GSM_A_PDU_TYPE_RR, DE_RR_DYN_ARFCN_MAP, "");
7110 /* VGCS Ciphering Parameters, VGCS Ciphering Parameters 10.5.2.42b */
7111 ELEM_OPT_TLV(0x04,GSM_A_PDU_TYPE_RR, DE_RR_VGCS_CIP_PAR, "");
7113 /* Dedicated Service Information, Dedicated Service Information 10.5.2.59 */
7114 ELEM_OPT_TV(0x51,GSM_A_PDU_TYPE_RR, DE_RR_DED_SERV_INF, "");
7116 EXTRANEOUS_DATA_CHECK(len, curr_offset - offset);
7121 * 9.1.15a Inter System To UTRAN Handover Command
7124 dtap_rr_inter_syst_to_utran_ho_cmd(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7126 guint32 curr_offset;
7130 curr_offset = offset;
7133 /* UTRAN Classmark 10.5.2.51 M LV 2-? */
7134 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_HO_TO_UTRAN_CMD, "");
7136 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7139 /* 3GPP TS 24.008 version 4.7.0 Release 4
7143 dtap_rr_ho_cpte(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7145 guint32 curr_offset;
7148 curr_offset = offset;
7151 /* RR Cause RR Cause 10.5.2.31 M V 1 */
7152 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
7154 /* 77 Mobile Observed Time Difference Mobile Time Difference 10.5.2.21a */
7155 ELEM_OPT_TLV(0x77,GSM_A_PDU_TYPE_RR, DE_RR_MOB_TIME_DIFF, " - Mobile Observed Time Difference");
7157 EXTRANEOUS_DATA_CHECK(len, curr_offset - offset);
7162 * 9.1.17 Handover failure
7165 dtap_rr_ho_fail(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7167 guint32 curr_offset;
7171 curr_offset = offset;
7174 /* RR Cause RR Cause 10.5.2.31 M V 1 */
7175 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
7177 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7182 * 9.1.18 Immediate assignment
7185 dtap_rr_imm_ass(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7187 guint32 curr_offset;
7191 curr_offset = offset;
7194 oct = tvb_get_guint8(tvb, curr_offset);
7196 /* NOTE: The order of the mandatory information elements should be chosen so that
7197 * information elements with 1/2 octet of content (type 1) go together in succession.
7198 * The first type 1 information element occupies bits 1 to 4 of octet N,
7199 * the second bits 5 to 8 of octet N, the third bits 1 to 4 of octet N+1 etc.
7200 * If the number of type 1 information elements is odd then bits 5 to 8 of the last octet
7201 * occupied by these information elements should be treated as spare bits,
7202 * i.e. coded with a "0" in each.
7205 /* Page Mode 10.5.2.26 M V 1/2 */
7206 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7208 /* Dedicated mode or TBF 10.5.2.25b M V 1/2 */
7209 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_DED_MOD_OR_TBF);
7211 if((oct&0x10) == 0){
7212 /* Channel Description 10.5.2.5 C V 3m */
7213 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
7215 /* Packet Channel Description 10.5.2.25a C V 3
7216 * If the Dedicated mode or TBF IE indicates that the message assigns a Temporary Block Flow (TBF),
7217 * the mobile station shall consider this information element present in the message.
7218 * If the Dedicated mode or TBF IE indicates that this message is the first of two in a two-message
7219 * assignment of an uplink or downlink TBF, the mobile station shall ignore the contents
7220 * of this information element and regard it as an unnecessary IE.
7222 if((oct&0x04) == 0){
7223 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_PACKET_CH_DESC);
7226 /* Request Reference 10.5.2.30 M V 3 */
7227 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7229 /* Timing Advance 10.5.2.40 M V 1 */
7230 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TIMING_ADV);
7231 /* Mobile Allocation 10.5.2.21 M LV 1-9 */
7232 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, "");
7233 /* 7C Starting Time 10.5.2.38 O TV 3 */
7234 ELEM_OPT_TV(0x7C,GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
7235 /* IA Rest Octets 10.5.2.16 M V 0-11 */
7236 if(tvb_length_remaining(tvb,curr_offset) > 0)
7237 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_IA_REST_OCT);
7242 * 9.1.19 Immediate assignment extended
7245 dtap_rr_imm_ass_ext(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7247 guint32 curr_offset;
7251 curr_offset = offset;
7254 oct = tvb_get_guint8(tvb, curr_offset);
7256 /* Page Mode 10.5.2.26 M V 1/2 */
7257 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7258 /* Spare Half Octet 10.5.1.8 M V 1/2 */
7259 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_COMMON, DE_SPARE_NIBBLE);
7260 /* Channel Description 1 Channel Description 10.5.2.5 M V 3 */
7261 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
7262 /* Request Reference 1 Request Reference 10.5.2.30 M V 3 */
7263 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7264 /* Timing Advance 1 Timing Advance 10.5.2.40 M V 1 */
7265 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TIMING_ADV);
7266 /* Channel Description 2 Channel Description 10.5.2.5 M V 3 */
7267 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
7268 /* Request Reference 2 Request Reference 10.5.2.30 M V 3 */
7269 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7270 /* Timing Advance 2 Timing Advance 10.5.2.40 M V 1 */
7271 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TIMING_ADV);
7272 /* Mobile Allocation 10.5.2.21 M LV 1-9 */
7273 ELEM_MAND_LV(GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, "");
7274 /* 7C Starting Time 10.5.2.38 O TV 3 */
7275 ELEM_OPT_TV(0x7C,GSM_A_PDU_TYPE_RR, DE_RR_STARTING_TIME, "");
7276 /* IAX Rest Octets 10.5.2.18 M V 0-4 */
7277 if(tvb_length_remaining(tvb,curr_offset) > 0)
7278 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_IAX_REST_OCT);
7283 * 9.1.20 Immediate assignment reject
7286 dtap_rr_imm_ass_rej(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7288 guint32 curr_offset;
7292 curr_offset = offset;
7295 oct = tvb_get_guint8(tvb, curr_offset);
7297 /* Page Mode 10.5.2.26 M V 1/2 */
7298 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7299 /* Spare Half Octet 10.5.1.8 M V 1/2 */
7300 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_COMMON, DE_SPARE_NIBBLE);
7301 /* Request Reference 1 Request Reference 10.5.2.30 M V 3 */
7302 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7303 /* Wait Indication 1 Wait Indication 10.5.2.43 M V 1 */
7304 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_WAIT_IND);
7305 /* Request Reference 2 Request Reference 10.5.2.30 M V 3 */
7306 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7307 /* Wait Indication 2 Wait Indication 10.5.2.43 M V 1 */
7308 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_WAIT_IND);
7309 /* Request Reference 3 Request Reference 10.5.2.30 M V 3 */
7310 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7311 /* Wait Indication 3 Wait Indication 10.5.2.43 M V 1 */
7312 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_WAIT_IND);
7313 /* Request Reference 4 Request Reference 10.5.2.30 M V 3 */
7314 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_REQ_REF);
7315 /* Wait Indication 4 Wait Indication 10.5.2.43 M V 1 */
7316 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_WAIT_IND);
7317 /* IAR Rest Octets 10.5.2.19 M V 3 */
7318 if(tvb_length_remaining(tvb,curr_offset) > 0)
7319 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_IAR_REST_OCT);
7324 * 9.1.21 Measurement report
7327 dtap_rr_meas_rep(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7329 guint32 curr_offset;
7333 curr_offset = offset;
7336 /* Measurement Results 10.5.2.20 M V 16 */
7337 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_MEAS_RES);
7341 * 9.1.7 Paging Request Type 1
7344 dtap_rr_paging_req_type_1(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7346 guint32 curr_offset;
7350 curr_offset = offset;
7352 lower_nibble = FALSE;
7354 /* RR Page Mode 10.5.2.26 M V 1/2 */
7355 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7357 /* RR Channel Needed 10.5.2.8 M V 1/2 */
7358 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_CHNL_NEEDED);
7360 /* RR Mobile Identity 10.5.1.4 M LV 2-9 */
7361 ELEM_MAND_LV(GSM_A_PDU_TYPE_COMMON, DE_MID, " - Mobile Identity 1");
7363 /* RR Mobile Identity 10.5.1.4 O TLV 3-10 */
7364 ELEM_OPT_TLV(0x17, GSM_A_PDU_TYPE_COMMON, DE_MID, " - Mobile Identity 2");
7366 /* RR P1 Rest Octets 10.5.2.23 M V 0-17 */
7367 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_P1_REST_OCT);
7372 * 9.1.8 Paging Request Type 2
7375 dtap_rr_paging_req_type_2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7377 guint32 curr_offset;
7381 curr_offset = offset;
7383 lower_nibble = FALSE;
7385 /* RR Page Mode 10.5.2.26 M V 1/2 */
7386 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7388 /* RR Channel Needed 10.5.2.8 M V 1/2 */
7389 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_CHNL_NEEDED);
7391 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7392 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 1");
7393 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7395 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7396 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 2");
7397 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7399 /* RR Mobile Identity 10.5.1.4 O TLV 3-10 */
7400 ELEM_OPT_TLV(0x17, GSM_A_PDU_TYPE_COMMON, DE_MID, " - Mobile Identity 3");
7402 /* RR P2 Rest Octets 10.5.2.24 M V 1-11 */
7403 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_P2_REST_OCT);
7408 * 9.1.9 Paging Request Type 3
7411 dtap_rr_paging_req_type_3(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7413 guint32 curr_offset;
7417 curr_offset = offset;
7419 lower_nibble = FALSE;
7421 /* RR Page Mode 10.5.2.26 M V 1/2 */
7422 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_PAGE_MODE);
7424 /* RR Channel Needed 10.5.2.8 M V 1/2 */
7425 ELEM_MAND_V_SHORT(GSM_A_PDU_TYPE_RR, DE_RR_CHNL_NEEDED);
7427 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7428 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 1");
7429 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7431 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7432 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 2");
7433 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7435 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7436 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 3");
7437 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7439 /* RR TMSI/P-TMSI 10.5.2.42 M V 4 */
7440 proto_tree_add_text(tree, tvb, curr_offset, 4, "Mobile Identity 4");
7441 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI);
7443 /* RR P3 Rest Octets 10.5.2.25 M V 3 */
7444 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_P3_REST_OCT);
7449 * [4] 9.1.25 Paging response
7452 dtap_rr_paging_resp(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7454 guint32 curr_offset;
7458 proto_tree *subtree;
7461 curr_offset = offset;
7465 * special dissection for Cipher Key Sequence Number
7467 oct = tvb_get_guint8(tvb, curr_offset);
7469 other_decode_bitfield_value(a_bigbuf, oct, 0xf0, 8);
7470 proto_tree_add_text(tree,
7471 tvb, curr_offset, 1,
7476 proto_tree_add_text(tree,
7477 tvb, curr_offset, 1, "%s",
7478 gsm_common_elem_strings[DE_CIPH_KEY_SEQ_NUM].strptr);
7480 subtree = proto_item_add_subtree(item, ett_gsm_common_elem[DE_CIPH_KEY_SEQ_NUM]);
7482 other_decode_bitfield_value(a_bigbuf, oct, 0x08, 8);
7483 proto_tree_add_text(subtree,
7484 tvb, curr_offset, 1,
7488 other_decode_bitfield_value(a_bigbuf, oct, 0x07, 8);
7493 proto_tree_add_text(subtree,
7494 tvb, curr_offset, 1,
7495 "%s : Ciphering Key Sequence Number: No key is available",
7500 proto_tree_add_text(subtree,
7501 tvb, curr_offset, 1,
7502 "%s : Ciphering Key Sequence Number: %u",
7511 if (curr_len <= 0) return;
7513 ELEM_MAND_LV(GSM_A_PDU_TYPE_COMMON, DE_MS_CM_2, "");
7515 ELEM_MAND_LV(GSM_A_PDU_TYPE_COMMON, DE_MID, "");
7517 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7521 * [4] 9.1.26 Partial Release
7524 dtap_rr_partial_rel(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7526 guint32 curr_offset;
7530 curr_offset = offset;
7533 /* Channel Description 10.5.2.5 M V 3 */
7534 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC);
7536 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7540 * [4] 9.1.27 Partial Release Complete
7545 * [4] 9.1.29 Physical Information
7548 dtap_rr_phy_info(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7550 guint32 curr_offset;
7554 curr_offset = offset;
7557 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TIMING_ADV);
7559 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7566 dtap_rr_rr_status(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7568 guint32 curr_offset;
7572 curr_offset = offset;
7575 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CAUSE);
7577 EXTRANEOUS_DATA_CHECK(curr_len, 0);
7584 dtap_rr_sys_info_1(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7586 guint32 curr_offset;
7590 curr_offset = offset;
7593 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_CH_DSC);
7595 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_RACH_CTRL_PARAM);
7597 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI1_REST_OCT);
7604 dtap_rr_sys_info_2(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7606 guint32 curr_offset;
7610 curr_offset = offset;
7613 proto_tree_add_text(tree, tvb, curr_offset, 16, "BCCH Frequency List");
7614 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC);
7616 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NCC_PERM);
7618 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_RACH_CTRL_PARAM);
7625 dtap_rr_sys_info_2bis(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7627 guint32 curr_offset;
7631 curr_offset = offset;
7634 proto_tree_add_text(tree, tvb, curr_offset, 16, "Extended BCCH Frequency List");
7635 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC);
7637 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_RACH_CTRL_PARAM);
7644 dtap_rr_sys_info_2ter(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7646 guint32 curr_offset;
7650 curr_offset = offset;
7653 proto_tree_add_text(tree, tvb, curr_offset, 16, "Extended BCCH Frequency List");
7654 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC2);
7656 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI2TER_REST_OCT);
7663 dtap_rr_sys_info_2quater(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7665 guint32 curr_offset;
7669 curr_offset = offset;
7672 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI2QUATER_REST_OCT);
7679 dtap_rr_sys_info_3(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7681 guint32 curr_offset;
7685 curr_offset = offset;
7688 ELEM_MAND_V(GSM_A_PDU_TYPE_COMMON, DE_CELL_ID);
7690 ELEM_MAND_V(GSM_A_PDU_TYPE_COMMON, DE_LAI);
7692 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CTRL_CH_DESC);
7694 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_OPT_BCCH);
7696 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_SEL_PARAM);
7698 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_RACH_CTRL_PARAM);
7700 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI3_REST_OCT);
7707 dtap_rr_sys_info_4(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7709 guint32 curr_offset;
7713 curr_offset = offset;
7716 ELEM_MAND_V(GSM_A_PDU_TYPE_COMMON, DE_LAI);
7718 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_SEL_PARAM);
7720 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_RACH_CTRL_PARAM);
7722 ELEM_OPT_TV(0x64, GSM_A_PDU_TYPE_RR, DE_RR_CH_DSC, "CBCH Channel Description");
7724 ELEM_OPT_TV(0x72, GSM_A_PDU_TYPE_RR, DE_RR_MOB_ALL, "CBCH Mobile Allocation");
7726 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI4_REST_OCT);
7733 dtap_rr_sys_info_5(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7735 guint32 curr_offset;
7739 curr_offset = offset;
7742 proto_tree_add_text(tree, tvb, curr_offset, 16, "BCCH Frequency List");
7743 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC);
7750 dtap_rr_sys_info_5bis(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7752 guint32 curr_offset;
7756 curr_offset = offset;
7759 proto_tree_add_text(tree, tvb, curr_offset, 16, "Extended BCCH Frequency List");
7760 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC);
7767 dtap_rr_sys_info_5ter(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7769 guint32 curr_offset;
7773 curr_offset = offset;
7776 proto_tree_add_text(tree, tvb, curr_offset, 16, "Extended BCCH Frequency List");
7777 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NEIGH_CELL_DESC2);
7784 dtap_rr_sys_info_6(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7786 guint32 curr_offset;
7790 curr_offset = offset;
7793 ELEM_MAND_V(GSM_A_PDU_TYPE_COMMON, DE_CELL_ID);
7795 ELEM_MAND_V(GSM_A_PDU_TYPE_COMMON, DE_LAI);
7797 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_CELL_OPT_SACCH);
7799 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_NCC_PERM);
7801 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI6_REST_OCT);
7808 dtap_rr_sys_info_13(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7810 guint32 curr_offset;
7814 curr_offset = offset;
7817 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_SI13_REST_OCT);
7821 * [4] 9.1.51 Extended Measurement Order
7824 dtap_rr_ext_meas_order(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7826 guint32 curr_offset;
7830 curr_offset = offset;
7833 /* Extended Measurement Frequency List 10.5.2.46 M V 16 */
7834 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_EXT_MEAS_FREQ_LIST);
7838 * [4] 9.1.52 Extended Measurement Report
7841 dtap_rr_ext_meas_report(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
7843 guint32 curr_offset;
7847 curr_offset = offset;
7850 /* Extended Measurement Result 10.5.2.45 M V 16 */
7851 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_EXT_MEAS_RESULT);
7855 * [4] 9.1.54 Measurement Information
7857 static const value_string gsm_a_rr_3g_wait_vals[] = {
7858 { 0, "1 instance that contain 3G Neighbour Cell Description shall be received"},
7859 { 1, "2 instances that contain 3G Neighbour Cell Description shall be received"},
7860 { 2, "3 instances that contain 3G Neighbour Cell Description shall be received"},
7861 { 3, "4 instances that contain 3G Neighbour Cell Description shall be received"},
7862 { 4, "5 instances that contain 3G Neighbour Cell Description shall be received"},
7863 { 5, "6 instances that contain 3G Neighbour Cell Description shall be received"},
7864 { 6, "7 instances that contain 3G Neighbour Cell Description shall be received"},
7865 { 7, "8 instances that contain 3G Neighbour Cell Description shall be received"},
7871 sacch_rr_meas_info(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len _U_)
7873 proto_tree *subtree, *subtree2;
7874 proto_item *item, *item2;
7875 guint32 curr_offset;
7876 gint bit_offset, bit_offset_sav, bit_offset_sav2;
7879 curr_offset = offset;
7880 bit_offset = curr_offset << 3;
7882 proto_tree_add_bits_item(tree, hf_gsm_a_rr_ba_ind, tvb, bit_offset, 1, FALSE);
7884 proto_tree_add_bits_item(tree, hf_gsm_a_rr_3g_ba_ind, tvb, bit_offset, 1, FALSE);
7886 proto_tree_add_bits_item(tree, hf_gsm_a_rr_mp_change_mark, tvb, bit_offset, 1, FALSE);
7888 proto_tree_add_bits_item(tree, hf_gsm_a_rr_mi_index, tvb, bit_offset, 4, FALSE);
7890 proto_tree_add_bits_item(tree, hf_gsm_a_rr_mi_count, tvb, bit_offset, 4, FALSE);
7892 proto_tree_add_bits_item(tree, hf_gsm_a_rr_pwrc, tvb, bit_offset, 1, FALSE);
7894 proto_tree_add_bits_item(tree, hf_gsm_a_rr_gsm_report_type, tvb, bit_offset, 1, FALSE);
7896 proto_tree_add_bits_item(tree, hf_gsm_a_rr_reporting_rate, tvb, bit_offset, 1, FALSE);
7898 proto_tree_add_bits_item(tree, hf_gsm_a_rr_invalid_bsic_reporting, tvb, bit_offset, 1, FALSE);
7900 value = tvb_get_bits8(tvb,bit_offset,1);
7903 { /* Real Time Difference Description */
7904 bit_offset += de_rr_rtd_desc(tvb, tree, bit_offset, DE_RR_REST_OCTETS_RTD_DESC);
7906 value = tvb_get_bits8(tvb,bit_offset,1);
7909 { /* BSIC Description */
7910 bit_offset += de_rr_bsic_desc(tvb, tree, bit_offset, DE_RR_REST_OCTETS_BSIC_DESC);
7912 value = tvb_get_bits8(tvb,bit_offset,1);
7915 { /* Report Priority Description */
7916 bit_offset += de_rr_report_priority_desc(tvb, tree, bit_offset, DE_RR_REST_OCTETS_REPORT_PRIO_DESC);
7918 value = tvb_get_bits8(tvb,bit_offset,1);
7921 { /* Measurement Parameters Description */
7922 bit_offset += de_rr_meas_param_desc(tvb, tree, bit_offset, DE_RR_REST_OCTETS_MEAS_PARAM_DESC);
7924 value = tvb_get_bits8(tvb,bit_offset,1);
7927 { /* used for future extensions of the 2G parameters */
7928 value = tvb_get_bits8(tvb,bit_offset,8);
7929 bit_offset += 8 + value + 1;
7931 value = tvb_get_bits8(tvb,bit_offset,1);
7934 { /* 3G Neighbour Cell Description */
7935 bit_offset_sav = bit_offset;
7936 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_NEIGH_CELL_DESC].strptr);
7937 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_NEIGH_CELL_DESC]);
7938 value = tvb_get_bits8(tvb,bit_offset,1);
7942 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_3g_wait, tvb, bit_offset, 3, FALSE);
7945 value = tvb_get_bits8(tvb,bit_offset,1);
7949 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_index_start_3g, tvb, bit_offset, 7, FALSE);
7952 value = tvb_get_bits8(tvb,bit_offset,1);
7956 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_absolute_index_start_emr, tvb, bit_offset, 7, FALSE);
7959 value = tvb_get_bits8(tvb,bit_offset,1);
7962 { /* UTRAN FDD Description */
7963 bit_offset += de_rr_si2quater_meas_info_utran_fdd_desc(tvb, subtree, bit_offset);
7965 value = tvb_get_bits8(tvb,bit_offset,1);
7968 { /* UTRAN TDD Description */
7969 bit_offset += de_rr_si2quater_meas_info_utran_tdd_desc(tvb, subtree, bit_offset);
7971 value = tvb_get_bits8(tvb,bit_offset,1);
7974 { /* CDMA2000 Description */
7975 bit_offset_sav2 = bit_offset;
7976 item2 = proto_tree_add_text(subtree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_CDMA2000_DESC].strptr);
7977 subtree2 = proto_item_add_subtree(item2, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_CDMA2000_DESC]);
7978 bit_offset += 16; /* cdma2000 frequency band + cdma2000 frequency */
7979 idx = tvb_get_bits8(tvb,bit_offset,5); /* number_cdma2000_cells */
7983 bit_offset += 9; /* Pilot PN offset */
7984 if (tvb_get_bits8(tvb,bit_offset,1))
7987 value = tvb_get_bits8(tvb,bit_offset,3);
7991 bit_offset += 5; /* TD_MODE + TD_POWER_LEVEL */
7994 bit_offset += 2; /* QOF */
7995 bit_offset += tvb_get_bits8(tvb,bit_offset,3) + 3 + 6; /* WALSH_LEN_A + bit(val(WALSH_LEN_A)+6) */
7998 bit_offset += 2; /* QOF */
7999 bit_offset += tvb_get_bits8(tvb,bit_offset,3) + 3 + 6; /* WALSH_LEN_B + bit(val(WALSH_LEN_B)+6) */
8000 bit_offset += 4; /* AUX_TD_POWER_LEVEL + TD_MODE */
8003 bit_offset += 8; /* SR3_PRIM_PILOT + SR3_PILOT_POWER1 + SR3_PILOT_POWER2 */
8006 bit_offset += 10; /* SR3_PRIM_PILOT + SR3_PILOT_POWER1 + SR3_PILOT_POWER2 + QOF */
8007 bit_offset += tvb_get_bits8(tvb,bit_offset,3) + 3 + 6; /* WALSH_LEN_C + bit(val(WALSH_LEN_C)+6) */
8008 if (tvb_get_bits8(tvb,bit_offset,1))
8010 bit_offset += 3; /* 1 + QOF1 */
8011 bit_offset += tvb_get_bits8(tvb,bit_offset,3) + 3 + 6; /* WALSH_LENGTH1 + bit(val(WALSH_LENGTH1)+6) */
8015 if (tvb_get_bits8(tvb,bit_offset,1))
8017 bit_offset += 3; /* 1 + QOF2 */
8018 bit_offset += tvb_get_bits8(tvb,bit_offset,3) + 3 + 6; /* WALSH_LENGTH2 + bit(val(WALSH_LENGTH2)+6) */
8024 /* decoding sequence is unknown ! */
8032 proto_tree_add_text(subtree2,tvb, bit_offset_sav2>>3, ((bit_offset-bit_offset_sav2)>>3)+1,"Data(Not decoded)");
8033 proto_item_set_len(item2,((bit_offset-bit_offset_sav2)>>3)+1);
8035 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
8037 value = tvb_get_bits8(tvb,bit_offset,1);
8040 { /* 3G Measurement Parameters Description */
8041 bit_offset_sav = bit_offset;
8042 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC].strptr);
8043 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_3G_MEAS_PARAM_DESC]);
8044 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_qsearch_c, tvb, bit_offset, 4, FALSE);
8046 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_3g_search_prio, tvb, bit_offset, 1, FALSE);
8048 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_rep_quant, tvb, bit_offset, 1, FALSE);
8050 value = tvb_get_bits8(tvb,bit_offset,1);
8054 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
8057 value = tvb_get_bits8(tvb,bit_offset,1);
8061 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_reporting_offset, tvb, bit_offset, 3, FALSE);
8063 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_fdd_reporting_threshold, tvb, bit_offset, 3, FALSE);
8066 value = tvb_get_bits8(tvb,bit_offset,1);
8070 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_tdd_multirat_reporting, tvb, bit_offset, 2, FALSE);
8073 value = tvb_get_bits8(tvb,bit_offset,1);
8077 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_tdd_reporting_offset, tvb, bit_offset, 3, FALSE);
8079 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_tdd_reporting_threshold, tvb, bit_offset, 3, FALSE);
8082 value = tvb_get_bits8(tvb,bit_offset,1);
8085 bit_offset += 2; /* CDMA2000 Multirat Reporting */
8086 value = tvb_get_bits8(tvb,bit_offset,1);
8089 bit_offset += 6; /* CDMA2000 Reporting Offset + CDMA2000 Reporting Threshold */
8090 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
8092 if (((curr_offset + len)<<3) - bit_offset > 0)
8094 /* There is still room left in the Rest Octets IE */
8095 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
8096 { /* Additions in Rel-5 */
8098 value = tvb_get_bits8(tvb,bit_offset,1);
8101 { /* 3G Additional Measurement Parameters Description 2 */
8102 bit_offset += de_rr_3g_add_meas_param_desc2(tvb, tree, bit_offset);
8104 if (((curr_offset + len)<<3) - bit_offset > 0)
8106 /* There is still room left in the Rest Octets IE */
8107 if (gsm_a_rr_is_bit_high(tvb,bit_offset) == TRUE)
8108 { /* Additions in Rel-7 */
8110 value = tvb_get_bits8(tvb,bit_offset,1);
8114 proto_tree_add_bits_item(tree, hf_gsm_a_rr_700_reporting_offset, tvb, bit_offset, 3, FALSE);
8116 proto_tree_add_bits_item(tree, hf_gsm_a_rr_700_reporting_threshold, tvb, bit_offset, 3, FALSE);
8119 value = tvb_get_bits8(tvb,bit_offset,1);
8123 proto_tree_add_bits_item(tree, hf_gsm_a_rr_810_reporting_offset, tvb, bit_offset, 3, FALSE);
8125 proto_tree_add_bits_item(tree, hf_gsm_a_rr_810_reporting_threshold, tvb, bit_offset, 3, FALSE);
8139 * [4] 9.1.55 Enhanced Measurement Information
8141 static const true_false_string gsm_a_rr_bsic_seen_value = {
8142 "One Cell or more with invalid BSIC and allowed NCC part of BSIC is seen",
8143 "No cell with invalid BSIC and allowed NCC part of BSIC is seen"
8146 static const true_false_string gsm_a_rr_scale_value = {
8151 static const value_string gsm_a_rr_mean_bep_gmsk_vals[] = {
8152 { 0, "log10(BEP) > -0.60"},
8153 { 1, "-0.70 < log10(BEP) < -0.60"},
8154 { 2, "-0.80 < log10(BEP) < -0.70"},
8155 { 3, "-0.90 < log10(BEP) < -0.80"},
8156 { 4, "-1.00 < log10(BEP) < -0.90"},
8157 { 5, "-1.10 < log10(BEP) < -1.00"},
8158 { 6, "-1.20 < log10(BEP) < -1.10"},
8159 { 7, "-1.30 < log10(BEP) < -1.20"},
8160 { 8, "-1.40 < log10(BEP) < -1.30"},
8161 { 9, "-1.50 < log10(BEP) < -1.40"},
8162 { 10, "-1.60 < log10(BEP) < -1.50"},
8163 { 11, "-1.70 < log10(BEP) < -1.60"},
8164 { 12, "-1.80 < log10(BEP) < -1.70"},
8165 { 13, "-1.90 < log10(BEP) < -1.80"},
8166 { 14, "-2.00 < log10(BEP) < -1.90"},
8167 { 15, "-2.10 < log10(BEP) < -2.00"},
8168 { 16, "-2.20 < log10(BEP) < -2.10"},
8169 { 17, "-2.30 < log10(BEP) < -2.20"},
8170 { 18, "-2.40 < log10(BEP) < -2.30"},
8171 { 19, "-2.50 < log10(BEP) < -2.40"},
8172 { 20, "-2.60 < log10(BEP) < -2.50"},
8173 { 21, "-2.70 < log10(BEP) < -2.60"},
8174 { 22, "-2.80 < log10(BEP) < -2.70"},
8175 { 23, "-2.90 < log10(BEP) < -2.80"},
8176 { 24, "-3.00 < log10(BEP) < -2.90"},
8177 { 25, "-3.10 < log10(BEP) < -3.00"},
8178 { 26, "-3.20 < log10(BEP) < -3.10"},
8179 { 27, "-3.30 < log10(BEP) < -3.20"},
8180 { 28, "-3.40 < log10(BEP) < -3.30"},
8181 { 29, "-3.50 < log10(BEP) < -3.40"},
8182 { 30, "-3.60 < log10(BEP) < -3.50"},
8183 { 31, "log10(BEP) < -3.60"},
8187 static const value_string gsm_a_rr_cv_bep_vals[] = {
8188 { 0, "1.75 < CV BEP < 2.00"},
8189 { 1, "1.50 < CV BEP < 1.75"},
8190 { 2, "1.25 < CV BEP < 1.50"},
8191 { 3, "1.00 < CV BEP < 1.25"},
8192 { 4, "0.75 < CV BEP < 1.00"},
8193 { 5, "0.50 < CV BEP < 0.75"},
8194 { 6, "0.25 < CV BEP < 0.50"},
8195 { 7, "0.00 < CV BEP < 0.25"},
8201 sacch_rr_enh_meas_report(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
8203 proto_tree *subtree;
8205 guint32 curr_offset;
8206 gint bit_offset, bit_offset_sav;
8209 curr_offset = offset;
8210 bit_offset = curr_offset << 3;
8212 proto_tree_add_bits_item(tree, hf_gsm_a_rr_ba_used, tvb, bit_offset, 1, FALSE);
8214 proto_tree_add_bits_item(tree, hf_gsm_a_rr_3g_ba_used, tvb, bit_offset, 1, FALSE);
8216 proto_tree_add_bits_item(tree, hf_gsm_a_rr_bsic_seen, tvb, bit_offset, 1, FALSE);
8218 proto_tree_add_bits_item(tree, hf_gsm_a_rr_scale, tvb, bit_offset, 1, FALSE);
8220 value = tvb_get_bits8(tvb,bit_offset,1);
8223 { /* Serving cell data */
8224 bit_offset_sav = bit_offset;
8225 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_SERVING_CELL_DATA].strptr);
8226 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_SERVING_CELL_DATA]);
8227 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_dtx_used, tvb, bit_offset, 1, FALSE);
8229 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxlev_full_serv_cell, tvb, bit_offset, 6, FALSE);
8231 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxqual_full_serv_cell, tvb, bit_offset, 3, FALSE);
8233 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_mean_bep_gmsk, tvb, bit_offset, 5, FALSE);
8235 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_mean_cv_bep, tvb, bit_offset, 3, FALSE);
8237 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_nbr_rcvd_blocks, tvb, bit_offset, 5, FALSE);
8239 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
8241 value = tvb_get_bits8(tvb,bit_offset,1);
8244 { /* Repeated Invalid BSIC Information */
8245 bit_offset_sav = bit_offset;
8246 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_REPEAT_INV_BSIC_INFO].strptr);
8247 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_REPEAT_INV_BSIC_INFO]);
8248 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bcch_freq_ncell, tvb, bit_offset, 5, FALSE);
8250 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_bsic_ncell, tvb, bit_offset, 6, FALSE);
8252 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_rxlev_ncell, tvb, bit_offset, 6, FALSE);
8254 proto_item_set_len(item,((bit_offset-bit_offset_sav)>>3)+1);
8255 value = tvb_get_bits8(tvb,bit_offset,1);
8258 value = tvb_get_bits8(tvb,bit_offset,1);
8261 { /* Bitmap Type Reporting */
8262 bit_offset_sav = bit_offset;
8263 item = proto_tree_add_text(tree, tvb, bit_offset>>3, -1, "%s", gsm_rr_rest_octets_elem_strings[DE_RR_REST_OCTETS_BITMAP_TYPE_REPORTING].strptr);
8264 subtree = proto_item_add_subtree(item, ett_gsm_rr_rest_octets_elem[DE_RR_REST_OCTETS_BITMAP_TYPE_REPORTING]);
8266 while (((guint)(bit_offset>>3) <= (offset + len)) && (idx < 96))
8268 value = tvb_get_bits8(tvb,bit_offset,1);
8272 proto_tree_add_text(subtree, tvb, bit_offset>>3, 1, "Neighbour Cell List index: %u", idx);
8273 proto_tree_add_bits_item(subtree, hf_gsm_a_rr_reporting_quantity, tvb, bit_offset, 6, FALSE);
8281 #define NUM_GSM_DTAP_MSG_RR (sizeof(gsm_a_dtap_msg_rr_strings)/sizeof(value_string))
8282 static gint ett_gsm_dtap_msg_rr[NUM_GSM_DTAP_MSG_RR];
8283 static void (*dtap_msg_rr_fcn[])(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len) = {
8284 NULL, /* Reserved */
8285 dtap_rr_add_ass, /* Additional Assignment */
8286 dtap_rr_imm_ass, /* 9.1.18 Immediate assignment */
8287 dtap_rr_imm_ass_ext, /* Immediate Assignment Extended */
8288 dtap_rr_imm_ass_rej, /* Immediate Assignment Reject */
8290 NULL, /* DTM Assignment Failure */
8291 NULL, /* DTM Reject */
8292 NULL, /* DTM Request */
8293 NULL, /* Main DCCH Assignment Command */
8294 NULL, /* Packet Assignment Command */
8296 dtap_rr_cip_mode_cmd, /* Ciphering Mode Command */
8297 dtap_rr_cip_mode_cpte, /* Ciphering Mode Complete */
8299 dtap_rr_conf_change_cmd, /* Configuration Change Command */
8300 NULL, /* Configuration Change Ack. */
8301 dtap_rr_conf_change_rej, /* Configuration Change Reject */
8303 dtap_rr_ass_cmd, /* 9.1.2 Assignment Command */
8304 dtap_rr_ass_comp, /* Assignment Complete */
8305 dtap_rr_ass_fail, /* Assignment Failure */
8306 dtap_rr_ho_cmd, /* Handover Command */
8307 dtap_rr_ho_cpte, /* Handover Complete */
8308 dtap_rr_ho_fail, /* Handover Failure */
8309 dtap_rr_phy_info, /* Physical Information */
8310 NULL, /* DTM Assignment Command */
8312 NULL, /* RR-cell Change Order */
8313 NULL, /* PDCH Assignment Command */
8315 dtap_rr_ch_rel, /* Channel Release */
8316 dtap_rr_partial_rel, /* Partial Release */
8317 NULL, /* Partial Release Complete */
8319 dtap_rr_paging_req_type_1, /* Paging Request Type 1 */
8320 dtap_rr_paging_req_type_2, /* Paging Request Type 2 */
8321 dtap_rr_paging_req_type_3, /* Paging Request Type 3 */
8322 dtap_rr_paging_resp, /* Paging Response */
8323 NULL, /* Notification/NCH */
8324 NULL, /* Reserved */
8325 NULL, /* Notification/Response */
8327 NULL, /* Reserved */
8329 dtap_rr_utran_classmark_change, /* Utran Classmark Change */
8330 NULL, /* cdma2000 Classmark Change */
8331 dtap_rr_inter_syst_to_utran_ho_cmd, /* Inter System to UTRAN Handover Command */
8332 NULL, /* Inter System to cdma2000 Handover Command */
8334 NULL, /* System Information Type 8 */
8335 dtap_rr_sys_info_1, /* System Information Type 1 */
8336 dtap_rr_sys_info_2, /* System Information Type 2 */
8337 dtap_rr_sys_info_3, /* System Information Type 3 */
8338 dtap_rr_sys_info_4, /* System Information Type 4 */
8339 dtap_rr_sys_info_5, /* System Information Type 5 */
8340 dtap_rr_sys_info_6, /* System Information Type 6 */
8341 NULL, /* System Information Type 7 */
8343 dtap_rr_sys_info_2bis, /* System Information Type 2bis */
8344 dtap_rr_sys_info_2ter, /* System Information Type 2ter */
8345 dtap_rr_sys_info_2quater, /* System Information Type 2quater */
8346 dtap_rr_sys_info_5bis, /* System Information Type 5bis */
8347 dtap_rr_sys_info_5ter, /* System Information Type 5ter */
8348 NULL, /* System Information Type 9 */
8349 dtap_rr_sys_info_13, /* System Information Type 13 */
8351 NULL, /* System Information Type 16 */
8352 NULL, /* System Information Type 17 */
8354 NULL, /* System Information Type 18 */
8355 NULL, /* System Information Type 19 */
8356 NULL, /* System Information Type 20 */
8358 dtap_rr_ch_mode_mod, /* Channel Mode Modify */
8359 dtap_rr_rr_status, /* RR Status */
8360 dtap_rr_ch_mode_mod_ack, /* Channel Mode Modify Acknowledge */
8361 dtap_rr_freq_redef, /* Frequency Redefinition */
8362 dtap_rr_meas_rep, /* 9.1.21 Measurement report */
8363 dtap_rr_mm_cm_change, /* 9.1.11 Classmark Change */
8364 dtap_rr_cm_enq, /* Classmark Enquiry */
8365 dtap_rr_ext_meas_report, /* Extended Measurement Report */
8366 dtap_rr_ext_meas_order, /* Extended Measurement Order */
8367 dtap_rr_gprs_sus_req, /* 9.1.13b GPRS Suspension Request */
8369 NULL, /* VGCS Uplink Grant */
8370 NULL, /* Uplink Release */
8371 NULL, /* Reserved */
8372 NULL, /* Uplink Busy */
8373 NULL, /* Talker Indication */
8375 NULL, /* UTRAN Classmark Change/Handover To UTRAN Command */ /* spec conflict */
8377 NULL, /* Application Information */
8382 void get_rr_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn)
8386 *msg_str = match_strval_idx((guint32) (oct & DTAP_RR_IEI_MASK), gsm_a_dtap_msg_rr_strings, &idx);
8387 *ett_tree = ett_gsm_dtap_msg_rr[idx];
8388 *hf_idx = hf_gsm_a_dtap_msg_rr_type;
8389 *msg_fcn = dtap_msg_rr_fcn[idx];
8393 /* This is more or less a copy of the dissect_dtap() code just adding
8394 * L2 Pseudo Length decoding first
8395 * The code should probably be cleaned up.
8396 * The name CCCH might not be correct!
8399 dissect_ccch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
8402 static gsm_a_tap_rec_t tap_rec[4];
8403 static gsm_a_tap_rec_t *tap_p;
8404 static guint tap_current=0;
8406 void (*msg_fcn)(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len);
8409 guint32 offset, saved_offset;
8411 guint32 oct_1, oct_2;
8412 proto_item *ccch_item = NULL;
8413 proto_tree *ccch_tree = NULL;
8414 proto_item *oct_1_item = NULL;
8415 proto_tree *pd_tree = NULL;
8416 proto_tree *saved_tree = NULL;
8417 const gchar *msg_str;
8423 guint32 curr_offset;
8427 len = tvb_length(tvb);
8431 * too short to be CCCH
8433 call_dissector(data_handle, tvb, pinfo, tree);
8437 if (check_col(pinfo->cinfo, COL_INFO)){
8438 col_append_str(pinfo->cinfo, COL_INFO, "(CCCH) ");
8441 * set tap record pointer
8444 if (tap_current >= 4)
8448 tap_p = &tap_rec[tap_current];
8453 /* Skip pseeudo hdr here */
8457 * get protocol discriminator
8459 oct_1 = tvb_get_guint8(tvb, offset++);
8461 if ((((oct_1 & DTAP_TI_MASK) >> 4) & DTAP_TIE_PRES_MASK) == DTAP_TIE_PRES_MASK){
8463 * eventhough we don't know if a TI should be in the message yet
8464 * we rely on the TI/SKIP indicator to be 0 to avoid taking this
8467 oct_2 = tvb_get_guint8(tvb, offset++);
8470 oct = tvb_get_guint8(tvb, offset);
8472 pd = oct_1 & DTAP_PD_MASK;
8479 if (check_col(pinfo->cinfo, COL_INFO)){
8480 col_append_fstr(pinfo->cinfo, COL_INFO, "(%s) ",val_to_str(pd,gsm_a_pd_short_str_vals,"Unknown (%u)"));
8488 get_rr_msg_params(oct, &msg_str, &ett_tree, &hf_idx, &msg_fcn);
8492 /* XXX - hf_idx is still -1! this is a bug in the implementation, and I don't know how to fix it so simple return here */
8497 * create the protocol tree
8499 if (msg_str == NULL){
8500 ccch_item = proto_tree_add_protocol_format(tree, proto_a_ccch, tvb, 0, len,
8501 "GSM CCCH - Message Type (0x%02x)",
8504 ccch_tree = proto_item_add_subtree(ccch_item, ett_ccch_msg);
8506 ccch_item = proto_tree_add_protocol_format(tree, proto_a_ccch, tvb, 0, -1,
8507 "GSM CCCH - %s", msg_str);
8509 ccch_tree = proto_item_add_subtree(ccch_item, ett_tree);
8512 if (check_col(pinfo->cinfo, COL_INFO)){
8513 col_append_fstr(pinfo->cinfo, COL_INFO, "%s ", msg_str);
8516 /* back to the begining */
8517 saved_offset = offset;
8520 curr_offset = offset;
8524 /* L2 Pseudo Length 10.5.2.19 */
8525 pseudo_len = tvb_get_guint8(tvb,offset)>>2;
8529 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_L2_PSEUDO_LEN);
8531 offset = saved_offset;
8534 proto_tree_add_text(ccch_tree,
8536 "Protocol Discriminator: %s",
8537 val_to_str(pd, protocol_discriminator_vals, "Unknown (%u)"));
8539 pd_tree = proto_item_add_subtree(oct_1_item, ett_ccch_oct_1);
8542 proto_tree_add_item(pd_tree, hf_gsm_a_skip_ind, tvb, 1, 1, FALSE);
8544 other_decode_bitfield_value(a_bigbuf, oct_1, 0x80, 8);
8545 proto_tree_add_text(pd_tree,tvb, 1, 1,
8548 ((oct_1 & 0x80) ? "allocated by receiver" : "allocated by sender"));
8550 if ((ti & DTAP_TIE_PRES_MASK) == DTAP_TIE_PRES_MASK){
8551 /* ti is extended to next octet */
8552 other_decode_bitfield_value(a_bigbuf, oct_1, 0x70, 8);
8553 proto_tree_add_text(pd_tree, tvb, 1, 1,
8554 "%s : TIO: The TI value is given by the TIE in octet 2",
8557 other_decode_bitfield_value(a_bigbuf, oct_1, 0x70, 8);
8558 proto_tree_add_text(pd_tree,tvb, 1, 1,
8559 "%s : TIO: %u",a_bigbuf,ti & DTAP_TIE_PRES_MASK);
8563 proto_tree_add_item(pd_tree, hf_gsm_a_L3_protocol_discriminator, tvb, 1, 1, FALSE);
8565 if ((ti != -1) && (ti & DTAP_TIE_PRES_MASK) == DTAP_TIE_PRES_MASK){
8566 proto_tree_add_item(tree, hf_gsm_a_extension, tvb, 2, 1, FALSE);
8567 other_decode_bitfield_value(a_bigbuf, oct_2, DTAP_TIE_MASK, 8);
8568 proto_tree_add_text(pd_tree, tvb, 2, 1,
8569 "%s : TIE: %u", a_bigbuf, oct_2 & DTAP_TIE_MASK);
8575 if ((pinfo->p2p_dir == P2P_DIR_RECV) &&
8582 * add DTAP message name
8584 proto_tree_add_uint_format(ccch_tree, hf_idx, tvb, offset, 1, oct,
8585 "Message Type: %s",msg_str ? msg_str : "(Unknown)");
8589 tap_p->pdu_type = GSM_A_PDU_TYPE_DTAP;
8590 tap_p->message_type = (nsd ? (oct & 0x3f) : oct);
8591 tap_p->protocol_disc = pd;
8593 tap_queue_packet(gsm_a_tap, pinfo, tap_p);
8595 if (msg_str == NULL)
8598 if ((len - offset) <= 0)
8604 if (msg_fcn == NULL){
8605 proto_tree_add_text(ccch_tree, tvb, offset, len - offset,
8606 "Message Elements");
8608 (*msg_fcn)(tvb, ccch_tree, offset, len - offset);
8612 const value_string gsm_a_sacch_msg_rr_strings[] = {
8613 { 0x00, "System Information Type 10" },
8614 { 0x01, "Notification/FACCH" },
8615 { 0x02, "Uplink Free" },
8616 { 0x04, "Enhanced Measurement Report" },
8617 { 0x05, "Measurement Information" },
8618 { 0x06, "VBS/VGCS Reconfigure" },
8619 { 0x07, "VBS/VGCS Reconfigure2" },
8620 { 0x08, "VGCS Additional Information" },
8621 { 0x09, "VGCS SMS Information" },
8625 #define NUM_GSM_SACCH_MSG_RR (sizeof(gsm_a_sacch_msg_rr_strings)/sizeof(value_string))
8626 static gint ett_gsm_sacch_msg_rr[NUM_GSM_SACCH_MSG_RR];
8627 static void (*sacch_msg_rr_fcn[])(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len) = {
8628 NULL, /* System Information Type 10 */
8629 NULL, /* Notification/FACCH */
8630 NULL, /* Uplink Free */
8631 sacch_rr_enh_meas_report, /* Enhanced Measurement Report */
8632 sacch_rr_meas_info, /* Measurement Information */
8633 NULL, /* VBS/VGCS Reconfigure */
8634 NULL, /* VBS/VGCS Reconfigure2 */
8635 NULL, /* VGCS Additional Information */
8636 NULL, /* VGCS SMS Information */
8640 void get_rr_short_pd_msg_params(guint8 mess_type, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn)
8644 *msg_str = match_strval_idx((guint32) mess_type, gsm_a_sacch_msg_rr_strings, &idx);
8645 *ett_tree = ett_gsm_sacch_msg_rr[idx];
8646 *hf_idx = hf_gsm_a_sacch_msg_rr_type;
8647 *msg_fcn = sacch_msg_rr_fcn[idx];
8650 const value_string short_protocol_discriminator_vals[] = {
8651 {0x0, "Radio Resources Management messages"},
8656 dissect_sacch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
8658 static gsm_a_tap_rec_t tap_rec[4];
8659 static gsm_a_tap_rec_t *tap_p;
8660 static guint tap_current=0;
8662 void (*msg_fcn)(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len);
8663 guint8 oct, short_pd, mess_type;
8666 proto_item *sacch_item = NULL;
8667 proto_tree *sacch_tree = NULL;
8668 const gchar *msg_str;
8672 len = tvb_length(tvb);
8674 if (check_col(pinfo->cinfo, COL_INFO))
8675 col_append_str(pinfo->cinfo, COL_INFO, "(SACCH) ");
8678 * set tap record pointer
8681 if (tap_current >= 4)
8685 tap_p = &tap_rec[tap_current];
8689 oct = tvb_get_guint8(tvb, offset);
8696 short_pd = (oct & 0x80) >> 7;
8697 mess_type = (oct & 0x7c) >> 2;
8701 if (check_col(pinfo->cinfo, COL_INFO))
8702 col_append_fstr(pinfo->cinfo, COL_INFO, "(RR) ");
8703 get_rr_short_pd_msg_params(mess_type, &msg_str, &ett_tree, &hf_idx, &msg_fcn);
8707 if (check_col(pinfo->cinfo, COL_INFO))
8708 col_append_fstr(pinfo->cinfo, COL_INFO, "(Unknown) ");
8712 * create the protocol tree
8714 if (msg_str == NULL){
8715 sacch_item = proto_tree_add_protocol_format(tree, proto_a_sacch, tvb, 0, len,
8716 "GSM SACCH - Message Type (0x%02x)", mess_type);
8718 sacch_tree = proto_item_add_subtree(sacch_item, ett_sacch_msg);
8720 sacch_item = proto_tree_add_protocol_format(tree, proto_a_sacch, tvb, 0, -1,
8721 "GSM SACCH - %s", msg_str);
8723 sacch_tree = proto_item_add_subtree(sacch_item, ett_tree);
8725 if (check_col(pinfo->cinfo, COL_INFO)){
8726 col_append_fstr(pinfo->cinfo, COL_INFO, "%s ", msg_str);
8731 proto_tree_add_text(sacch_tree,
8733 "Short Protocol Discriminator: %s",
8734 val_to_str(short_pd, short_protocol_discriminator_vals, "Unknown (%u)"));
8740 * add SACCH message name
8742 proto_tree_add_uint_format(sacch_tree, hf_idx, tvb, offset, 1, oct,
8743 "Message Type: %s",msg_str ? msg_str : "(Unknown)");
8745 proto_tree_add_text(sacch_tree, tvb, offset, 1,
8746 "Short Layer 2 header: %u", oct & 0x03);
8750 tap_p->pdu_type = GSM_A_PDU_TYPE_SACCH;
8751 tap_p->message_type = mess_type;
8752 tap_p->protocol_disc = short_pd;
8754 tap_queue_packet(gsm_a_tap, pinfo, tap_p);
8756 if (msg_str == NULL)
8762 if (msg_fcn == NULL){
8763 proto_tree_add_text(sacch_tree, tvb, offset, len - offset,
8764 "Message Elements");
8766 (*msg_fcn)(tvb, sacch_tree, offset, len - offset);
8770 /* Register the protocol with Wireshark */
8772 proto_register_gsm_a_rr(void)
8777 /* Setup list of header fields */
8779 static hf_register_info hf[] =
8781 { &hf_gsm_a_dtap_msg_rr_type,
8782 { "DTAP Radio Resources Management Message Type", "gsm_a.dtap_msg_rr_type",
8783 FT_UINT8, BASE_HEX, VALS(gsm_a_dtap_msg_rr_strings), 0x0,
8786 { &hf_gsm_a_rr_elem_id,
8787 { "Element ID", "gsm_a_rr.elem_id",
8788 FT_UINT8, BASE_DEC, NULL, 0,
8792 { "BCC","gsm_a.bcc",
8793 FT_UINT8,BASE_DEC, NULL, 0x07,
8797 { "NCC","gsm_a.ncc",
8798 FT_UINT8,BASE_DEC, NULL, 0x38,
8801 { &hf_gsm_a_bcch_arfcn,
8802 { "BCCH ARFCN(RF channel number)","gsm_a.bcch_arfcn",
8803 FT_UINT16,BASE_DEC, NULL, 0x0,
8804 "BCCH ARFCN", HFILL }
8806 { &hf_gsm_a_rr_range_nb,
8807 { "Number of Ranges","gsm_a.rr.range_nb",
8808 FT_UINT8, BASE_DEC, NULL, 0xff,
8809 "Number of Ranges", HFILL }
8811 { &hf_gsm_a_rr_range_lower,
8812 { "Range Lower","gsm_a.rr.range_lower",
8813 FT_UINT16, BASE_DEC, NULL, 0x0000,
8814 "ARFCN used as the lower limit of a range of frequencies to be used by the mobile station in cell selection (Range Lower)", HFILL }
8816 { &hf_gsm_a_rr_range_higher,
8817 { "Range Higher","gsm_a.rr.range_higher",
8818 FT_UINT16, BASE_DEC, NULL, 0x0000,
8819 "ARFCN used as the higher limit of a range of frequencies to be used by the mobile station in cell selection (Range Higher)", HFILL }
8821 { &hf_gsm_a_rr_ba_list_pref_length,
8822 { "Length of BA List Pref","gsm_a.rr.ba_list_pref_length",
8823 FT_UINT8, BASE_DEC, NULL, 0xff,
8824 "Length of BA List Pref", HFILL }
8826 { &hf_gsm_a_rr_ba_freq,
8827 { "BA Freq","gsm_a.rr.ba_freq",
8828 FT_UINT16, BASE_DEC, NULL, 0x0000,
8829 "ARFCN indicating a single frequency to be used by the mobile station in cell selection and reselection (BA Freq)", HFILL }
8831 { &hf_gsm_a_rr_utran_freq_list_length,
8832 { "Length of BA List Pref","gsm_a.rr.ba_list_pref_length",
8833 FT_UINT8, BASE_DEC, NULL, 0xff,
8834 "Length of BA List Pref", HFILL }
8836 { &hf_gsm_a_rr_ho_ref_val,
8837 { "Handover reference value","gsm_a.rr.ho_ref_val",
8838 FT_UINT8,BASE_DEC, NULL, 0x0,
8839 "Handover reference value", HFILL }
8841 { &hf_gsm_a_rr_L2_pseudo_len,
8842 { "L2 Pseudo Length value","gsm_a.rr.rr_2_pseudo_len",
8843 FT_UINT8, BASE_DEC, NULL, 0xfc,
8844 "L2 Pseudo Length value", HFILL }
8846 { &hf_gsm_a_rr_ba_used,
8847 { "BA-USED","gsm_a.rr.ba_used",
8848 FT_UINT8, BASE_DEC, NULL, 0x00,
8851 { &hf_gsm_a_rr_dtx_used,
8852 { "DTX-USED","gsm_a.rr.dtx_used",
8853 FT_BOOLEAN, 8, TFS(&gsm_a_rr_dtx_vals), 0x00,
8856 { &hf_gsm_a_rr_3g_ba_used,
8857 { "3G-BA-USED","gsm_a.rr.3g_ba_used",
8858 FT_UINT8, BASE_DEC, NULL, 0x00,
8859 "3G-BA-USED", HFILL }
8861 { &hf_gsm_a_rr_meas_valid,
8862 { "MEAS-VALID","gsm_a.rr.meas_valid",
8863 FT_BOOLEAN,8, TFS(&gsm_a_rr_mv_vals), 0x40,
8864 "MEAS-VALID", HFILL }
8866 { &hf_gsm_a_rr_rxlev_full_serv_cell,
8867 { "RXLEV-FULL-SERVING-CELL","gsm_a.rr.rxlev_full_serv_cell",
8868 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_rxlev_vals), 0x00,
8869 "RXLEV-FULL-SERVING-CELL", HFILL }
8871 { &hf_gsm_a_rr_rxlev_sub_serv_cell,
8872 { "RXLEV-SUB-SERVING-CELL","gsm_a.rr.rxlev_sub_serv_cell",
8873 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_rxlev_vals), 0x3f,
8874 "RXLEV-SUB-SERVING-CELL", HFILL }
8876 { &hf_gsm_a_rr_rxqual_full_serv_cell,
8877 { "RXQUAL-FULL-SERVING-CELL","gsm_a.rr.rxqual_full_serv_cell",
8878 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_rxqual_vals), 0x00,
8879 "RXQUAL-FULL-SERVING-CELL", HFILL }
8881 { &hf_gsm_a_rr_rxqual_sub_serv_cell,
8882 { "RXQUAL-SUB-SERVING-CELL","gsm_a.rr.rxqual_sub_serv_cell",
8883 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_rxqual_vals), 0x0e,
8884 "RXQUAL-SUB-SERVING-CELL", HFILL }
8886 { &hf_gsm_a_rr_no_ncell_m,
8887 { "NO-NCELL-M","gsm_a.rr.no_ncell_m",
8888 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_ncell_vals), 0x00,
8889 "NO-NCELL-M", HFILL }
8891 { &hf_gsm_a_rr_rxlev_ncell,
8892 { "RXLEV-NCELL","gsm_a.rr.rxlev_ncell",
8893 FT_UINT8,BASE_DEC, NULL, 0x00,
8894 "RXLEV-NCELL", HFILL }
8896 { &hf_gsm_a_rr_bcch_freq_ncell,
8897 { "BCCH-FREQ-NCELL","gsm_a.rr.bcch_freq_ncell",
8898 FT_UINT8,BASE_DEC, NULL, 0x00,
8899 "BCCH-FREQ-NCELL", HFILL }
8901 { &hf_gsm_a_rr_bsic_ncell,
8902 { "BSIC-NCELL","gsm_a.rr.bsic_ncell",
8903 FT_UINT8,BASE_DEC, NULL, 0x00,
8904 "BSIC-NCELL", HFILL }
8906 { &hf_gsm_a_rr_mobile_time_difference,
8907 { "Mobile Timing Difference value (in half bit periods)","gsm_a.rr.mobile_time_difference",
8908 FT_UINT32,BASE_DEC, NULL, 0xFFFFF8,
8909 "Mobile Timing Difference value (in half bit periods)", HFILL }
8911 { &hf_gsm_a_rr_pow_cmd_atc,
8912 { "ATC","gsm_a.rr.pow_cmd_atc",
8913 FT_BOOLEAN,8, TFS(&gsm_a_rr_pow_cmd_atc_value), 0x80,
8916 { &hf_gsm_a_rr_page_mode,
8917 { "Page Mode","gsm_a.rr.page_mode",
8918 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_page_mode_vals), 0x03,
8919 "Page Mode", HFILL }
8921 { &hf_gsm_a_rr_dedicated_mode_or_tbf,
8922 { "Dedicated mode or TBF","gsm_a.rr.dedicated_mode_or_tbf",
8923 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_dedicated_mode_or_tbf_vals), 0x70,
8924 "Dedicated mode or TBF", HFILL }
8926 { &hf_gsm_a_rr_pow_cmd_epc,
8927 { "EPC_mode","gsm_a.rr.pow_cmd_epc",
8928 FT_BOOLEAN,8, TFS(&gsm_a_rr_pow_cmd_epc_value), 0x40,
8931 { &hf_gsm_a_rr_pow_cmd_fpcepc,
8932 { "FPC_EPC","gsm_a.rr.pow_cmd_fpcepc",
8933 FT_BOOLEAN,8, TFS(&gsm_a_rr_pow_cmd_fpcepc_value), 0x20,
8936 { &hf_gsm_a_rr_pow_cmd_powlev,
8937 { "POWER LEVEL","gsm_a.rr.pow_cmd_pow",
8938 FT_UINT8,BASE_DEC, NULL, 0x1f,
8939 "POWER LEVEL", HFILL }
8941 { &hf_gsm_a_rr_sync_ind_nci,
8942 { "Normal cell indication(NCI)","gsm_a.rr.sync_ind_nci",
8943 FT_BOOLEAN,8, TFS(&gsm_a_rr_sync_ind_nci_value), 0x08,
8944 "Normal cell indication(NCI)", HFILL }
8946 { &hf_gsm_a_rr_sync_ind_rot,
8947 { "Report Observed Time Difference(ROT)","gsm_a.rr.sync_ind_rot",
8948 FT_BOOLEAN,8, TFS(&sm_a_rr_sync_ind_rot_value), 0x04,
8949 "Report Observed Time Difference(ROT)", HFILL }
8951 { &hf_gsm_a_rr_sync_ind_si,
8952 { "Synchronization indication(SI)","gsm_a.rr_sync_ind_si",
8953 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_sync_ind_si_vals), 0x03,
8954 "Synchronization indication(SI)", HFILL }
8956 { &hf_gsm_a_rr_format_id,
8957 { "Format Identifier","gsm_a.rr_format_id",
8958 FT_UINT8,BASE_HEX, VALS(gsm_a_rr_freq_list_format_id_vals), 0xce,
8959 "Format Identifier", HFILL }
8961 { &hf_gsm_a_rr_channel_mode,
8962 { "Channel Mode","gsm_a.rr.channel_mode",
8963 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_mode_vals), 0x0,
8964 "Channel Mode", HFILL }
8966 { &hf_gsm_a_rr_channel_mode2,
8967 { "Channel Mode 2","gsm_a.rr.channel_mode2",
8968 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_mode2_vals), 0x0,
8969 "Channel Mode 2", HFILL }
8972 { "SC","gsm_a.rr.SC",
8973 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_sc_vals), 0x00,
8976 { &hf_gsm_a_algorithm_id,
8977 { "Algorithm identifier","gsm_a.algorithm_identifier",
8978 FT_UINT8,BASE_DEC, VALS(gsm_a_algorithm_identifier_vals), 0x00,
8979 "Algorithm_identifier", HFILL }
8982 { "CR","gsm_a.rr.CR",
8983 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_cr_vals), 0x00,
8986 { &hf_gsm_a_rr_multirate_speech_ver,
8987 { "Multirate speech version","gsm_a.rr.multirate_speech_ver",
8988 FT_UINT8,BASE_DEC, VALS(multirate_speech_ver_vals), 0xe0,
8989 "Multirate speech version", HFILL }
8991 { &hf_gsm_a_rr_NCSB,
8992 { "NSCB: Noise Suppression Control Bit","gsm_a.rr.NCSB",
8993 FT_UINT8,BASE_DEC, VALS(NSCB_vals), 0x10,
8994 "NSCB: Noise Suppression Control Bit", HFILL }
8996 { &hf_gsm_a_rr_ICMI,
8997 { "ICMI: Initial Codec Mode Indicator","gsm_a.rr.ICMI",
8998 FT_UINT8,BASE_DEC, VALS(ICMI_vals), 0x8,
8999 "ICMI: Initial Codec Mode Indicator", HFILL }
9001 { &hf_gsm_a_rr_start_mode,
9002 { "Start Mode","gsm_a.rr.start_mode",
9003 FT_UINT8,BASE_DEC, NULL, 0x3,
9004 "Start Mode", HFILL }
9006 { &hf_gsm_a_rr_timing_adv,
9007 { "Timing advance value","gsm_a.rr.timing_adv",
9008 FT_UINT8,BASE_DEC, NULL, 0x0,
9009 "Timing advance value", HFILL }
9011 { &hf_gsm_a_rr_time_diff,
9012 { "Time difference value","gsm_a.rr.time_diff",
9013 FT_UINT8,BASE_DEC, NULL, 0x0,
9014 "Time difference value", HFILL }
9016 { &hf_gsm_a_rr_tlli,
9017 { "TLLI","gsm_a.rr.tlli",
9018 FT_UINT32,BASE_HEX, NULL, 0x0,
9021 { &hf_gsm_a_rr_tmsi_ptmsi,
9022 { "TMSI/P-TMSI Value","gsm_a.rr.tmsi_ptmsi",
9023 FT_UINT32,BASE_HEX, NULL, 0x0,
9024 "TMSI/P-TMSI Value", HFILL }
9026 { &hf_gsm_a_rr_target_mode,
9027 { "Target mode","gsm_a.rr.target_mode",
9028 FT_UINT8,BASE_DEC, NULL, 0xc0,
9029 "Target mode", HFILL }
9031 { &hf_gsm_a_rr_wait_indication,
9032 { "Wait Indication","gsm_a.rr.wait_indication",
9033 FT_UINT8,BASE_DEC, NULL, 0x00,
9034 "Wait Indication (T3122/T3142)", HFILL }
9036 { &hf_gsm_a_rr_seq_code,
9037 { "Sequence Code","gsm_a.rr.seq_code",
9038 FT_UINT8, BASE_DEC, NULL, 0x00,
9039 "Sequence Code", HFILL }
9042 { &hf_gsm_a_rr_group_cipher_key_number,
9043 { "Group cipher key number","gsm_a.rr.Group_cipher_key_number",
9044 FT_UINT8,BASE_DEC, NULL, 0x3c,
9045 "Group cipher key number", HFILL }
9047 { &hf_gsm_a_rr_MBMS_broadcast,
9048 { "MBMS Broadcast","gsm_a.rr.MBMS_broadcast",
9049 FT_BOOLEAN,8, TFS(&gsm_a_rr_MBMS_broadcast_value), 0x01,
9050 "MBMS Broadcast", HFILL }
9052 { &hf_gsm_a_rr_MBMS_multicast,
9053 { "MBMS Multicast","gsm_a.rr.MBMS_multicast",
9054 FT_BOOLEAN,8, TFS(&gsm_a_rr_MBMS_multicast_value), 0x02,
9055 "MBMS Multicast", HFILL }
9057 { &hf_gsm_a_rr_last_segment,
9058 { "Last Segment","gsm_a.rr.last_segment",
9059 FT_BOOLEAN,8, TFS(&gsm_a_rr_last_segment_value), 0x01,
9060 "Last Segment", HFILL }
9062 { &hf_gsm_a_rr_carrier_ind,
9063 { "Carrier Indication","gsm_a.rr.carrier_ind",
9064 FT_BOOLEAN,8, TFS(&gsm_a_rr_carrier_ind_value), 0x01,
9065 "Carrier Indication", HFILL }
9068 { "Random Access Information (RA)", "gsm_a_rr_ra",
9069 FT_UINT8, BASE_DEC, NULL, 0x0,
9070 "Random Access Information (RA)", HFILL }
9072 { &hf_gsm_a_rr_T1prim,
9073 { "T1'", "gsm_a.rr.T1prim",
9074 FT_UINT8, BASE_DEC, NULL, 0xf8,
9078 { "T3", "gsm_a.rr.T3",
9079 FT_UINT16, BASE_DEC, NULL, 0x07e0,
9083 { "T2", "gsm_a.rr.T2",
9084 FT_UINT8, BASE_DEC, NULL, 0x1f,
9088 { "RFN", "gsm_a.rr.rfn",
9089 FT_UINT16, BASE_DEC, NULL, 0x0,
9090 "Reduced Frame Number", HFILL }
9092 { &hf_gsm_a_rr_RR_cause,
9093 { "RR cause value","gsm_a.rr.RRcause",
9094 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_RR_cause_vals), 0x0,
9095 "RR cause value", HFILL }
9097 { &hf_gsm_a_rr_cm_cng_msg_req,
9098 { "CLASSMARK CHANGE","gsm_a.rr_cm_cng_msg_req",
9099 FT_BOOLEAN,8, TFS(&gsm_a_msg_req_value), 0x80,
9100 "CLASSMARK CHANGE ", HFILL }
9102 { &hf_gsm_a_rr_utran_cm_cng_msg_req,
9103 { "UTRAN CLASSMARK CHANGE","gsm_a.rr_utran_cm_cng_msg_req",
9104 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_utran_cm_cng_msg_req_vals), 0x70,
9105 "UTRAN CLASSMARK CHANGE", HFILL }
9107 { &hf_gsm_a_rr_cdma200_cm_cng_msg_req,
9108 { "CDMA2000 CLASSMARK CHANGE ","gsm_a.rr_cdma200_cm_cng_msg_req",
9109 FT_BOOLEAN,8, TFS(&gsm_a_msg_req_value), 0x08,
9110 "CDMA2000 CLASSMARK CHANGE ", HFILL }
9112 { &hf_gsm_a_rr_geran_iu_cm_cng_msg_req,
9113 { "GERAN IU MODE CLASSMARK CHANGE","gsm_a.rr_geran_iu_cm_cng_msg_req",
9114 FT_BOOLEAN,8, TFS(&gsm_a_msg_req_value), 0x04,
9115 "GERAN IU MODE CLASSMARK CHANGE", HFILL }
9117 { &hf_gsm_a_rr_chnl_needed_ch1,
9118 { "Channel 1","gsm_a.rr_chnl_needed_ch1",
9119 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_needed_vals), 0x00,
9120 "Channel 1", HFILL }
9122 { &hf_gsm_a_rr_chnl_needed_ch2,
9123 { "Channel 2","gsm_a.rr_chnl_needed_ch2",
9124 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_needed_vals), 0x00,
9125 "Channel 2", HFILL }
9127 { &hf_gsm_a_rr_chnl_needed_ch3,
9128 { "Channel 3","gsm_a.rr_chnl_needed_ch3",
9129 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_needed_vals), 0x00,
9130 "Channel 3", HFILL }
9132 { &hf_gsm_a_rr_chnl_needed_ch4,
9133 { "Channel 4","gsm_a.rr_chnl_needed_ch4",
9134 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_channel_needed_vals), 0x00,
9135 "Channel 4", HFILL }
9137 { &hf_gsm_a_rr_suspension_cause,
9138 { "Suspension cause value","gsm_a.rr.suspension_cause",
9139 FT_UINT8,BASE_DEC, VALS(gsm_a_rr_suspension_cause_vals), 0x0,
9140 "Suspension cause value", HFILL }
9142 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b8,
9143 { "12,2 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b8",
9144 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x80,
9145 "12,2 kbit/s codec rate", HFILL }
9147 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b7,
9148 { "10,2 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b7",
9149 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x40,
9150 "10,2 kbit/s codec rate", HFILL }
9152 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b6,
9153 { "7,95 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b6",
9154 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x20,
9155 "7,95 kbit/s codec rate", HFILL }
9157 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b5,
9158 { "7,40 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b5",
9159 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x10,
9160 "7,40 kbit/s codec rate", HFILL }
9162 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b4,
9163 { "6,70 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b4",
9164 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x08,
9165 "6,70 kbit/s codec rate", HFILL }
9167 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b3,
9168 { "5,90 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b3",
9169 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x04,
9170 "5,90 kbit/s codec rate", HFILL }
9172 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b2,
9173 { "5,15 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b2",
9174 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x02,
9175 "5,15 kbit/s codec rate", HFILL }
9177 { &hf_gsm_a_rr_set_of_amr_codec_modes_v1_b1,
9178 { "4,75 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v1b1",
9179 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x01,
9180 "4,75 kbit/s codec rate", HFILL }
9182 { &hf_gsm_a_rr_set_of_amr_codec_modes_v2_b5,
9183 { "23,85 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v2b5",
9184 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x10,
9185 "23,85 kbit/s codec rate", HFILL }
9187 { &hf_gsm_a_rr_set_of_amr_codec_modes_v2_b4,
9188 { "15,85 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v2b4",
9189 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x08,
9190 "15,85 kbit/s codec rate", HFILL }
9192 { &hf_gsm_a_rr_set_of_amr_codec_modes_v2_b3,
9193 { "12,65 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v2b3",
9194 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x04,
9195 "12,65 kbit/s codec rate", HFILL }
9197 { &hf_gsm_a_rr_set_of_amr_codec_modes_v2_b2,
9198 { "8,85 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v2b2",
9199 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x02,
9200 "8,85 kbit/s codec rate", HFILL }
9202 { &hf_gsm_a_rr_set_of_amr_codec_modes_v2_b1,
9203 { "6,60 kbit/s codec rate", "gsm_a.rr.set_of_amr_codec_modes_v2b1",
9204 FT_BOOLEAN,8, TFS(&gsm_a_rr_set_of_amr_codec_modes), 0x01,
9205 "6,60 kbit/s codec rate", HFILL }
9207 { &hf_gsm_a_rr_amr_threshold,
9208 { "AMR Threshold", "gsm_a.rr.amr_threshold",
9209 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_amr_threshold_vals), 0x00,
9210 "AMR Threshold", HFILL }
9212 { &hf_gsm_a_rr_amr_hysteresis,
9213 { "AMR Hysteresis", "gsm_a.rr.amr_hysteresis",
9214 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_amr_hysteresis_vals), 0x00,
9215 "AMR Hysteresis", HFILL }
9217 { &hf_gsm_a_rr_pwrc,
9218 { "PWRC", "gsm_a.rr.pwrc",
9219 FT_BOOLEAN, BASE_DEC, NULL, 0x00,
9220 "Power Control Indicator (PWRC)", HFILL }
9222 { &hf_gsm_a_rr_dtx_bcch,
9223 { "DTX (BCCH)", "gsm_a.rr.dtx_bcch",
9224 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_dtx_bcch_vals), 0x30,
9225 "Discontinuous Tranmission (DTX-BCCH)", HFILL }
9227 { &hf_gsm_a_rr_dtx_sacch,
9228 { "DTX (SACCH)", "gsm_a.rr.dtx_sacch",
9229 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_dtx_sacch_vals), 0xb0,
9230 "Discontinuous Tranmission (DTX-SACCH)", HFILL }
9232 { &hf_gsm_a_rr_radio_link_timeout,
9233 { "Radio Link Timeout", "gsm_a.rr.radio_link_timeout",
9234 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_radio_link_timeout_vals), 0x0f,
9235 "Radio Link Timeout (s)", HFILL }
9237 { &hf_gsm_a_rr_cell_reselect_hyst,
9238 { "Cell Reselection Hysteresis", "gsm_a.rr.cell_reselect_hyst",
9239 FT_UINT8, BASE_DEC, NULL, 0xe0,
9240 "Cell Reslection Hysteresis (dB)", HFILL }
9242 { &hf_gsm_a_rr_ms_txpwr_max_cch,
9243 { "MS TXPWR MAX CCH", "gsm_a.rr.ms_txpwr_max_cch",
9244 FT_UINT8, BASE_DEC, NULL, 0x1f,
9245 "MS TXPWR MAX CCH", HFILL }
9248 { "ACS", "gsm_a.rr.acs",
9249 FT_BOOLEAN, 8, NULL, 0x80,
9250 "Additional Reselect Param Indicator (ACS)", HFILL }
9252 { &hf_gsm_a_rr_neci,
9253 { "NECI", "gsm_a.rr.neci",
9254 FT_UINT8, BASE_DEC, NULL, 0x40,
9255 "New Establishment Cause Indicator (NECI)", HFILL }
9257 { &hf_gsm_a_rr_rxlev_access_min,
9258 { "RXLEV-ACCESS-MIN", "gsm_a.rr.rxlev_access_min",
9259 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_rxlev_vals), 0x3f,
9260 "RXLEV-ACCESS-MIN", HFILL }
9262 { &hf_gsm_a_rr_mscr,
9263 { "MSCR", "gsm_a.rr.mscr",
9264 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_mscr_vals), 0x80,
9265 "MSC Release Indicator (MSCR)", HFILL }
9268 { "ATT", "gsm_a.rr.att",
9269 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_att_vals), 0x40,
9270 "Attach Indicator (ATT)", HFILL }
9272 { &hf_gsm_a_rr_bs_ag_blks_res,
9273 { "BS_AG_BLKS_RES", "gsm_a.rr.bs_ag_blks_res",
9274 FT_UINT8, BASE_DEC, NULL, 0x38,
9275 "Access Grant Reserved Blocks (BS_AG_BLKS_RES)", HFILL }
9277 { &hf_gsm_a_rr_ccch_conf,
9278 { "CCCH-CONF", "gsm_a.rr.ccch_conf",
9279 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_ccch_conf_vals), 0x07,
9280 "CCCH-CONF", HFILL }
9282 { &hf_gsm_a_rr_cbq3,
9283 { "CBQ3", "gsm_a.rr.cbq3",
9284 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_cbq3_vals), 0x00,
9285 "Cell Bar Qualify 3", HFILL }
9287 { &hf_gsm_a_rr_bs_pa_mfrms,
9288 { "BS-PA-MFRMS", "gsm_a.rr.bs_pa_mfrms",
9289 FT_UINT8, BASE_DEC, NULL, 0x07,
9290 "BS-PA-MFRMS", HFILL }
9292 { &hf_gsm_a_rr_t3212,
9293 { "T3212", "gsm_a.rr.t3212",
9294 FT_UINT8, BASE_DEC, NULL, 0x00,
9295 "Periodic Update period (T3212) (deci-hours)", HFILL }
9297 { &hf_gsm_a_rr_dyn_arfcn_length,
9298 { "Length of Dynamic Mapping", "gsm_a.rr.dyn_arfcn_length",
9299 FT_UINT8, BASE_DEC, NULL, 0x00,
9300 "Length of Dynamic Mapping", HFILL }
9302 { &hf_gsm_a_rr_gsm_band,
9303 { "GSM Band", "gsm_a.rr.gsm_band",
9304 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_gsm_band_vals), 0x00,
9307 { &hf_gsm_a_rr_arfcn_first,
9308 { "ARFCN First", "gsm_a.rr.arfcn_first",
9309 FT_UINT16, BASE_DEC, NULL, 0x00,
9310 "ARFCN First", HFILL }
9312 { &hf_gsm_a_rr_band_offset,
9313 { "Band Offset", "gsm_a.rr.band_offset",
9314 FT_UINT16, BASE_DEC, NULL, 0x00,
9315 "Band Offset", HFILL }
9317 { &hf_gsm_a_rr_arfcn_range,
9318 { "ARFCN Range", "gsm_a.rr.arfcn_range",
9319 FT_UINT8, BASE_DEC, NULL, 0x00,
9320 "ARFCN Range", HFILL }
9322 { &hf_gsm_a_rr_lowest_arfcn,
9323 { "Lowest ARFCN", "gsm_a.rr.lowest_arfcn",
9324 FT_UINT8, BASE_DEC, NULL, 0x7f,
9325 "Lowest ARFCN", HFILL }
9327 { &hf_gsm_a_rr_inc_skip_arfcn,
9328 { "Increment skip ARFCN", "gsm_a.rr.inc_skip_arfcn",
9329 FT_UINT8, BASE_DEC, NULL, 0x00,
9330 "Increment skip ARFCN", HFILL }
9332 { &hf_gsm_a_rr_gprs_resumption_ack,
9333 { "Ack", "gsm_a.rr.gprs_resumption_ack",
9334 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_gprs_resumption_ack_value), 0x01,
9335 "GPRS Resumption Ack bit", HFILL }
9337 { &hf_gsm_a_rr_ext_ind,
9338 { "EXT-IND", "gsm_a.rr.ext_ind",
9339 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_ext_ind_vals), 0x20,
9340 "Extension Indication (EXT-IND)", HFILL }
9342 { &hf_gsm_a_rr_ba_ind,
9343 { "BA-IND", "gsm_a.rr.ba_ind",
9344 FT_UINT8, BASE_DEC, NULL, 0x00,
9345 "BCCH Allocation Indication (BA-IND)", HFILL }
9347 { &hf_gsm_a_rr_multiband_reporting,
9348 { "Multiband Reporting", "gsm_a.rr.multiband_reporting",
9349 FT_UINT8, BASE_DEC, NULL, 0x00,
9350 "Number of cells to be reported in each band if Multiband Reporting", HFILL }
9352 { &hf_gsm_a_rr_ncc_permitted,
9353 { "NCC Permitted", "gsm_a.rr.ncc_permitted",
9354 FT_UINT8, BASE_HEX, NULL, 0xff,
9355 "NCC Permitted", HFILL }
9357 { &hf_gsm_a_rr_max_retrans,
9358 { "Max retrans", "gsm_a.rr.max_retrans",
9359 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_max_retrans_vals), 0xc0,
9360 "Maximum number of retransmissions", HFILL }
9362 { &hf_gsm_a_rr_tx_integer,
9363 { "Tx-integer", "gsm_a.rr.tx_integer",
9364 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_tx_integer_vals), 0x3c,
9365 "Number of Slots to spread Transmission (Tx-integer)", HFILL }
9367 { &hf_gsm_a_rr_cell_barr_access,
9368 { "CELL_BARR_ACCESS", "gsm_a.rr.cell_barr_access",
9369 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_cell_barr_access_vals), 0x02,
9370 "Cell Barred for Access (CELL_BARR_ACCESS)", HFILL }
9373 { "RE", "gsm_a.rr.re",
9374 FT_BOOLEAN, 8, NULL, 0x01,
9375 "Call re-establishment allowed (RE)", HFILL }
9378 { "ACC", "gsm_a.rr.acc",
9379 FT_UINT16, BASE_HEX, NULL, 0xffff,
9380 "Access Control Class N barred (ACC)", HFILL }
9382 { &hf_gsm_a_rr_nch_position,
9383 { "NCH Position", "gsm_a.rr.nch_position",
9384 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_nch_position_vals), 0x00,
9385 "NCH Position", HFILL }
9387 { &hf_gsm_a_rr_si2ter_mp_change_mark,
9388 { "SI2ter Measurement Parameter Change Mark", "gsm_a.rr.si2ter_mp_change_mark",
9389 FT_UINT8, BASE_DEC, NULL, 0x00,
9390 "SI2ter Measurement Parameter Change Mark", HFILL }
9392 { &hf_gsm_a_rr_si2ter_3g_change_mark,
9393 { "SI2ter 3G Change Mark", "gsm_a.rr.si2ter_3g_change_mark",
9394 FT_UINT8, BASE_DEC, NULL, 0x00,
9395 "SI2ter 3G Change Mark", HFILL }
9397 { &hf_gsm_a_rr_si2ter_index,
9398 { "SI2ter Index", "gsm_a.rr.si2ter_index",
9399 FT_UINT8, BASE_DEC, NULL, 0x00,
9400 "SI2ter Index", HFILL }
9402 { &hf_gsm_a_rr_si2ter_count,
9403 { "SI2ter Count", "gsm_a.rr.si2ter_count",
9404 FT_UINT8, BASE_DEC, NULL, 0x00,
9405 "SI2ter Count", HFILL }
9407 { &hf_gsm_a_rr_fdd_uarfcn,
9408 { "FDD UARFCN", "gsm_a.rr.fdd_uarfcn",
9409 FT_UINT16, BASE_DEC, NULL, 0x0000,
9410 "FDD UARFCN", HFILL }
9412 { &hf_gsm_a_rr_bandwidth_fdd,
9413 { "Bandwidth FDD", "gsm_a.rr.bandwidth_fdd",
9414 FT_UINT8, BASE_DEC, NULL, 0x00,
9415 "Bandwidth FDD", HFILL }
9417 { &hf_gsm_a_rr_tdd_uarfcn,
9418 { "TDD UARFCN", "gsm_a.rr.tdd_uarfcn",
9419 FT_UINT16, BASE_DEC, NULL, 0x0000,
9420 "TDD UARFCN", HFILL }
9422 { &hf_gsm_a_rr_bandwidth_tdd,
9423 { "Bandwidth TDD", "gsm_a.rr.bandwidth_tdd",
9424 FT_UINT8, BASE_DEC, NULL, 0x00,
9425 "Bandwidth TDD", HFILL }
9427 { &hf_gsm_a_rr_arfcn,
9428 { "ARFCN", "gsm_a.rr.arfcn",
9429 FT_UINT16, BASE_DEC, NULL, 0x0000,
9430 "Absolute Radio Frequency Channel Number (ARFCN)", HFILL }
9432 { &hf_gsm_a_rr_bsic,
9433 { "BSIC", "gsm_a.rr.bsic",
9434 FT_UINT8, BASE_DEC, NULL, 0x00,
9435 "Base Station Identify Code (BSIC)", HFILL }
9437 { &hf_gsm_a_rr_qsearch_i,
9438 { "Qsearch I", "gsm_a.rr.qsearch_i",
9439 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_qsearch_x_vals), 0x00,
9440 "Search for 3G cells if signal level is below (0 7) or above (8 15) threshold (Qsearch I)", HFILL }
9442 { &hf_gsm_a_rr_fdd_qoffset,
9443 { "FDD Qoffset", "gsm_a.rr.fdd_qoffset",
9444 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xdd_qoffset_vals), 0x00,
9445 "Offset to RLA_C for cell re selection to FDD access technology (FDD Qoffset)", HFILL }
9447 { &hf_gsm_a_rr_fdd_qmin,
9448 { "FDD Qmin", "gsm_a.rr.fdd_qmin",
9449 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_fdd_qmin_vals), 0x00,
9450 "Minimum threshold for Ec/No for UTRAN FDD cell re-selection (FDD Qmin)", HFILL }
9452 { &hf_gsm_a_rr_tdd_qoffset,
9453 { "TDD Qoffset", "gsm_a.rr.tdd_qoffset",
9454 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xdd_qoffset_vals), 0x00,
9455 "Offset to RLA_C for cell re selection to TDD access technology (TDD Qoffset)", HFILL }
9457 { &hf_gsm_a_rr_fdd_qmin_offset,
9458 { "FDD Qmin Offset", "gsm_a.rr.fdd_qmin_offset",
9459 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_fdd_qmin_offset_vals), 0x00,
9460 "Offset to FDD Qmin value (FDD Qmin Offset)", HFILL }
9462 { &hf_gsm_a_rr_fdd_rscpmin,
9463 { "FDD RSCPmin", "gsm_a.rr.fdd_rscpmin",
9464 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_fdd_rscpmin_vals), 0x00,
9465 "Minimum threshold of RSCP for UTRAN FDD cell re-selection (FDD RSCPmin)", HFILL }
9467 { &hf_gsm_a_rr_3g_ba_ind,
9468 { "3G BA-IND", "gsm_a.rr.3g_ba_ind",
9469 FT_UINT8, BASE_DEC, NULL, 0x00,
9470 "3G BCCH Allocation Indication (3G BA-IND)", HFILL }
9472 { &hf_gsm_a_rr_mp_change_mark,
9473 { "Measurement Parameter Change Mark", "gsm_a.rr.mp_change_mark",
9474 FT_UINT8, BASE_DEC, NULL, 0x00,
9475 "Measurement Parameter Change Mark", HFILL }
9477 { &hf_gsm_a_rr_si2quater_index,
9478 { "SI2quater Index", "gsm_a.rr.si2quater_index",
9479 FT_UINT8, BASE_DEC, NULL, 0x00,
9480 "SI2quater Index", HFILL }
9482 { &hf_gsm_a_rr_si2quater_count,
9483 { "SI2quater Count", "gsm_a.rr.si2quater_count",
9484 FT_UINT8, BASE_DEC, NULL, 0x00,
9485 "SI2quater Count", HFILL }
9487 { &hf_gsm_a_rr_gsm_report_type,
9488 { "Report Type", "gsm_a.rr.gsm_report_type",
9489 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_gsm_report_type_value), 0x00,
9490 "Report type the MS shall use (Report Type)", HFILL }
9492 { &hf_gsm_a_rr_serving_band_reporting,
9493 { "Serving Band Reporting", "gsm_a.rr.serving_band_reporting",
9494 FT_UINT8, BASE_DEC, NULL, 0x00,
9495 "Number of cells reported from the GSM serving frequency band (Serving Band Reporting)", HFILL }
9497 { &hf_gsm_a_rr_frequency_scrolling,
9498 { "Frequency Scrolling", "gsm_a.rr.frequency_scrolling",
9499 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_frequency_scrolling_value), 0x00,
9500 "Frequency Scrolling", HFILL }
9502 { &hf_gsm_a_rr_rep_priority,
9503 { "Rep Priority", "gsm_a.rr.rep_priority",
9504 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_rep_priority_value), 0x00,
9505 "Reporting Priority", HFILL }
9507 { &hf_gsm_a_rr_report_type,
9508 { "Report Type", "gsm_a.rr.report_type",
9509 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_report_type_value), 0x00,
9510 "Report Type", HFILL }
9512 { &hf_gsm_a_rr_reporting_rate,
9513 { "Reporting Rate", "gsm_a.rr.reporting_rate",
9514 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_reporting_rate_value), 0x00,
9515 "Reporting Rate", HFILL }
9517 { &hf_gsm_a_rr_invalid_bsic_reporting,
9518 { "Invalid BSIC Reporting", "gsm_a.rr.invalid_bsic_reporting",
9519 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_invalid_bsic_reporting_value), 0x00,
9520 "Invalid BSIC Reporting", HFILL }
9522 { &hf_gsm_a_rr_scale_ord,
9523 { "Scale Ord", "gsm_a.rr.scale_ord",
9524 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_scale_ord_vals), 0x00,
9525 "Offset used for the reported RXLEV values (Scale Ord)", HFILL }
9527 { &hf_gsm_a_rr_900_reporting_offset,
9528 { "900 Reporting Offset", "gsm_a.rr.900_reporting_offset",
9529 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9530 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 900 (900 Reporting Offset)", HFILL }
9532 { &hf_gsm_a_rr_900_reporting_threshold,
9533 { "900 Reporting Threshold", "gsm_a.rr.900_reporting_threshold",
9534 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9535 "Apply priority reporting if the reported value is above threshold for GSM frequency band 900 (900 Reporting Threshold)", HFILL }
9537 { &hf_gsm_a_rr_1800_reporting_offset,
9538 { "1800 Reporting Offset", "gsm_a.rr.1800_reporting_offset",
9539 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9540 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 1800 (1800 Reporting Offset)", HFILL }
9542 { &hf_gsm_a_rr_1800_reporting_threshold,
9543 { "1800 Reporting Threshold", "gsm_a.rr.1800_reporting_threshold",
9544 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9545 "Apply priority reporting if the reported value is above threshold for GSM frequency band 1800 (1800 Reporting Threshold)", HFILL }
9547 { &hf_gsm_a_rr_400_reporting_offset,
9548 { "400 Reporting Offset", "gsm_a.rr.400_reporting_offset",
9549 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9550 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 400 (400 Reporting Offset)", HFILL }
9552 { &hf_gsm_a_rr_400_reporting_threshold,
9553 { "400 Reporting Threshold", "gsm_a.rr.400_reporting_threshold",
9554 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9555 "Apply priority reporting if the reported value is above threshold for GSM frequency band 400 (400 Reporting Threshold)", HFILL }
9557 { &hf_gsm_a_rr_1900_reporting_offset,
9558 { "1900 Reporting Offset", "gsm_a.rr.1900_reporting_offset",
9559 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9560 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 1900 (1900 Reporting Offset)", HFILL }
9562 { &hf_gsm_a_rr_1900_reporting_threshold,
9563 { "1900 Reporting Threshold", "gsm_a.rr.1900_reporting_threshold",
9564 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9565 "Apply priority reporting if the reported value is above threshold for GSM frequency band 1900 (1900 Reporting Threshold)", HFILL }
9567 { &hf_gsm_a_rr_850_reporting_offset,
9568 { "850 Reporting Offset", "gsm_a.rr.850_reporting_offset",
9569 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9570 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 850 (850 Reporting Offset)", HFILL }
9572 { &hf_gsm_a_rr_850_reporting_threshold,
9573 { "850 Reporting Threshold", "gsm_a.rr.900_reporting_threshold",
9574 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9575 "Apply priority reporting if the reported value is above threshold for GSM frequency band 850 (850 Reporting Threshold)", HFILL }
9577 { &hf_gsm_a_rr_network_control_order,
9578 { "Network Control Order", "gsm_a.rr.network_control_order",
9579 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_network_control_order_vals), 0x00,
9580 "Network Control Order", HFILL }
9582 { &hf_gsm_a_rr_nc_non_drx_period,
9583 { "NC Non DRX Period", "gsm_a.rr.nc_non_drx_period",
9584 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_nc_non_drx_period_vals), 0x00,
9585 "NC Non DRX Period", HFILL }
9587 { &hf_gsm_a_rr_nc_reporting_period_i,
9588 { "NC Reporting Period I", "gsm_a.rr.nc_reporting_period_i",
9589 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_nc_reporting_period_x_vals), 0x00,
9590 "NC Reporting Period in Packet Idle mode (NC Reporting Period I)", HFILL }
9592 { &hf_gsm_a_rr_nc_reporting_period_t,
9593 { "NC Reporting Period T", "gsm_a.rr.nc_reporting_period_t",
9594 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_nc_reporting_period_x_vals), 0x00,
9595 "NC Reporting Period in Packet Transfer mode (NC Reporting Period T)", HFILL }
9597 { &hf_gsm_a_rr_index_start_3g,
9598 { "Index Start 3G", "gsm_a.rr.index_start_3g",
9599 FT_UINT8, BASE_DEC, NULL, 0x00,
9600 "Index Start 3G", HFILL }
9602 { &hf_gsm_a_rr_absolute_index_start_emr,
9603 { "Absolute Index Start EMR", "gsm_a.rr.absolute_index_start_emr",
9604 FT_UINT8, BASE_DEC, NULL, 0x00,
9605 "Absolute Index Start EMR", HFILL }
9607 { &hf_gsm_a_rr_qsearch_c_initial,
9608 { "QSearch C Initial", "gsm_a.rr.qsearch_c_initial",
9609 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_qsearch_c_initial_value), 0x00,
9610 "Qsearch value to be used in connected mode before Qsearch C is received (QSearch C Initial)", HFILL }
9612 { &hf_gsm_a_rr_fdd_rep_quant,
9613 { "FDD Rep Quant", "gsm_a.rr.fdd_rep_quant",
9614 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_fdd_rep_quant_value), 0x00,
9615 "FDD Reporting Quantity (FDD Rep Quant)", HFILL }
9617 { &hf_gsm_a_rr_fdd_multirat_reporting,
9618 { "FDD Multirat Reporting", "gsm_a.rr.fdd_multirat_reporting",
9619 FT_UINT8, BASE_DEC, NULL, 0x00,
9620 "Number of cells from the FDD access technology that shall be included in the list of strongest cells or in the measurement report (FDD Multirat Reporting)", HFILL }
9622 { &hf_gsm_a_rr_tdd_multirat_reporting,
9623 { "TDD Multirat Reporting", "gsm_a.rr.tdd_multirat_reporting",
9624 FT_UINT8, BASE_DEC, NULL, 0x00,
9625 "Number of cells from the TDD access technology that shall be included in the list of strongest cells or in the measurement report (TDD Multirat Reporting)", HFILL }
9627 { &hf_gsm_a_rr_qsearch_p,
9628 { "Qsearch P", "gsm_a.rr.qsearch_p",
9629 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_qsearch_x_vals), 0x00,
9630 "Search for 3G cells if signal level below threshold (Qsearch P)", HFILL }
9632 { &hf_gsm_a_rr_3g_search_prio,
9633 { "3G Search Prio", "gsm_a.rr.3g_search_prio",
9634 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_3g_search_prio_value), 0x00,
9635 "3G Search Priority", HFILL }
9637 { &hf_gsm_a_rr_fdd_reporting_offset,
9638 { "FDD Reporting Offset", "gsm_a.rr.fdd_reporting_offset",
9639 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9640 "Offset to the reported value when prioritising the cells for reporting for FDD access technology (FDD Reporting Offset)", HFILL }
9642 { &hf_gsm_a_rr_fdd_reporting_threshold,
9643 { "FDD Reporting Threshold", "gsm_a.rr.fdd_reporting_threshold",
9644 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9645 "Apply priority reporting if the reported value is above threshold for FDD access technology (FDD Reporting Threshold)", HFILL }
9647 { &hf_gsm_a_rr_tdd_reporting_offset,
9648 { "TDD Reporting Offset", "gsm_a.rr.tdd_reporting_offset",
9649 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9650 "Offset to the reported value when prioritising the cells for reporting for TDD access technology (TDD Reporting Offset)", HFILL }
9652 { &hf_gsm_a_rr_tdd_reporting_threshold,
9653 { "TDD Reporting Threshold", "gsm_a.rr.tdd_reporting_threshold",
9654 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9655 "Apply priority reporting if the reported value is above threshold for TDD access technology (TDD Reporting Threshold)", HFILL }
9657 { &hf_gsm_a_rr_fdd_reporting_threshold_2,
9658 { "FDD Reporting Threshold 2", "gsm_a.rr.fdd_reporting_threshold_2",
9659 FT_UINT8, BASE_DEC, NULL, 0x00,
9660 "Reporting threshold for the CPICH parameter (Ec/No or RSCP) that is not reported according to FDD_REP_QUANT (FDD Reporting Threshold 2)", HFILL }
9662 { &hf_gsm_a_rr_3g_ccn_active,
9663 { "3G CCN Active", "gsm_a.rr.3g_ccn_active",
9664 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_3g_ccn_active_value), 0x00,
9665 "3G CCN Active", HFILL }
9667 { &hf_gsm_a_rr_700_reporting_offset,
9668 { "700 Reporting Offset", "gsm_a.rr.700_reporting_offset",
9669 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9670 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 700 (700 Reporting Offset)", HFILL }
9672 { &hf_gsm_a_rr_700_reporting_threshold,
9673 { "700 Reporting Threshold", "gsm_a.rr.700_reporting_threshold",
9674 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9675 "Apply priority reporting if the reported value is above threshold for GSM frequency band 700 (700 Reporting Threshold)", HFILL }
9677 { &hf_gsm_a_rr_810_reporting_offset,
9678 { "810 Reporting Offset", "gsm_a.rr.810_reporting_offset",
9679 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_offset_vals), 0x00,
9680 "Offset to the reported value when prioritising the cells for reporting for GSM frequency band 810 (810 Reporting Offset)", HFILL }
9682 { &hf_gsm_a_rr_810_reporting_threshold,
9683 { "810 Reporting Threshold", "gsm_a.rr.810_reporting_threshold",
9684 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_xxx_reporting_threshold_vals), 0x00,
9685 "Apply priority reporting if the reported value is above threshold for GSM frequency band 810 (810 Reporting Threshold)", HFILL }
9688 { "CBQ", "gsm_a.rr.cbq",
9689 FT_UINT8, BASE_DEC, NULL, 0x00,
9690 "Cell Bar Qualify", HFILL }
9692 { &hf_gsm_a_rr_cell_reselect_offset,
9693 { "Cell Reselect Offset", "gsm_a.rr.cell_reselect_offset",
9694 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_cell_reselect_offset_vals), 0x00,
9695 "Offset to the C2 reselection criterion (Cell Reselect Offset)", HFILL }
9697 { &hf_gsm_a_rr_temporary_offset,
9698 { "Temporary Offset", "gsm_a.rr.temporary_offset",
9699 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_temporary_offset_vals), 0x0,
9700 "Negative offset to C2 for the duration of Penalty Time (Temporary Offset)", HFILL }
9702 { &hf_gsm_a_rr_penalty_time,
9703 { "Penalty Time", "gsm_a.rr.penalty_time",
9704 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_penalty_time_vals), 0x0,
9705 "Duration for which the temporary offset is applied (Penalty Time)", HFILL }
9707 { &hf_gsm_a_rr_si13_position,
9708 { "SI13 Position", "gsm_a.rr.si13_position",
9709 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_si13_position_vals), 0x0,
9710 "SI13 Position", HFILL }
9712 { &hf_gsm_a_rr_power_offset,
9713 { "Power Offset", "gsm_a.rr.power_offset",
9714 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_power_offset_vals), 0x0,
9715 "Power offset used in conjunction with the MS TXPWR MAX CCH parameter by the class 3 DCS 1800 MS (Power Offset)", HFILL }
9717 { &hf_gsm_a_rr_si2quater_position,
9718 { "SI2quater Position", "gsm_a.rr.si2quater_position",
9719 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_si2quater_position_value), 0x0,
9720 "SI2quater Position", HFILL }
9722 { &hf_gsm_a_rr_si13alt_position,
9723 { "SI13alt Position", "gsm_a.rr.si13alt_position",
9724 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_si13alt_position_value), 0x0,
9725 "SI13alt Position", HFILL }
9727 { &hf_gsm_a_rr_prio_thr,
9728 { "Prio Thr", "gsm_a.rr.prio_thr",
9729 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_prio_thr_vals), 0x0,
9730 "Prio signal strength threshold is related to RXLEV ACCESS_MIN (Prio Thr)", HFILL }
9732 { &hf_gsm_a_rr_lsa_offset,
9733 { "LSA Offset", "gsm_a.rr.lsa_offset",
9734 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_lsa_offset_vals), 0x0,
9735 "Offset to be used for LSA cell re selection between cells with the same LSA priorities (LSA Offset)", HFILL }
9737 { &hf_gsm_a_rr_paging_channel_restructuring,
9738 { "Paging Channel Restructuring", "gsm_a.rr.paging_channel_restructuring",
9739 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_paging_channel_restructuring_value), 0x0,
9740 "Paging Channel Restructuring", HFILL }
9742 { &hf_gsm_a_rr_nln_sacch,
9743 { "NLN (SACCH)", "gsm_a.rr.nln_sacch",
9744 FT_UINT8, BASE_DEC, NULL, 0x0,
9745 "NLN (SACCH)", HFILL }
9747 { &hf_gsm_a_rr_nln_status_sacch,
9748 { "NLN Status (SACCH)", "gsm_a.rr.nln_status_sacch",
9749 FT_UINT8, BASE_DEC, NULL, 0x0,
9750 "NLN Status (SACCH)", HFILL }
9752 { &hf_gsm_a_rr_nln_pch,
9753 { "NLN (PCH)", "gsm_a.rr.nln_pch",
9754 FT_UINT8, BASE_DEC, NULL, 0x0,
9755 "NLN (PCH)", HFILL }
9757 { &hf_gsm_a_rr_nln_status_pch,
9758 { "NLN Status (PCH)", "gsm_a.rr.nln_status_pch",
9759 FT_UINT8, BASE_DEC, NULL, 0x0,
9760 "NLN Status (PCH)", HFILL }
9762 { &hf_gsm_a_rr_vbs_vgcs_inband_notifications,
9763 { "Inband Notifications", "gsm_a.rr.vbs_vgcs_inband_notifications",
9764 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_vbs_vgcs_inband_notifications_value), 0x0,
9765 "Inband Notifications", HFILL }
9767 { &hf_gsm_a_rr_vbs_vgcs_inband_pagings,
9768 { "Inband Pagings", "gsm_a.rr.vbs_vgcs_inband_pagings",
9769 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_vbs_vgcs_inband_pagings_value), 0x0,
9770 "Inband Pagings", HFILL }
9773 { "RAC", "gsm_a.rr.rac",
9774 FT_UINT8, BASE_DEC, NULL, 0x0,
9775 "Routeing Area Code", HFILL }
9777 { &hf_gsm_a_rr_max_lapdm,
9778 { "Max LAPDm", "gsm_a.rr.max_lapdm",
9779 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_max_lapdm_vals), 0x0,
9780 "Maximum number of LAPDm frames on which a layer 3 can be segmented into and be sent on the main DCCH (Max LAPDm)", HFILL }
9782 { &hf_gsm_a_rr_gprs_ms_txpwr_max_ccch,
9783 { "GPRS MS TxPwr Max CCH", "gsm_a.rr.gprs_ms_txpwr_max_cch",
9784 FT_UINT8, BASE_DEC, NULL, 0x00,
9785 "GPRS MS TxPwr Max CCH", HFILL }
9787 { &hf_gsm_a_rr_dedicated_mode_mbms_notification_support,
9788 { "Dedicated Mode MBMS Notification Support", "gsm_a.rr.dedicated_mode_mbms_notification_support",
9789 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_dedicated_mode_mbms_notification_support_value), 0x0,
9790 "Dedicated Mode MBMS Notification Support", HFILL }
9792 { &hf_gsm_a_rr_mnci_support,
9793 { "MNCI Support", "gsm_a.rr.mnci_support",
9794 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_mnci_support_value), 0x0,
9795 "MBMS Neighbouring Cell Information Support (MNCI Support)", HFILL }
9797 { &hf_gsm_a_rr_amr_config,
9798 { "AMR Configuration", "gsm_a.rr.amr_config",
9799 FT_UINT8, BASE_DEC, NULL, 0x0,
9800 "AMR Configuration", HFILL }
9802 { &hf_gsm_a_rr_bcch_change_mark,
9803 { "BCCH Change Mark", "gsm_a.rr.bcch_change_mark",
9804 FT_UINT8, BASE_DEC, NULL, 0x0,
9805 "BCCH Change Mark", HFILL }
9807 { &hf_gsm_a_rr_si_change_field,
9808 { "SI Change Field", "gsm_a.rr.si_change_field",
9809 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_si_change_field_vals), 0x0,
9810 "SI Change Field", HFILL }
9812 { &hf_gsm_a_rr_si13_change_mark,
9813 { "SI13 Change Mark", "gsm_a.rr.si13_change_mark",
9814 FT_UINT8, BASE_DEC, NULL, 0x0,
9815 "SI13 Change Mark", HFILL }
9818 { "HSN", "gsm_a.rr.hsn",
9819 FT_UINT8, BASE_DEC, NULL, 0x0,
9820 "Hopping Sequence Number (HSN)", HFILL }
9822 { &hf_gsm_a_rr_rfl_number,
9823 { "RFL Number", "gsm_a.rr.rfl_number",
9824 FT_UINT8, BASE_DEC, NULL, 0x0,
9825 "Radio Frequency List Number (RFL Number)", HFILL }
9827 { &hf_gsm_a_rr_arfcn_index,
9828 { "ARFCN Index", "gsm_a.rr.arfcn_index",
9829 FT_UINT8, BASE_DEC, NULL, 0x0,
9830 "ARFCN Index", HFILL }
9832 { &hf_gsm_a_rr_ma_length,
9833 { "MA Length", "gsm_a.rr.ma_length",
9834 FT_UINT8, BASE_DEC, NULL, 0x0,
9835 "Mobile Allocation Length (MA Length)", HFILL }
9837 { &hf_gsm_a_rr_psi1_repeat_period,
9838 { "PSI1 Repeat Period", "gsm_a.rr.psi1_repeat_period",
9839 FT_UINT8, BASE_DEC, VALS(&gsm_a_rr_psi1_repeat_period_vals), 0x0,
9840 "PSI1 Repeat Period", HFILL }
9842 { &hf_gsm_a_rr_pbcch_pb,
9843 { "Pb", "gsm_a.rr.pbcch_pb",
9844 FT_UINT8, BASE_DEC, VALS(&gsm_a_rr_pbcch_pb_vals), 0x0,
9845 "Power reduction on PBCCH/PCCCH (Pb)", HFILL }
9847 { &hf_gsm_a_rr_pbcch_tsc,
9848 { "TSC", "gsm_a.rr.pbcch_tsc",
9849 FT_UINT8, BASE_DEC, NULL, 0x0,
9850 "Training Sequence Code for PBCCH (TSC)", HFILL }
9852 { &hf_gsm_a_rr_pbcch_tn,
9853 { "TN", "gsm_a.rr.pbcch_tn",
9854 FT_UINT8, BASE_DEC, NULL, 0x0,
9855 "Timeslot Number for PCCH (TN)", HFILL }
9857 { &hf_gsm_a_rr_spgc_ccch_sup,
9858 { "SPGC CCCH Sup", "gsm_a.rr.spgc_ccch_sup",
9859 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_spgc_ccch_sup_value), 0x0,
9860 "Split PG Cycle Code on CCCH Support (SPGC CCCH Sup)", HFILL }
9862 { &hf_gsm_a_rr_priority_access_thr,
9863 { "Priority Access Thr", "gsm_a.rr.priority_access_thr",
9864 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_priority_access_thr_vals), 0x0,
9865 "Priority Access Threshold for packet access (Priority Access Thr)", HFILL }
9868 { "NMO", "gsm_a.rr.nmo",
9869 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_nmo_vals), 0x0,
9870 "Network mode of Operation (NMO)", HFILL }
9872 { &hf_gsm_a_rr_t3168,
9873 { "T3168", "gsm_a.rr.t3168",
9874 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_t3168_vals), 0x0,
9877 { &hf_gsm_a_rr_t3192,
9878 { "T3192", "gsm_a.rr.t3192",
9879 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_t3192_vals), 0x0,
9882 { &hf_gsm_a_rr_drx_timer_max,
9883 { "DRX Timer Max", "gsm_a.rr.drx_timer_max",
9884 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_drx_timer_max_vals), 0x0,
9885 "Discontinous Reception Timer Max (DRX Timer Max)", HFILL }
9887 { &hf_gsm_a_rr_access_burst_type,
9888 { "Access Burst Type", "gsm_a.rr.access_burst_type",
9889 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_access_burst_type_value), 0x0,
9890 "Format used in the PACKET CHANNEL REQUEST message, the PS HANDOVER ACCESS message, the PTCCH uplink block and in the PACKET CONTROL ACKNOWLEDGMENT message (Access Burst Type)", HFILL }
9892 { &hf_gsm_a_rr_control_ack_type,
9893 { "Control Ack Type", "gsm_a.rr.control_ack_type",
9894 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_control_ack_type_value), 0x0,
9895 "Default format of the PACKET CONTROL ACKNOWLEDGMENT message (Control Ack Type)", HFILL }
9897 { &hf_gsm_a_rr_bs_cv_max,
9898 { "BS CV Max", "gsm_a.rr.bs_cv_max",
9899 FT_UINT8, BASE_DEC, NULL, 0x0,
9900 "Base Station Countdown Value Maximum (BS CV Max)", HFILL }
9902 { &hf_gsm_a_rr_pan_dec,
9903 { "PAN Dec", "gsm_a.rr.pan_dec",
9904 FT_UINT8, BASE_DEC, NULL, 0x0,
9907 { &hf_gsm_a_rr_pan_inc,
9908 { "PAN Inc", "gsm_a.rr.pan_inc",
9909 FT_UINT8, BASE_DEC, NULL, 0x0,
9912 { &hf_gsm_a_rr_pan_max,
9913 { "PAN Max", "gsm_a.rr.pan_max",
9914 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_pan_max_vals), 0x0,
9917 { &hf_gsm_a_rr_egprs_packet_channel_request,
9918 { "EGPRS Packet Channel Request", "gsm_a.rr.egprs_packet_channel_request",
9919 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_egprs_packet_channel_request_value), 0x0,
9920 "EGPRS Packet Channel Request", HFILL }
9922 { &hf_gsm_a_rr_bep_period,
9923 { "BEP Period", "gsm_a.rr.bep_period",
9924 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_bep_period_vals), 0x0,
9925 "BEP Period", HFILL }
9927 { &hf_gsm_a_rr_pfc_feature_mode,
9928 { "PFC Feature Mode", "gsm_a.rr.pfc_feature_mode",
9929 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_pfc_feature_mode_value), 0x0,
9930 "Packet Flow Context Feature Mode (PFC Feature Mode)", HFILL }
9932 { &hf_gsm_a_rr_dtm_support,
9933 { "DTM Support", "gsm_a.rr.dtm_support",
9934 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_dtm_support_value), 0x0,
9935 "Dual Transfer Mode Support (DTM Support)", HFILL }
9937 { &hf_gsm_a_rr_bss_paging_coordination,
9938 { "BSS Paging Coordination", "gsm_a.rr.bss_paging_coordination",
9939 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_bss_paging_coordination_value), 0x0,
9940 "BSS Paging Coordination", HFILL }
9942 { &hf_gsm_a_rr_ccn_active,
9943 { "CCN Active", "gsm_a.rr.ccn_active",
9944 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_ccn_active_value), 0x0,
9945 "CCN Active", HFILL }
9947 { &hf_gsm_a_rr_nw_ext_utbf,
9948 { "NW Ext UTBF", "gsm_a.rr.nw_ext_utbf",
9949 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_nw_ext_utbf_value), 0x0,
9950 "Network Extended Uplink TBF (NW Ext UTBF)", HFILL }
9952 { &hf_gsm_a_rr_multiple_tbf_capability,
9953 { "Multiple TBF Capability", "gsm_a.rr.multiple_tbf_capability",
9954 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_multiple_tbf_capability_value), 0x0,
9955 "Multiple TBF Capability", HFILL }
9957 { &hf_gsm_a_rr_ext_utbf_no_data,
9958 { "Ext UTBF No Data", "gsm_a.rr.ext_utbf_no_data",
9959 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_ext_utbf_no_data_value), 0x0,
9960 "Ext UTBF No Data", HFILL }
9962 { &hf_gsm_a_rr_dtm_enhancements_capability,
9963 { "DTM Enhancements Capability", "gsm_a.rr.dtm_enhancements_capability",
9964 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_dtm_enhancements_capability_value), 0x0,
9965 "DTM Enhancements Capability", HFILL }
9967 { &hf_gsm_a_rr_reduced_latency_access,
9968 { "Reduced Latency Access", "gsm_a.rr.reduced_latency_access",
9969 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_reduced_latency_access_value), 0x0,
9970 "Reduced Latency Access", HFILL }
9972 { &hf_gsm_a_rr_alpha,
9973 { "Alpha", "gsm_a.rr.alpha",
9974 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_alpha_vals), 0x0,
9975 "Alpha parameter for GPR MS output power control (Alpha)", HFILL }
9977 { &hf_gsm_a_rr_t_avg_w,
9978 { "T Avg W", "gsm_a.rr.t_avg_w",
9979 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_t_avg_x_vals), 0x0,
9980 "Signal strength filter period for power control in packet idle mode ", HFILL }
9982 { &hf_gsm_a_rr_t_avg_t,
9983 { "T Avg T", "gsm_a.rr.t_avg_t",
9984 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_t_avg_x_vals), 0x0,
9985 "Signal strength filter period for power control in packet transfer mode ", HFILL }
9987 { &hf_gsm_a_rr_pc_meas_chan,
9988 { "PC Meas Chan", "gsm_a.rr.pc_meas_chan",
9989 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_pc_meas_chan_value), 0x0,
9990 "Channel used to measure the received power level on the downlink for the purpose of the uplink power control (PC Meas Chan)", HFILL }
9992 { &hf_gsm_a_rr_n_avg_i,
9993 { "N Avg I", "gsm_a.rr.n_avg_i",
9994 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_n_avg_i_vals), 0x0,
9995 "Interfering signal strength filter constant for power control (N Avg I)", HFILL }
9997 { &hf_gsm_a_rr_sgsnr,
9998 { "SGSNR", "gsm_a.rr.sgsnr",
9999 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_sgsnr_value), 0x0,
10000 "SGSN Release (SGSNR)", HFILL }
10002 { &hf_gsm_a_rr_si_status_ind,
10003 { "SI Status Ind", "gsm_a.rr.si_status_ind",
10004 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_si_status_ind_value), 0x0,
10005 "SI Status Ind", HFILL }
10007 { &hf_gsm_a_rr_lb_ms_txpwr_max_cch,
10008 { "LB MS TxPwr Max CCCH", "gsm_a.rr.n_avg_i",
10009 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_n_avg_i_vals), 0x0,
10010 "Maximum TX power level an MS is allowed to use on all other than DCS 1800 and PCS 1900 frequency bands when accessing the system until otherwise commanded (LB MS TxPwr Max CCCH)", HFILL }
10012 { &hf_gsm_a_rr_si2n_support,
10013 { "SI2n Support", "gsm_a.rr.si2n_support",
10014 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_si2n_support_vals), 0x0,
10015 "SI2n Support", HFILL }
10017 { &hf_gsm_a_rr_mi_index,
10018 { "Measurement Information Index", "gsm_a.rr.mi_index",
10019 FT_UINT8, BASE_DEC, NULL, 0x0,
10020 "Measurement Information Index", HFILL }
10022 { &hf_gsm_a_rr_mi_count,
10023 { "Measurement Information Count", "gsm_a.rr.mi_count",
10024 FT_UINT8, BASE_DEC, NULL, 0x0,
10025 "Measurement Information Count", HFILL }
10027 { &hf_gsm_a_rr_3g_wait,
10028 { "3G Wait", "gsm_a.rr.3g_wait",
10029 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_3g_wait_vals), 0x0,
10032 { &hf_gsm_a_rr_qsearch_c,
10033 { "Qsearch C", "gsm_a.rr.qsearch_c",
10034 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_qsearch_x_vals), 0x00,
10035 "Search for 3G cells if signal level is below (0 7) or above (8 15) threshold (Qsearch C)", HFILL }
10037 { &hf_gsm_a_rr_bsic_seen,
10038 { "BSIC Seen", "gsm_a.rr.bsic_seen",
10039 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_bsic_seen_value), 0x00,
10040 "BSIC Seen", HFILL }
10042 { &hf_gsm_a_rr_scale,
10043 { "Scale", "gsm_a.rr.scale",
10044 FT_BOOLEAN, BASE_DEC, TFS(&gsm_a_rr_scale_value), 0x00,
10045 "Offset applied for the reported RXLEV values (Scale)", HFILL }
10047 { &hf_gsm_a_rr_mean_bep_gmsk,
10048 { "Mean BEP GMSK", "gsm_a.rr.mean_bep_gmsk",
10049 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_mean_bep_gmsk_vals), 0x00,
10050 "Mean Bit Error Probability in GMSK (Mean BEP GMSK)", HFILL }
10052 { &hf_gsm_a_rr_mean_cv_bep,
10053 { "CV BEP", "gsm_a.rr.cv_bep",
10054 FT_UINT8, BASE_DEC, VALS(gsm_a_rr_cv_bep_vals), 0x00,
10055 "Coefficient of Variation of the Bit Error Probability (CV BEP)", HFILL }
10057 { &hf_gsm_a_rr_nbr_rcvd_blocks,
10058 { "Nb Rcvd Blocks", "gsm_a.rr.nbr_rcvd_blocks",
10059 FT_UINT8, BASE_DEC, NULL, 0x00,
10060 "Number of correctly decoded blocks that were completed during the measurement report period (Nb Rcvd Blocks)", HFILL }
10062 { &hf_gsm_a_rr_reporting_quantity,
10063 { "Reporting Quantity", "gsm_a.rr.reporting_quantity",
10064 FT_UINT8, BASE_DEC, NULL, 0x00,
10065 "Reporting Quantity", HFILL }
10069 static hf_register_info hf_sacch[] =
10071 { &hf_gsm_a_sacch_msg_rr_type,
10072 { "SACCH Radio Resources Management Message Type", "gsm_a.sacch_msg_rr_type",
10073 FT_UINT8, BASE_HEX, VALS(gsm_a_sacch_msg_rr_strings), 0x0,
10078 /* Setup protocol subtree array */
10079 #define NUM_INDIVIDUAL_ELEMS 3
10080 static gint *ett[NUM_INDIVIDUAL_ELEMS +
10081 NUM_GSM_DTAP_MSG_RR +
10083 NUM_GSM_RR_REST_OCTETS_ELEM +
10084 NUM_GSM_SACCH_MSG_RR];
10086 ett[0] = &ett_ccch_msg;
10087 ett[1] = &ett_ccch_oct_1;
10088 ett[2] = &ett_sacch_msg;
10090 last_offset = NUM_INDIVIDUAL_ELEMS;
10092 for (i=0; i < NUM_GSM_DTAP_MSG_RR; i++, last_offset++)
10094 ett_gsm_dtap_msg_rr[i] = -1;
10095 ett[last_offset] = &ett_gsm_dtap_msg_rr[i];
10098 for (i=0; i < NUM_GSM_RR_ELEM; i++, last_offset++)
10100 ett_gsm_rr_elem[i] = -1;
10101 ett[last_offset] = &ett_gsm_rr_elem[i];
10104 for (i=0; i < NUM_GSM_RR_REST_OCTETS_ELEM; i++, last_offset++)
10106 ett_gsm_rr_rest_octets_elem[i] = -1;
10107 ett[last_offset] = &ett_gsm_rr_rest_octets_elem[i];
10110 for (i=0; i < NUM_GSM_SACCH_MSG_RR; i++, last_offset++)
10112 ett_gsm_sacch_msg_rr[i] = -1;
10113 ett[last_offset] = &ett_gsm_sacch_msg_rr[i];
10116 /* Register the protocol name and description */
10118 proto_register_protocol("GSM CCCH", "GSM CCCH", "gsm_a_ccch");
10120 proto_register_field_array(proto_a_ccch, hf, array_length(hf));
10122 proto_register_subtree_array(ett, array_length(ett));
10124 /* subdissector code */
10125 register_dissector("gsm_a_ccch", dissect_ccch, proto_a_ccch);
10127 /* Register the protocol name and description */
10129 proto_register_protocol("GSM SACCH", "GSM SACCH", "gsm_a_sacch");
10131 proto_register_field_array(proto_a_sacch, hf_sacch, array_length(hf_sacch));
10133 proto_register_subtree_array(ett, array_length(ett));
10135 /* subdissector code */
10136 register_dissector("gsm_a_sacch", dissect_sacch, proto_a_sacch);
10140 proto_reg_handoff_gsm_a_rr(void)
10142 rrc_irat_ho_info_handle = find_dissector("rrc.irat.irat_ho_info");
10143 rrc_irat_ho_to_utran_cmd_handle = find_dissector("rrc.irat.ho_to_utran_cmd");