Wireshark 5.1.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
packet-umts_fp.h
1/* packet-umts_fp.h
2 *
3 * Martin Mathieson
4 * Wireshark - Network traffic analyzer
5 * By Gerald Combs <gerald@wireshark.org>
6 * Copyright 1998 Gerald Combs
7 *
8 * SPDX-License-Identifier: GPL-2.0-or-later
9 */
10
11#include <epan/conversation.h>
12
13/* Channel types */
14#define CHANNEL_UNKNOWN 0
15#define CHANNEL_RACH_FDD 1
16#define CHANNEL_RACH_TDD 2
17#define CHANNEL_FACH_FDD 3
18#define CHANNEL_FACH_TDD 4
19#define CHANNEL_DSCH_FDD 5 /* DSCH Downlink Shared Channel */
20#define CHANNEL_DSCH_TDD 6
21#define CHANNEL_USCH_TDD_384 8
22#define CHANNEL_USCH_TDD_128 24
23#define CHANNEL_PCH 9
24#define CHANNEL_CPCH 10
25#define CHANNEL_BCH 11
26#define CHANNEL_DCH 12 /* DCH Dedicated Transport Channel */
27#define CHANNEL_HSDSCH 13 /* HS-DSCH - High Speed Downlink Shared Channel */
28#define CHANNEL_IUR_CPCHF 14
29#define CHANNEL_IUR_FACH 15
30#define CHANNEL_IUR_DSCH 16
31#define CHANNEL_EDCH 17 /* E-DCH Enhanced DCH */
32#define CHANNEL_RACH_TDD_128 18
33#define CHANNEL_HSDSCH_COMMON 19 /* HS-DSCH - High Speed Downlink Shared Channel */
34#define CHANNEL_HSDSCH_COMMON_T3 20
35#define CHANNEL_EDCH_COMMON 21
36
37
38/* Constants */
39#define MAX_FP_CHANS 64
40#define MAX_EDCH_DDIS 16
41#define MAX_NUM_HSDHSCH_MACDFLOW 8
42#define FP_maxNrOfDCHs 128 /* From NBAP-Constants.asn */
43
44enum fp_interface_type
45{
46 IuB_Interface,
47 IuR_Interface
48};
49
50enum division_type
51{
52 Division_FDD = 1,
53 Division_TDD_384 = 2,
54 Division_TDD_128 = 3,
55 Division_TDD_768 = 4
56};
57
58enum fp_hsdsch_entity
59{
60 entity_not_specified = 0,
61 hs = 1,
62 ehs = 2
63};
64
65enum fp_link_type
66{
67 FP_Link_Unknown,
68 FP_Link_ATM,
69 FP_Link_Ethernet
70};
71
72enum fp_rlc_mode {
73 FP_RLC_MODE_UNKNOWN,
74 FP_RLC_TM,
75 FP_RLC_UM,
76 FP_RLC_AM
77};
78
79
80typedef struct
81{
82 int num_ul_chans;
83 int ul_chan_tf_size[MAX_FP_CHANS];
84 int ul_chan_num_tbs[MAX_FP_CHANS];
85 int num_dl_chans;
86 int dl_chan_tf_size[MAX_FP_CHANS];
87 int dl_chan_num_tbs[MAX_FP_CHANS];
88
90
91
92/****************************************/
93/* Channel Specific Information Structs */
94
95/****************/
96/* FACH Structs */
97
99{
100 uint32_t alloc_frame_number; /* Frame where C-RNTI was allocated */
101 uint32_t urnti; /* The U-RNTI to which the C-RNTI was allocated*/
102 uint32_t global_retrieval_count; /* How many times this alloc info was retrieved for FACH channels*/
104
105/* Used in the 'channel_specific_info' field for FACH channels */
107{
108 /* Key: (uint32_t) C-RNTI */
109 /* Value: (fp_crnti_allocation_info_t) U-RNTI allocation info */
110 wmem_tree_t* crnti_to_urnti_map; /* Mapping between C-RNTIs and U-RNTIs using them in this FACH */
112
113
114/****************/
115/* RACH Structs */
116
117/* Used in the 'channel_specific_info' field for RACH channels */
119{
120 /* Key: (uint32_t) C-RNTI */
121 /* Value: (fp_crnti_allocation_info_t) U-RNTI allocation info */
122 wmem_tree_t* crnti_to_urnti_map; /* Mapping between C-RNTIs and U-RNTIs using them in this RACH */
124
125
126/****************/
127/* PCH Structs */
128
129/* Information about the Paging Indication Bitmap seen in a specific PCH frame*/
131{
132 uint32_t frame_number;
133 uint8_t* paging_indications_bitmap;
134 unsigned bitmap_len;
136
137/* Used in the 'channel_specific_info' field for PCH channels */
139{
140 /*Size of the Paging Indication field in this PCH*/
141 int paging_indications;
142 /* Information from the previous frame in this field which contained the paging indication field*/
143 paging_indications_info_t* last_paging_indication_info;
145
146
147/*****************/
148/* E-DCH Structs */
149
150/* Used in the 'channel_specific_info' field for E-DCH channels */
152{
153 int no_ddi_entries;
154 uint8_t edch_ddi[MAX_EDCH_DDIS];
155 unsigned edch_macd_pdu_size[MAX_EDCH_DDIS];
156 uint8_t edch_lchId[MAX_EDCH_DDIS];
157 uint8_t edch_type; /* 1 means T2 */
159
160
161/*******************/
162/* HS-DSCH Structs */
163
164/* Used in the 'channel_specific_info' field for HS-DSCH channels */
166{
167 enum fp_hsdsch_entity hsdsch_entity;
168 uint8_t common_macdflow_id;
169 uint8_t hsdsch_macdflow_id;
170 unsigned hrnti; /*Used for tracking a HS-DSCH flow*/
172
173
174/************************/
175/* FP Conversation Data */
176
177typedef struct
178{
179 enum fp_interface_type iface_type;
180 enum division_type division;
181 int channel; /* see Channel types definitions above */
182 enum fp_rlc_mode rlc_mode;
183 uint32_t dl_frame_number; /* the frame where this conversation is started from CRNC */
184 uint32_t ul_frame_number; /* the frame where this conversation is started from Node B */
185 address crnc_address;
186 uint16_t crnc_port;
187
188 unsigned urnti; /* Identifies a single UE in the UTRAN. Used for tracking it's RLC session across different transport channels */
189 int com_context_id; /* Identifies a single UE in all NBAP messages */
190 uint32_t scrambling_code; /* Identifies a single UE's radio transmissions in the UTRAN */
191
192 void* channel_specific_info; /* Extended channel info based on the channel type */
193
194 /* DCH's in this flow */
195 int num_dch_in_flow;
196 int dch_ids_in_flow_list[FP_maxNrOfDCHs];
197 /* DCH type channel data */
198 fp_dch_channel_info_t fp_dch_channel_info[FP_maxNrOfDCHs];
199 uint8_t dch_crc_present; /* 0=No, 1=Yes, 2=Unknown */
200
201 bool reset_frag; /*Used to indicate that a stream has been reconfigured, hence we need to reset the fragtable*/
202 uint32_t cfn;
203 uint32_t cfn_index;
204
206
207
208/********************************/
209/* FP Packet Data */
210/* (attached to each FP packet) */
211typedef struct fp_info
212{
213 enum fp_interface_type iface_type;
214 enum division_type division;
215 uint8_t release; /* e.g. 99, 4, 5, 6, 7 */
216 uint16_t release_year; /* e.g. 2001 */
217 uint8_t release_month; /* e.g. 12 for December */
218 bool is_uplink;
219 int channel; /* see Channel types definitions above */
220 uint8_t dch_crc_present; /* 0=No, 1=Yes, 2=Unknown */
221 int num_chans;
222 int chan_tf_size[MAX_FP_CHANS];
223 int chan_num_tbs[MAX_FP_CHANS];
224
225 /* fp_edch_channel_info_t; */
226 int no_ddi_entries;
227 uint8_t edch_ddi[MAX_EDCH_DDIS];
228 unsigned edch_macd_pdu_size[MAX_EDCH_DDIS];
229 unsigned edch_lchId[MAX_EDCH_DDIS]; /* Logical Channel Id for E-DCH*/
230 uint8_t edch_type; /* 1 means T2 */
231
232 int cur_tb; /* current transport block (required for dissecting of single TBs */
233 int cur_chan; /* current channel, required to retrieve the correct channel configuration for UMTS MAC */
234 int com_context_id; /* Identifies a single UE in the network */
235 uint16_t srcport, destport;
236
237 /* PCH Related data*/
238 int paging_indications;
239 paging_indications_info_t* relevant_paging_indications; /* Info from previous frame */
240 /* Info from the current frame. Used to carry information from this frame to the conversation info */
241 paging_indications_info_t* current_paging_indications;
242
243 /* HSDSCH Related data */
244 enum fp_hsdsch_entity hsdsch_entity;
245 int hsdsch_macflowd_id;
246 bool hsdhsch_macfdlow_is_mux[MAX_NUM_HSDHSCH_MACDFLOW];
247 enum fp_rlc_mode hsdsch_rlc_mode;
248 enum fp_link_type link_type;
249 unsigned urnti; /*Used for tracking a "sequence" over different transport channels*/
250
251 bool reset_frag; /*Used to indicate that a stream has been reconfigured, hence we need to reset the fragtable*/
252} fp_info;
253
254void set_umts_fp_conv_data(conversation_t *conversation, umts_fp_conversation_info_t *umts_fp_conversation_info);
255
256/*
257 * Editor modelines - https://www.wireshark.org/tools/modelines.html
258 *
259 * Local variables:
260 * c-basic-offset: 4
261 * tab-width: 8
262 * indent-tabs-mode: nil
263 * End:
264 *
265 * vi: set shiftwidth=4 tabstop=8 expandtab:
266 * :indentSize=4:tabSize=8:noTabs=true:
267 */
struct _address address
Holds a network or link-layer address of any supported type.
struct conversation conversation_t
struct _wmem_tree_t wmem_tree_t
Opaque type representing a red-black tree in the wmem system.
Definition wmem_tree.h:49
Definition conversation.h:284
Definition packet-umts_fp.h:99
Definition packet-umts_fp.h:81
Definition packet-umts_fp.h:152
Definition packet-umts_fp.h:107
Definition packet-umts_fp.h:166
Definition packet-umts_fp.h:212
Definition packet-umts_fp.h:139
Definition packet-umts_fp.h:119
Definition packet-umts_fp.h:131
Definition packet-umts_fp.h:178