rrc_defs.h 32.1 KB
Newer Older
1 2 3 4 5
/*
 * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The OpenAirInterface Software Alliance licenses this file to You under
6
 * the OAI Public License, Version 1.1  (the "License"); you may not use this file
7 8 9 10 11 12 13 14 15 16 17 18
 * except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.openairinterface.org/?page_id=698
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *-------------------------------------------------------------------------------
 * For more information about the OpenAirInterface (OAI) Software Alliance:
19
 *      conmnc_digit_lengtht@openairinterface.org
20
 */
21

22
/*! \file RRC/LTE/defs.h
23 24 25
* \brief RRC struct definitions and function prototypes
* \author Navid Nikaein and Raymond Knopp
* \date 2010 - 2014
26 27
* \version 1.0
* \company Eurecom
28
* \email: navid.nikaein@eurecom.fr, raymond.knopp@eurecom.fr
29 30 31 32 33 34 35 36 37
*/

#ifndef __OPENAIR_RRC_DEFS_H__
#define __OPENAIR_RRC_DEFS_H__

#include <stdio.h>
#include <stdlib.h>
#include <string.h>

38
#include "collection/tree.h"
39
#include "common/ngran_types.h"
winckel's avatar
winckel committed
40
#include "rrc_types.h"
41
//#include "PHY/phy_defs.h"
42
#include "LAYER2/RLC/rlc.h"
43 44 45 46
#include "RRC/NR/nr_rrc_types.h"
#include "NR_UE-MRDC-Capability.h"
#include "NR_UE-NR-Capability.h"

47

48
#include "COMMON/platform_constants.h"
49
#include "COMMON/platform_types.h"
50

51
#include "LAYER2/MAC/mac.h"
52

53 54 55 56 57 58 59 60 61 62 63 64 65 66 67
//for D2D
#define DEBUG_CTRL_SOCKET
#define BUFSIZE                1024
#define CONTROL_SOCKET_PORT_NO 8888
#define MAX_NUM_DEST           10
//netlink
//#define DEBUG_PDCP
#define UE_IP_PDCP_NETLINK_ID  31
#define PDCP_PID               1
#define NETLINK_HEADER_SIZE    16
#define SL_DEFAULT_RAB_ID      3
#define SLRB_ID                3

#define MAX_PAYLOAD 1024 /* maximum payload size*/

68 69
#define MAX_NUM_NEIGH_CELLs 6 /* maximum neighbouring cells number */

70 71
#define MAX_NUM_GNB_CELLs 1   /* maximum gNB cells number */

72 73 74 75
#define UE_STATE_NOTIFICATION_INTERVAL      50

#define IPV4_ADDR    "%u.%u.%u.%u"
#define IPV4_ADDR_FORMAT(aDDRESS)                 \
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
76 77 78 79
  (uint8_t)((aDDRESS)  & 0x000000ff),         \
  (uint8_t)(((aDDRESS) & 0x0000ff00) >> 8 ),  \
  (uint8_t)(((aDDRESS) & 0x00ff0000) >> 16),  \
  (uint8_t)(((aDDRESS) & 0xff000000) >> 24)
80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95


//-----------------------------------------------------
// header for Control socket

//Primitives
#define SESSION_INIT_REQ                    1
#define UE_STATUS_INFO                      2
#define GROUP_COMMUNICATION_ESTABLISH_REQ   3
#define GROUP_COMMUNICATION_ESTABLISH_RSP   4
#define DIRECT_COMMUNICATION_ESTABLISH_REQ  5
#define DIRECT_COMMUNICATION_ESTABLISH_RSP  6
#define GROUP_COMMUNICATION_RELEASE_REQ     7
#define GROUP_COMMUNICATION_RELEASE_RSP     8
#define PC5S_ESTABLISH_REQ                  9
#define PC5S_ESTABLISH_RSP                  10
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
96
#define PC5_DISCOVERY_MESSAGE             11
97 98


Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
99
#define PC5_DISCOVERY_PAYLOAD_SIZE      29
100

101
#define DEBUG_SCG_CONFIG 1
102 103

typedef enum {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
104 105
  UE_STATE_OFF_NETWORK,
  UE_STATE_ON_NETWORK
106 107 108
} SL_UE_STATE_t;

typedef enum {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
109 110
  GROUP_COMMUNICATION_RELEASE_OK = 0,
  GROUP_COMMUNICATION_RELEASE_FAILURE
111 112 113
} Group_Communication_Status_t;

struct GroupCommunicationEstablishReq {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
114 115 116 117
  uint32_t sourceL2Id;
  uint32_t groupL2Id;
  uint32_t groupIpAddress;
  uint8_t pppp;
118 119 120
};

struct GroupCommunicationReleaseReq {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
121 122 123
  uint32_t sourceL2Id;
  uint32_t groupL2Id;
  int slrb_id;
124 125 126
};

struct DirectCommunicationEstablishReq {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
127 128 129
  uint32_t sourceL2Id;
  uint32_t destinationL2Id;
  uint32_t pppp;
130 131
};

Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
132 133 134 135
struct PC5SEstablishReq {
  uint8_t type;
  uint32_t sourceL2Id;
  uint32_t destinationL2Id;
136 137
};

Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
138 139 140 141
struct PC5SEstablishRsp {
  uint32_t slrbid_lcid28;
  uint32_t slrbid_lcid29;
  uint32_t slrbid_lcid30;
142 143 144 145 146
};


//PC5_DISCOVERY MESSAGE
typedef struct  {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
147 148
  unsigned char payload[PC5_DISCOVERY_PAYLOAD_SIZE];
  uint32_t measuredPower;
149 150 151 152
}  __attribute__((__packed__)) PC5DiscoveryMessage ;


struct sidelink_ctrl_element {
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
153 154 155 156 157 158 159 160 161 162 163 164
  unsigned short type;
  union {
    struct GroupCommunicationEstablishReq group_comm_establish_req;
    struct DirectCommunicationEstablishReq direct_comm_establish_req;
    Group_Communication_Status_t group_comm_release_rsp;
    //struct DirectCommunicationReleaseReq  direct_comm_release_req;
    SL_UE_STATE_t ue_state;
    int slrb_id;
    struct PC5SEstablishReq pc5s_establish_req;
    struct PC5SEstablishRsp pc5s_establish_rsp;
    PC5DiscoveryMessage pc5_discovery_message;
  } sidelinkPrimitive;
165 166 167 168 169 170 171 172 173 174 175 176 177 178 179
};


//global variables
extern struct sockaddr_in clientaddr;
extern int slrb_id;
extern pthread_mutex_t slrb_mutex;

//the thread function
void *send_UE_status_notification(void *);



//#include "COMMON/openair_defs.h"
#ifndef USER_MODE
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
180
  //#include <rtai.h>
181
#endif
182

183 184 185 186 187 188 189 190 191 192 193
#include "LTE_SystemInformationBlockType1.h"
#include "LTE_SystemInformation.h"
#include "LTE_RRCConnectionReconfiguration.h"
#include "LTE_RRCConnectionReconfigurationComplete.h"
#include "LTE_RRCConnectionSetup.h"
#include "LTE_RRCConnectionSetupComplete.h"
#include "LTE_RRCConnectionRequest.h"
#include "LTE_RRCConnectionReestablishmentRequest.h"
#include "LTE_BCCH-DL-SCH-Message.h"
#include "LTE_SBCCH-SL-BCH-MessageType.h"
#include "LTE_BCCH-BCH-Message.h"
194 195 196
#include "LTE_MCCH-Message.h"
#include "LTE_MBSFNAreaConfiguration-r9.h"
#include "LTE_SCellToAddMod-r10.h"
197 198 199 200
#include "LTE_AS-Config.h"
#include "LTE_AS-Context.h"
#include "LTE_UE-EUTRA-Capability.h"
#include "LTE_MeasResults.h"
201 202
#include "LTE_SidelinkUEInformation-r12.h"

203

204 205
/* for ImsiMobileIdentity_t */
#include "MobileIdentity.h"
206

207
#include "LTE_DRX-Config.h"
208

Cedric Roux's avatar
Cedric Roux committed
209 210 211 212
/* correct Rel(8|10)/Rel14 differences
 * the code is in favor of Rel14, those defines do the translation
 */

213 214 215 216 217 218 219


#define NB_SIG_CNX_CH 1
#define NB_CNX_CH MAX_MOBILES_PER_ENB
#define NB_SIG_CNX_UE 2 //MAX_MANAGED_RG_PER_MOBILE
#define NB_CNX_UE 2//MAX_MANAGED_RG_PER_MOBILE

220
#ifndef NO_RRM
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
221 222 223
  #include "L3_rrc_interface.h"
  #include "rrc_rrm_msg.h"
  #include "rrc_rrm_interface.h"
224 225
#endif

226

227 228 229 230 231 232
#include "intertask_interface.h"




#include "commonDef.h"
Cedric Roux's avatar
Cedric Roux committed
233

234

235 236
//--------
typedef unsigned int uid_t;
237
#define UID_LINEAR_ALLOCATOR_BITMAP_SIZE (((MAX_MOBILES_PER_ENB/8)/sizeof(unsigned int)) + 1)
238 239 240 241 242 243 244 245 246 247 248 249 250
typedef struct uid_linear_allocator_s {
  unsigned int   bitmap[UID_LINEAR_ALLOCATOR_BITMAP_SIZE];
} uid_allocator_t;

//--------



#define PROTOCOL_RRC_CTXT_UE_FMT           PROTOCOL_CTXT_FMT
#define PROTOCOL_RRC_CTXT_UE_ARGS(CTXT_Pp) PROTOCOL_CTXT_ARGS(CTXT_Pp)

#define PROTOCOL_RRC_CTXT_FMT           PROTOCOL_CTXT_FMT
#define PROTOCOL_RRC_CTXT_ARGS(CTXT_Pp) PROTOCOL_CTXT_ARGS(CTXT_Pp)
251
/** @defgroup _rrc RRC
252
 * @ingroup _oai2
253 254 255 256
 * @{
 */


257 258
#define UE_MODULE_INVALID ((module_id_t) ~0) // FIXME attention! depends on type uint8_t!!!
#define UE_INDEX_INVALID  ((module_id_t) ~0) // FIXME attention! depends on type uint8_t!!! used to be -1
winckel's avatar
winckel committed
259

260 261 262 263 264 265 266 267
typedef enum {
  RRC_OK=0,
  RRC_ConnSetup_failed,
  RRC_PHY_RESYNCH,
  RRC_Handover_failed,
  RRC_HO_STARTED
} RRC_status_t;

winckel's avatar
winckel committed
268
typedef enum UE_STATE_e {
winckel's avatar
winckel committed
269 270
  RRC_INACTIVE=0,
  RRC_IDLE,
271 272
  RRC_SI_RECEIVED,
  RRC_CONNECTED,
273
  RRC_RECONFIGURED,
274 275
  RRC_HO_EXECUTION,
  RRC_NR_NSA,
Cedric Roux's avatar
Cedric Roux committed
276 277
  RRC_NR_NSA_RECONFIGURED,
  RRC_NR_NSA_DELETED
278 279
} UE_STATE_t;

winckel's avatar
winckel committed
280
typedef enum HO_STATE_e {
281
  HO_IDLE=0,
282
  HO_MEASUREMENT,
283 284
  HO_PREPARE,
  HO_CMD, // initiated by the src eNB
285 286 287
  HO_COMPLETE, // initiated by the target eNB
  HO_REQUEST,
  HO_ACK,
luaihui's avatar
luaihui committed
288
  HO_FORWARDING,
289
  HO_CONFIGURED,
luaihui's avatar
luaihui committed
290 291
  HO_END_MARKER,
  HO_FORWARDING_COMPLETE,
Cedric Roux's avatar
Cedric Roux committed
292 293
  HO_RELEASE,
  HO_CANCEL
294 295
} HO_STATE_t;

luaihui's avatar
luaihui committed
296 297 298 299 300 301 302 303 304 305
typedef enum DATA_FORWARDING_STATE_e {
  FORWARDING_EMPTY=0,
  FORWARDING_NO_EMPTY
} DATA_FORWARDING_STATE_t;

typedef enum DATA_ENDMARK_STATE_e {
  ENDMARK_EMPTY=0,
  ENDMARK_NO_EMPTY
} DATA_ENDMARK_STATE_t;

306 307 308 309 310 311 312 313 314 315 316 317 318 319 320
typedef enum SL_TRIGGER_e {
  SL_RECEIVE_COMMUNICATION=0,
  SL_TRANSMIT_RELAY_ONE_TO_ONE,
  SL_TRANSMIT_RELAY_ONE_TO_MANY,
  SL_TRANSMIT_NON_RELAY_ONE_TO_ONE,
  SL_TRANSMIT_NON_RELAY_ONE_TO_MANY,
  SL_RECEIVE_DISCOVERY,
  SL_TRANSMIT_NON_PS_DISCOVERY,
  SL_TRANSMIT_PS_DISCOVERY,
  SL_RECEIVE_V2X,
  SL_TRANSMIT_V2X,
  SL_REQUEST_DISCOVERY_TRANSMISSION_GAPS,
  SL_REQUEST_DISCOVERY_RECEPTION_GAPS
} SL_TRIGGER_t;

321
//#define MAX_MOBILES_PER_ENB MAX_MOBILES_PER_RG
322
#define RRM_FREE(p)       if ( (p) != NULL) { free(p) ; p=NULL ; }
323 324 325
#define RRM_MALLOC(t,n)   (t *) malloc16( sizeof(t) * n )
#define RRM_CALLOC(t,n)   (t *) malloc16( sizeof(t) * n)
#define RRM_CALLOC2(t,s)  (t *) malloc16( s )
326

327 328 329
#define MAX_MEAS_OBJ 6
#define MAX_MEAS_CONFIG 6
#define MAX_MEAS_ID 6
330 331

#define PAYLOAD_SIZE_MAX 1024
332
#define RRC_BUF_SIZE 8192
333
#define UNDEF_SECURITY_MODE 0xff
334
#define NO_SECURITY_MODE 0x20
335 336 337 338

#define CBA_OFFSET        0xfff4
// #define NUM_MAX_CBA_GROUP 4 // in the platform_constants

339 340 341
/* TS 36.331: RRC-TransactionIdentifier ::= INTEGER (0..3) */
#define RRC_TRANSACTION_IDENTIFIER_NUMBER  3

342
typedef struct {
343 344 345 346
  unsigned short transport_block_size;   /*!< \brief Minimum PDU size in bytes provided by RLC to MAC layer interface */
  unsigned short max_transport_blocks;   /*!< \brief Maximum PDU size in bytes provided by RLC to MAC layer interface */
  unsigned long  Guaranteed_bit_rate;    /*!< \brief Guaranteed Bit Rate (average) to be offered by MAC layer scheduling*/
  unsigned long  Max_bit_rate;           /*!< \brief Maximum Bit Rate that can be offered by MAC layer scheduling*/
347 348 349 350 351 352 353
  uint8_t  Delay_class;                  /*!< \brief Delay class offered by MAC layer scheduling*/
  uint8_t  Target_bler;                  /*!< \brief Target Average Transport Block Error rate*/
  uint8_t  Lchan_t;                      /*!< \brief Logical Channel Type (BCCH,CCCH,DCCH,DTCH_B,DTCH,MRBCH)*/
} __attribute__ ((__packed__))  LCHAN_DESC;

#define LCHAN_DESC_SIZE sizeof(LCHAN_DESC)

winckel's avatar
winckel committed
354
typedef struct UE_RRC_INFO_s {
355
  UE_STATE_t State;
356
  uint8_t SIB1systemInfoValueTag;
357 358
  uint32_t SIStatus;
  uint32_t SIcnt;
359 360 361
  uint8_t SIB1systemInfoValueTag_MBMS;
  uint32_t SIStatus_MBMS;
  uint32_t SIcnt_MBMS;
362
  uint8_t MCCHStatus[8]; // MAX_MBSFN_AREA
363
  uint8_t SIwindowsize; //!< Corresponds to the SIB1 si-WindowLength parameter. The unit is ms. Possible values are (final): 1,2,5,10,15,20,40
364
  uint8_t SIwindowsize_MBMS; //!< Corresponds to the SIB1 si-WindowLength parameter. The unit is ms. Possible values are (final): 1,2,5,10,15,20,40
365
  uint8_t handoverTarget;
366
  HO_STATE_t ho_state;
367
  uint16_t SIperiod; //!< Corresponds to the SIB1 si-Periodicity parameter (multiplied by 10). Possible values are (final): 80,160,320,640,1280,2560,5120
368
  uint16_t SIperiod_MBMS; //!< Corresponds to the SIB1-MBMS si-Periodicity parameter (multiplied by 10). Possible values are (final): 80,160,320,640,1280,2560,5120 TODO
369
  unsigned short UE_index;
370 371 372 373 374 375 376 377
  uint32_t T300_active;
  uint32_t T300_cnt;
  uint32_t T304_active;
  uint32_t T304_cnt;
  uint32_t T310_active;
  uint32_t T310_cnt;
  uint32_t N310_cnt;
  uint32_t N311_cnt;
378
  rnti_t   rnti;
winckel's avatar
winckel committed
379
} __attribute__ ((__packed__)) UE_RRC_INFO;
380

381
typedef struct UE_S_TMSI_s {
gauthier's avatar
gauthier committed
382 383 384
  boolean_t  presence;
  mme_code_t mme_code;
  m_tmsi_t   m_tmsi;
winckel's avatar
winckel committed
385
} __attribute__ ((__packed__)) UE_S_TMSI;
386

387

winckel's avatar
winckel committed
388
typedef enum e_rab_satus_e {
389
  E_RAB_STATUS_NEW,
390 391
  E_RAB_STATUS_DONE, // from the eNB perspective
  E_RAB_STATUS_ESTABLISHED, // get the reconfigurationcomplete form UE
392
  E_RAB_STATUS_REESTABLISHED, // after HO
393
  E_RAB_STATUS_TOMODIFY,      // ENDC NSA
394
  E_RAB_STATUS_FAILED,
395
  E_RAB_STATUS_TORELEASE  // to release DRB between eNB and UE
winckel's avatar
winckel committed
396 397
} e_rab_status_t;

398
typedef struct e_rab_param_s {
399 400
  e_rab_t param;
  uint8_t status;
401
  uint8_t xid; // transaction_id
402 403
  s1ap_Cause_t cause;
  uint8_t cause_value;
winckel's avatar
winckel committed
404
} __attribute__ ((__packed__)) e_rab_param_t;
405

406

407
/* Intermediate structure for Handover management. Associated per-UE in eNB_RRC_INST */
winckel's avatar
winckel committed
408
typedef struct HANDOVER_INFO_s {
409 410
  uint8_t ho_prepare;
  uint8_t ho_complete;
411 412 413
  HO_STATE_t state; //current state of handover
  uint32_t modid_s; //module_idP of serving cell
  uint32_t modid_t; //module_idP of target cell
414
  int assoc_id;
415 416
  uint8_t ueid_s; //UE index in serving cell
  uint8_t ueid_t; //UE index in target cell
417 418
  LTE_AS_Config_t as_config; /* these two parameters are taken from 36.331 section 10.2.2: HandoverPreparationInformation-r8-IEs */
  LTE_AS_Context_t as_context; /* They are mandatory for HO */
419 420
  uint8_t buf[RRC_BUF_SIZE];  /* ASN.1 encoded handoverCommandMessage */
  int size;   /* size of above message in bytes */
421
  int x2_id;   /* X2AP UE ID in the target eNB */
luaihui's avatar
luaihui committed
422 423 424
  uint32_t x2u_teid;
  DATA_FORWARDING_STATE_t forwarding_state;
  DATA_ENDMARK_STATE_t endmark_state;
winckel's avatar
winckel committed
425
} HANDOVER_INFO;
426

427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485
typedef struct PER_EVENT_s {
  long maxReportCells;
} PER_EVENT_t;

typedef struct A1_EVENT_s {
  long threshold_RSRP;
  long hysteresis;
  long timeToTrigger;
  long maxReportCells;
} A1_EVENT_t;

typedef struct A2_EVENT_s {
  long threshold_RSRP;
  long hysteresis;
  long timeToTrigger;
  long maxReportCells;
} A2_EVENT_t;

typedef struct A3_EVENT_s {
  long a3_offset;
  int reportOnLeave;
  long hysteresis;
  long timeToTrigger;
  long maxReportCells;
} A3_EVENT_t;


typedef struct A4_EVENT_s {
  long threshold_RSRP;
  long hysteresis;
  long timeToTrigger;
  long maxReportCells;
} A4_EVENT_t;

typedef struct A5_EVENT_s {
  long threshold_RSRP_1;
  long threshold_RSRP_2;
  long hysteresis;
  long timeToTrigger;
  long maxReportCells;
} A5_EVENT_t;

typedef struct EVENTS_s {
  PER_EVENT_t *per_event;

  A1_EVENT_t *a1_event;

  A2_EVENT_t *a2_event;

  A3_EVENT_t *a3_event;

  A4_EVENT_t *a4_event;

  A5_EVENT_t *a5_event;
} EVENTS_t;

typedef struct MEASUREMENT_INFO_s {
  //TODO: Extend to multiple meas objects for OFP/OFN offsets
  long  offsetFreq;
486
  //TODO: extend to multiple carriers for OCP/OCN offsets
487
  long cellIndividualOffset[MAX_NUM_NEIGH_CELLs+1];
488 489
  long filterCoefficientRSRP;
  long filterCoefficientRSRQ;
490 491 492 493
  EVENTS_t *events;
} MEASUREMENT_INFO;


494 495
#define RRC_HEADER_SIZE_MAX 64
#define RRC_BUFFER_SIZE_MAX 1024
496
typedef struct {
497
  char Payload[RRC_BUFFER_SIZE_MAX];
498
  char Header[RRC_HEADER_SIZE_MAX];
499
  char payload_size;
500
} RRC_BUFFER;
501 502
#define RRC_BUFFER_SIZE sizeof(RRC_BUFFER)

winckel's avatar
winckel committed
503
typedef struct RB_INFO_s {
504
  uint16_t Rb_id;  //=Lchan_id
505
  LCHAN_DESC Lchan_desc[2];
506
  //  MAC_MEAS_REQ_ENTRY *Meas_entry;
winckel's avatar
winckel committed
507
} RB_INFO;
508

winckel's avatar
winckel committed
509
typedef struct SRB_INFO_s {
510
  uint16_t Srb_id;  //=Lchan_id
511 512
  RRC_BUFFER Rx_buffer;
  RRC_BUFFER Tx_buffer;
513 514
  LCHAN_DESC Lchan_desc[2];
  unsigned int Trans_id;
515
  uint8_t Active;
winckel's avatar
winckel committed
516
} SRB_INFO;
517

winckel's avatar
winckel committed
518
typedef struct RB_INFO_TABLE_ENTRY_s {
519
  RB_INFO Rb_info;
520 521 522
  uint8_t Active;
  uint32_t Next_check_frame;
  uint8_t Status;
winckel's avatar
winckel committed
523
} RB_INFO_TABLE_ENTRY;
524

winckel's avatar
winckel committed
525
typedef struct SRB_INFO_TABLE_ENTRY_s {
526
  SRB_INFO Srb_info;
527 528
  uint8_t Active;
  uint8_t Status;
529
  uint32_t Next_check_frame;
530
} SRB_INFO_TABLE_ENTRY;
531

winckel's avatar
winckel committed
532
typedef struct MEAS_REPORT_LIST_s {
533
  LTE_MeasId_t measId;
534
  //CellsTriggeredList  cellsTriggeredList;//OPTIONAL
535
  uint32_t numberOfReportsSent;
536
} MEAS_REPORT_LIST;
537

winckel's avatar
winckel committed
538
typedef struct HANDOVER_INFO_UE_s {
539
  LTE_PhysCellId_t targetCellId;
540
  uint8_t measFlag;
winckel's avatar
winckel committed
541
} HANDOVER_INFO_UE;
542

543 544 545 546 547 548 549
typedef struct rrc_gummei_s {
  uint16_t mcc;
  uint16_t mnc;
  uint8_t  mnc_len;
  uint8_t  mme_code;
  uint16_t mme_group_id;
} rrc_gummei_t;
550

551 552 553 554 555 556 557
typedef struct {
  uint16_t ciphering_algorithms;
  uint16_t integrity_algorithms;
  uint16_t sk_counter;
  uint8_t  kgNB[32];
} lte_rrc_nr_security_t;

558
typedef struct eNB_RRC_UE_s {
559
  uint8_t                            primaryCC_id;
560
  LTE_SCellToAddMod_r10_t            sCell_config[2];
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
561 562 563 564 565
  LTE_SRB_ToAddModList_t            *SRB_configList;
  LTE_SRB_ToAddModList_t            *SRB_configList2[RRC_TRANSACTION_IDENTIFIER_NUMBER];
  LTE_DRB_ToAddModList_t            *DRB_configList;
  LTE_DRB_ToAddModList_t            *DRB_configList2[RRC_TRANSACTION_IDENTIFIER_NUMBER];
  LTE_DRB_ToReleaseList_t           *DRB_Release_configList2[RRC_TRANSACTION_IDENTIFIER_NUMBER];
566
  uint8_t                            DRB_active[NB_RB_MAX -2];
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
567 568 569 570 571 572 573 574
  struct LTE_PhysicalConfigDedicated    *physicalConfigDedicated;
  struct LTE_SPS_Config             *sps_Config;
  LTE_MeasObjectToAddMod_t          *MeasObj[MAX_MEAS_OBJ];
  struct LTE_ReportConfigToAddMod   *ReportConfig[MAX_MEAS_CONFIG];
  struct LTE_QuantityConfig         *QuantityConfig;
  struct LTE_MeasIdToAddMod         *MeasId[MAX_MEAS_ID];
  LTE_MAC_MainConfig_t              *mac_MainConfig;
  LTE_MeasGapConfig_t               *measGapConfig;
575 576 577 578
  SRB_INFO                           SI;
  SRB_INFO                           Srb0;
  SRB_INFO_TABLE_ENTRY               Srb1;
  SRB_INFO_TABLE_ENTRY               Srb2;
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
579 580
  LTE_MeasConfig_t                  *measConfig;
  HANDOVER_INFO                     *handover_info;
581
  MEASUREMENT_INFO                  *measurement_info;
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
582
  LTE_MeasResults_t                 *measResults;
583
  LTE_MobilityControlInfo_t         *mobilityInfo;
584

Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
585
  LTE_UE_EUTRA_Capability_t         *UE_Capability;
586
  int                                UE_Capability_size;
587 588 589 590
  NR_UE_MRDC_Capability_t           *UE_Capability_MRDC;
  int                UE_MRDC_Capability_size;
  NR_UE_NR_Capability_t       *UE_Capability_nr;
  int                UE_NR_Capability_size;
591
  ImsiMobileIdentity_t               imsi;
592 593 594

  /* KeNB as derived from KASME received from EPC */
  uint8_t kenb[32];
595 596 597
  int8_t  kenb_ncc;
  uint8_t nh[32];
  int8_t  nh_ncc;
598
  /* Used integrity/ciphering algorithms */
599 600
  LTE_CipheringAlgorithm_r12_t                          ciphering_algorithm;
  e_LTE_SecurityAlgorithmConfig__integrityProtAlgorithm integrity_algorithm;
601

602
  uint8_t                            Status; // RRC status, type enum UE_STATE_t
603
  rnti_t                             rnti;
Cedric Roux's avatar
Cedric Roux committed
604 605
  int                                gnb_rnti;     //RNTI of the UE at the gNB if in ENDC connection
  int                                gnb_x2_assoc_id;
606 607
  uint64_t                           random_ue_identity;

608

609 610
  /* Information from UE RRC ConnectionRequest */
  UE_S_TMSI                          Initialue_identity_s_TMSI;
611
  LTE_EstablishmentCause_t           establishment_cause;
612 613

  /* Information from UE RRC ConnectionReestablishmentRequest */
614
  LTE_ReestablishmentCause_t         reestablishment_cause;
615 616 617 618 619 620 621

  /* UE id for initial connection to S1AP */
  uint16_t                           ue_initial_id;

  /* Information from S1AP initial_context_setup_req */
  uint32_t                           eNB_ue_s1ap_id :24;

622 623 624
  uint32_t                           mme_ue_s1ap_id;
  rrc_gummei_t                       ue_gummei;

625 626
  security_capabilities_t            security_capabilities;

627 628 629
  /* security capabilities and settings for an UE in ENDC mode */
  lte_rrc_nr_security_t              nr_security;

630 631 632 633
  int                                next_hop_chain_count;

  uint8_t                            next_security_key[SECURITY_KEY_LENGTH];

634
  /* Total number of e_rab already setup in the list */
635
  uint8_t                            setup_e_rabs;
636 637
  /* Number of e_rab to be setup in the list */
  uint8_t                            nb_of_e_rabs;
638 639 640
  /* Number of e_rab to be modified in the list */
  uint8_t                            nb_of_modify_e_rabs;
  uint8_t                            nb_of_failed_e_rabs;
641
  uint8_t              nb_of_modify_endc_e_rabs;
642
  e_rab_param_t                      modify_e_rab[NB_RB_MAX];//[S1AP_MAX_E_RAB];
643
  /* list of e_rab to be setup by RRC layers */
644
  e_rab_param_t                      e_rab[NB_RB_MAX];//[S1AP_MAX_E_RAB];
645 646
  /* UE aggregate maximum bitrate */
  ambr_t ue_ambr;
647 648
  //release e_rabs
  uint8_t                            nb_release_of_e_rabs;
649 650
  /* list of e_rab to be released by RRC layers */
  uint8_t                            e_rabs_tobereleased[NB_RB_MAX];
651
  e_rab_failed_t                     e_rabs_release_failed[S1AP_MAX_E_RAB];
652 653 654 655
  // LG: For GTPV1 TUNNELS
  uint32_t                           enb_gtp_teid[S1AP_MAX_E_RAB];
  transport_layer_addr_t             enb_gtp_addrs[S1AP_MAX_E_RAB];
  rb_id_t                            enb_gtp_ebi[S1AP_MAX_E_RAB];
656 657 658 659
  // LG: For GTPV1 TUNNELS ENDC
  uint32_t                           gnb_gtp_endc_teid[S1AP_MAX_E_RAB];
  transport_layer_addr_t             gnb_gtp_endc_addrs[S1AP_MAX_E_RAB];
  rb_id_t                            gnb_gtp_endc_ebi[S1AP_MAX_E_RAB];
luaihui's avatar
luaihui committed
660 661 662 663 664 665
  /* Total number of e_rab already setup in the list */
  uint8_t                            nb_x2u_e_rabs;
  // LG: For GTPV1 TUNNELS(X2U)
  uint32_t                           enb_gtp_x2u_teid[S1AP_MAX_E_RAB];
  transport_layer_addr_t             enb_gtp_x2u_addrs[S1AP_MAX_E_RAB];
  rb_id_t                            enb_gtp_x2u_ebi[S1AP_MAX_E_RAB];
666
  uint32_t                           ul_failure_timer;
667
  uint32_t                           ue_release_timer;
668
  uint32_t                           ue_release_timer_thres;
669 670 671 672 673 674
  uint32_t                           ue_release_timer_s1;
  uint32_t                           ue_release_timer_thres_s1;
  uint32_t                           ue_release_timer_rrc;
  uint32_t                           ue_release_timer_thres_rrc;
  uint32_t                           ue_reestablishment_timer;
  uint32_t                           ue_reestablishment_timer_thres;
675 676
  /* RRC inactivity timer: on timeout, should release RRC connection for inactivity on all E-RABs */
  uint32_t                           ue_rrc_inactivity_timer;
677
  uint8_t                            e_rab_release_command_flag;
678
  int8_t                             reestablishment_xid;
679
  int                                does_nr;
680
  int                                nr_capabilities_requested;
681 682 683
} eNB_RRC_UE_t;

typedef uid_t ue_uid_t;
684

685 686 687 688 689 690 691 692 693
typedef struct rrc_eNB_ue_context_s {
  /* Tree related data */
  RB_ENTRY(rrc_eNB_ue_context_s) entries;

  /* Uniquely identifies the UE between MME and eNB within the eNB.
   * This id is encoded on 24bits.
   */
  rnti_t         ue_id_rnti;

694
  // another key for protocol layers but should not be used as a key for RB tree
695 696 697 698 699
  ue_uid_t       local_uid;

  /* UE id for initial connection to S1AP */
  struct eNB_RRC_UE_s   ue_context;
} rrc_eNB_ue_context_t;
700

701
typedef struct {
702 703
  uint8_t                           *MIB;
  uint8_t                           sizeof_MIB;
704 705 706 707
  uint8_t                           *SIB1;
  uint8_t                           sizeof_SIB1;
  uint8_t                           *SIB23;
  uint8_t                           sizeof_SIB23;
708 709
  uint8_t                           *SIB1_BR;
  uint8_t                           sizeof_SIB1_BR;
710 711
  uint8_t                           *SIB23_BR;
  uint8_t                           sizeof_SIB23_BR;
712 713 714 715
  uint8_t                           *MIB_FeMBMS;
  uint8_t                           sizeof_MIB_FeMBMS;
  uint8_t                           *SIB1_MBMS;
  uint8_t                           sizeof_SIB1_MBMS;
716 717 718 719 720
  int                                   physCellId;
  int                                   Ncp;
  int                                   p_eNB;
  uint32_t                              dl_CarrierFreq;
  uint32_t                              ul_CarrierFreq;
721 722
  uint32_t                              eutra_band;
  uint32_t                              N_RB_DL;
723 724
  uint32_t                              pbch_repetition;
  LTE_BCCH_BCH_Message_t                mib;
725
  LTE_BCCH_BCH_Message_t                *mib_DU;
726 727
  LTE_BCCH_DL_SCH_Message_t             siblock1;
  LTE_BCCH_DL_SCH_Message_t             siblock1_BR;
728
  LTE_BCCH_DL_SCH_Message_t             *siblock1_DU;
729 730
  LTE_BCCH_DL_SCH_Message_t             systemInformation;
  LTE_BCCH_DL_SCH_Message_t             systemInformation_BR;
731 732 733
  LTE_BCCH_BCH_Message_MBMS_t            mib_fembms;
  LTE_BCCH_DL_SCH_Message_MBMS_t         siblock1_MBMS;
  LTE_BCCH_DL_SCH_Message_MBMS_t         systemInformation_MBMS;
734 735 736
  LTE_SchedulingInfo_MBMS_r14_t 	 schedulingInfo_MBMS;
  LTE_PLMN_IdentityInfo_t		 PLMN_identity_info_MBMS[6];
  LTE_MCC_MNC_Digit_t			 dummy_mcc_MBMS[6][3], dummy_mnc_MBMS[6][3];
737 738 739 740 741
  LTE_SystemInformationBlockType1_t     *sib1;
  LTE_SystemInformationBlockType2_t     *sib2;
  LTE_SystemInformationBlockType3_t     *sib3;
  LTE_SystemInformationBlockType1_t     *sib1_BR;
  LTE_SystemInformationBlockType2_t     *sib2_BR;
742 743
  LTE_SystemInformationBlockType1_MBMS_r14_t *sib1_MBMS;
  LTE_SystemInformationBlockType13_r9_t *sib13_MBMS;
744
  uint8_t       FeMBMS_flag;
745
  LTE_SystemInformationBlockType13_r9_t *sib13;
746
  uint8_t                           MBMS_flag;
747 748 749
  uint8_t                           num_mbsfn_sync_area;
  uint8_t                           **MCCH_MESSAGE; //  MAX_MBSFN_AREA
  uint8_t                           sizeof_MCCH_MESSAGE[8];// MAX_MBSFN_AREA
750 751
  LTE_MCCH_Message_t                mcch;
  LTE_MBSFNAreaConfiguration_r9_t  *mcch_message;
752
  SRB_INFO                          MCCH_MESS[8];// MAX_MBSFN_AREA
753 754 755 756 757 758
  uint8_t                           **MCCH_MESSAGE_COUNTING; //  MAX_MBSFN_AREA
  uint8_t                           sizeof_MCCH_MESSAGE_COUNTING[8];// MAX_MBSFN_AREA
  LTE_MCCH_Message_t                mcch_counting;
  LTE_MBMSCountingRequest_r10_t    *mcch_message_counting;
  SRB_INFO                          MCCH_MESS_COUNTING[8];// MAX_MBSFN_AREA

759
  //TTN - SIB 18,19,21 for D2D
760 761 762
  LTE_SystemInformationBlockType18_r12_t *sib18;
  LTE_SystemInformationBlockType19_r12_t *sib19;
  LTE_SystemInformationBlockType21_r14_t *sib21;
763
  // End - TTN
764
  SRB_INFO                          SI;
765 766
  uint8_t                           *paging[MAX_MOBILES_PER_ENB];
  uint32_t                           sizeof_paging[MAX_MOBILES_PER_ENB];
767
} rrc_eNB_carrier_data_t;
768

769

770
typedef struct eNB_RRC_INST_s {
771
  /// southbound midhaul configuration
772
  ngran_node_t                    node_type;
773
  eth_params_t                    eth_params_s;
774 775
  char                            *node_name;
  uint32_t                        node_id;
776
  rrc_eNB_carrier_data_t          carrier[MAX_NUM_CCs];
777 778
  uid_allocator_t                    uid_allocator; // for rrc_ue_head
  RB_HEAD(rrc_ue_tree_s, rrc_eNB_ue_context_s)     rrc_ue_head; // ue_context tree key search by rnti
779
  uint8_t                           HO_flag;
780
  uint8_t                            Nb_ue;
781 782 783
  hash_table_t                      *initial_id2_s1ap_ids; // key is    content is rrc_ue_s1ap_ids_t
  hash_table_t                      *s1ap_id2_s1ap_ids   ; // key is    content is rrc_ue_s1ap_ids_t

784 785 786 787 788 789
#ifdef LOCALIZATION
  /// localization type, 0: power based, 1: time based
  uint8_t loc_type;
  /// epoch timestamp in millisecond, RRC
  int32_t reference_timestamp_ms;
  /// aggregate physical states every n millisecond
790
  int32_t aggregation_period_ms;
791 792
  /// localization list for aggregated measurements from PHY
  struct list loc_list;
793
#endif
794

795 796
  //RRC configuration
  RrcConfigurationReq configuration;
797

798 799
  /// NR cell id
  uint64_t nr_cellid;
800

801 802 803
  // X2 handover controlled by network
  int x2_ho_net_control;

804 805 806 807 808
  // Neighborouring cells id
  int num_neigh_cells;
  int num_neigh_cells_cc[MAX_NUM_CCs];
  uint32_t neigh_cells_id[MAX_NUM_NEIGH_CELLs][MAX_NUM_CCs];

809 810 811 812 813
  // gNB cells connected to this eNB
  int num_gnb_cells;
  int num_gnb_cells_cc[MAX_NUM_GNB_CELLs];
  uint32_t gnb_cells_id[MAX_NUM_GNB_CELLs][MAX_NUM_CCs];

814
  // Nr scc freq band and SSB absolute frequency
815
  uint32_t nr_gnb_freq_band[MAX_NUM_GNB_CELLs][MAX_NUM_CCs];
816
  int nr_scg_ssb_freq;
817

818 819 820 821 822 823 824 825
  // other RAN parameters
  int srb1_timer_poll_retransmit;
  int srb1_poll_pdu;
  int srb1_poll_byte;
  int srb1_max_retx_threshold;
  int srb1_timer_reordering;
  int srb1_timer_status_prohibit;
  int srs_enable[MAX_NUM_CCs];
826 827
  int cell_info_configured;
  pthread_mutex_t cell_info_mutex;
828 829 830
  uint16_t sctp_in_streams;
  uint16_t sctp_out_streams;

831 832 833
} eNB_RRC_INST;

#define MAX_UE_CAPABILITY_SIZE 255
winckel's avatar
winckel committed
834
typedef struct OAI_UECapability_s {
835 836
  uint8_t sdu[MAX_UE_CAPABILITY_SIZE];
  uint8_t sdu_size;
837
  LTE_UE_EUTRA_Capability_t *UE_EUTRA_Capability;
838 839
} OAI_UECapability_t;

winckel's avatar
winckel committed
840
typedef struct UE_RRC_INST_s {
winckel's avatar
winckel committed
841 842 843 844
  Rrc_State_t     RrcState;
  Rrc_Sub_State_t RrcSubState;
  plmn_t          plmnID;
  Byte_t          rat;
845
  uint8_t         selected_plmn_identity;
winckel's avatar
winckel committed
846
  as_nas_info_t   initialNasMsg;
Raymond Knopp's avatar
 
Raymond Knopp committed
847
  OAI_UECapability_t *UECap;
848 849 850 851 852 853
  uint8_t *UECapability;
  uint8_t UECapability_size;
  UE_RRC_INFO Info[NB_SIG_CNX_UE];
  SRB_INFO Srb0[NB_SIG_CNX_UE];
  SRB_INFO_TABLE_ENTRY Srb1[NB_CNX_UE];
  SRB_INFO_TABLE_ENTRY Srb2[NB_CNX_UE];
854
  HANDOVER_INFO_UE HandoverInfoUe;
855 856 857 858 859 860
  uint8_t *SIB1[NB_CNX_UE];
  uint8_t sizeof_SIB1[NB_CNX_UE];
  uint8_t *SI[NB_CNX_UE];
  uint8_t sizeof_SI[NB_CNX_UE];
  uint8_t SIB1Status[NB_CNX_UE];
  uint8_t SIStatus[NB_CNX_UE];
861 862 863 864 865 866
  uint8_t *SIB1_MBMS[NB_CNX_UE];
  uint8_t sizeof_SIB1_MBMS[NB_CNX_UE];
  uint8_t *SI_MBMS[NB_CNX_UE];
  uint8_t sizeof_SI_MBMS[NB_CNX_UE];
  uint8_t SIB1Status_MBMS[NB_CNX_UE];
  uint8_t SIStatus_MBMS[NB_CNX_UE];
867
  LTE_SystemInformationBlockType1_t *sib1[NB_CNX_UE];
868
  LTE_SystemInformationBlockType1_MBMS_r14_t *sib1_MBMS[NB_CNX_UE];
869
  LTE_SystemInformation_t *si[NB_CNX_UE]; //!< Temporary storage for an SI message. Decoding happens in decode_SI().
870
  LTE_SystemInformation_MBMS_r14_t *si_MBMS[NB_CNX_UE]; //!< Temporary storage for an SI message. Decoding happens in decode_SI().
871 872 873 874 875 876 877 878 879 880
  LTE_SystemInformationBlockType2_t *sib2[NB_CNX_UE];
  LTE_SystemInformationBlockType3_t *sib3[NB_CNX_UE];
  LTE_SystemInformationBlockType4_t *sib4[NB_CNX_UE];
  LTE_SystemInformationBlockType5_t *sib5[NB_CNX_UE];
  LTE_SystemInformationBlockType6_t *sib6[NB_CNX_UE];
  LTE_SystemInformationBlockType7_t *sib7[NB_CNX_UE];
  LTE_SystemInformationBlockType8_t *sib8[NB_CNX_UE];
  LTE_SystemInformationBlockType9_t *sib9[NB_CNX_UE];
  LTE_SystemInformationBlockType10_t *sib10[NB_CNX_UE];
  LTE_SystemInformationBlockType11_t *sib11[NB_CNX_UE];
881 882
  uint8_t                           *MIB;
  //SIB18
883 884 885
  LTE_SystemInformationBlockType18_r12_t *sib18[NB_CNX_UE];
  LTE_SystemInformationBlockType19_r12_t *sib19[NB_CNX_UE];
  LTE_SystemInformationBlockType21_r14_t *sib21[NB_CNX_UE];
886

887
  LTE_SBCCH_SL_BCH_MessageType_t   mib_sl[NB_CNX_UE];
888
  /// Preconfiguration for Sidelink
889
  struct LTE_SL_Preconfiguration_r12 *SL_Preconfiguration[NB_CNX_UE];
890 891 892 893 894 895 896
  //source L2 Id
  uint32_t sourceL2Id;
  //group L2 Id
  uint32_t groupL2Id;
  //current destination
  uint32_t destinationL2Id;
  //List of destinations
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
897
  uint32_t destinationList[MAX_NUM_DEST];
898 899
  //sl_discovery..
  SRB_INFO SL_Discovery[NB_CNX_UE];
900
  uint8_t MBMS_flag;
901 902 903
  uint8_t *MCCH_MESSAGE[NB_CNX_UE];
  uint8_t sizeof_MCCH_MESSAGE[NB_CNX_UE];
  uint8_t MCCH_MESSAGEStatus[NB_CNX_UE];
904 905 906
  LTE_MBSFNAreaConfiguration_r9_t       *mcch_message[NB_CNX_UE];
  LTE_SystemInformationBlockType12_r9_t *sib12[NB_CNX_UE];
  LTE_SystemInformationBlockType13_r9_t *sib13[NB_CNX_UE];
907
  LTE_SystemInformationBlockType13_r9_t *sib13_MBMS[NB_CNX_UE];
908
  uint8_t           FeMBMS_flag;
909
  uint8_t                         num_srb;
910 911 912
  struct LTE_SRB_ToAddMod         *SRB1_config[NB_CNX_UE];
  struct LTE_SRB_ToAddMod         *SRB2_config[NB_CNX_UE];
  struct LTE_DRB_ToAddMod         *DRB_config[NB_CNX_UE][8];
913
  rb_id_t                         *defaultDRB; // remember the ID of the default DRB
914 915 916 917 918 919 920 921 922 923 924 925
  LTE_MeasObjectToAddMod_t        *MeasObj[NB_CNX_UE][MAX_MEAS_OBJ];
  struct LTE_ReportConfigToAddMod *ReportConfig[NB_CNX_UE][MAX_MEAS_CONFIG];
  struct LTE_QuantityConfig       *QuantityConfig[NB_CNX_UE];
  struct LTE_MeasIdToAddMod       *MeasId[NB_CNX_UE][MAX_MEAS_ID];
  MEAS_REPORT_LIST                *measReportList[NB_CNX_UE][MAX_MEAS_ID];
  uint32_t                        measTimer[NB_CNX_UE][MAX_MEAS_ID][6]; // 6 neighboring cells
  LTE_RSRP_Range_t                s_measure;
  struct LTE_MeasConfig__speedStatePars *speedStatePars;
  struct LTE_PhysicalConfigDedicated  *physicalConfigDedicated[NB_CNX_UE];
  struct LTE_SPS_Config           *sps_Config[NB_CNX_UE];
  LTE_MAC_MainConfig_t            *mac_MainConfig[NB_CNX_UE];
  LTE_MeasGapConfig_t             *measGapConfig[NB_CNX_UE];
926
  double                          filter_coeff_rsrp; // [7] ???
927
  double                          filter_coeff_rsrq; // [7] ???
928 929 930 931
  float                           rsrp_db[7];
  float                           rsrq_db[7];
  float                           rsrp_db_filtered[7];
  float                           rsrq_db_filtered[7];
932 933
  /* KeNB as computed from parameters within USIM card */
  uint8_t kenb[32];
934 935
  uint8_t nh[32];
  int8_t  nh_ncc;
936 937

  /* Used integrity/ciphering algorithms */
938 939
  LTE_CipheringAlgorithm_r12_t                          ciphering_algorithm;
  e_LTE_SecurityAlgorithmConfig__integrityProtAlgorithm integrity_algorithm;
940
  /// Used for Sidelink Preconfiguration
941
  LTE_DRB_ToAddModList_t *DRB_configList;
winckel's avatar
winckel committed
942
} UE_RRC_INST;
943

944 945 946 947 948 949 950 951
typedef struct UE_PF_PO_s {
  boolean_t enable_flag;  /* flag indicate whether current object is used */
  uint16_t ue_index_value;  /* UE index value */
  uint8_t PF_min;  /* minimal value of Paging Frame (PF) */
  uint8_t PO;  /* Paging Occasion (PO) */
  uint32_t T;  /* DRX cycle */
} UE_PF_PO_t;

952
#include "rrc_proto.h"
winckel's avatar
winckel committed
953

954
#endif
955
/** @} */