remove eNB threads for RRC and MAC, MAC thread was only for DRX config (useless) and RRC thread has many race conditions with MAC+PHY
This commit is contained in:
@@ -296,55 +296,54 @@ typedef struct {
|
||||
//TASK_DEF(TASK_GTPV1_U, TASK_PRIORITY_MED, 1000,NULL, NULL)
|
||||
//TASK_DEF(TASK_UDP, TASK_PRIORITY_MED, 1000, NULL, NULL)
|
||||
void *rrc_enb_process_msg(void *);
|
||||
#define FOREACH_TASK(TASK_DEF) \
|
||||
TASK_DEF(TASK_UNKNOWN, TASK_PRIORITY_MED, 50, NULL, NULL) \
|
||||
TASK_DEF(TASK_TIMER, TASK_PRIORITY_MED, 10, NULL, NULL) \
|
||||
TASK_DEF(TASK_L2L1, TASK_PRIORITY_MAX, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_BM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PHY_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAC_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAC_GNB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RLC_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_ENB_NB_IoT, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_GNB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_DATA_FORWARDING, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_END_MARKER, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_ENB, TASK_PRIORITY_MED, 200, NULL,NULL)\
|
||||
TASK_DEF(TASK_RRC_GNB, TASK_PRIORITY_MED, 200, NULL,NULL)\
|
||||
TASK_DEF(TASK_RAL_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_S1AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NGAP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_X2AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M2AP_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M2AP_MCE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP_MME, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP_MCE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_SCTP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_ENB_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_GNB_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MCE_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MME_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PHY_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RLC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NAS_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RAL_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_GTPV1_U, TASK_PRIORITY_MED, 1000,NULL, NULL)\
|
||||
TASK_DEF(TASK_CU_F1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_DU_F1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_CUCP_E1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_CUUP_E1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_UE_SIM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_GNB_SIM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NSA_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NSA_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NAS_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAX, TASK_PRIORITY_MED, 200, NULL, NULL)
|
||||
#define FOREACH_TASK(TASK_DEF) \
|
||||
TASK_DEF(TASK_UNKNOWN, TASK_PRIORITY_MED, 50, NULL, NULL) \
|
||||
TASK_DEF(TASK_TIMER, TASK_PRIORITY_MED, 10, NULL, NULL) \
|
||||
TASK_DEF(TASK_L2L1, TASK_PRIORITY_MAX, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_BM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PHY_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAC_GNB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RLC_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_ENB_NB_IoT, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_GNB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_DATA_FORWARDING, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_END_MARKER, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_GNB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RAL_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_S1AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NGAP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_X2AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M2AP_ENB, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M2AP_MCE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP_MME, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_M3AP_MCE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_SCTP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_ENB_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_GNB_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MCE_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MME_APP, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PHY_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RLC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_PDCP_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NAS_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RAL_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_GTPV1_U, TASK_PRIORITY_MED, 1000, NULL, NULL) \
|
||||
TASK_DEF(TASK_CU_F1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_DU_F1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_CUCP_E1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_CUUP_E1, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_UE_SIM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_GNB_SIM, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NSA_UE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_RRC_NSA_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_NAS_NRUE, TASK_PRIORITY_MED, 200, NULL, NULL) \
|
||||
TASK_DEF(TASK_MAX, TASK_PRIORITY_MED, 200, NULL, NULL)
|
||||
|
||||
#define TASK_DEF(TaskID, pRIO, qUEUEsIZE, FuNc, ThreadFunc) { pRIO, qUEUEsIZE, #TaskID, FuNc, ThreadFunc },
|
||||
|
||||
|
||||
@@ -53,11 +53,8 @@ int create_tasks(uint32_t enb_nb) {
|
||||
LOG_I(ENB_APP, "Creating ENB_APP eNB Task\n");
|
||||
rc = itti_create_task (TASK_ENB_APP, eNB_app_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for eNB APP failed\n");
|
||||
|
||||
LOG_I(RRC,"Creating RRC eNB Task\n");
|
||||
rc = itti_create_task (TASK_RRC_ENB, rrc_enb_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for RRC eNB failed\n");
|
||||
|
||||
rrc_enb_init();
|
||||
itti_mark_task_ready(TASK_RRC_ENB);
|
||||
if (get_softmodem_params()->emulate_l1 || (EPC_MODE_ENABLED && split73 != SPLIT73_DU)) {
|
||||
rc = itti_create_task(TASK_SCTP, sctp_eNB_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for SCTP failed\n");
|
||||
@@ -89,11 +86,5 @@ int create_tasks(uint32_t enb_nb) {
|
||||
AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
|
||||
}
|
||||
|
||||
if (!NODE_IS_CU(type)) {
|
||||
LOG_I(MAC,"Creating MAC eNB Task\n");
|
||||
rc = itti_create_task(TASK_MAC_ENB, mac_enb_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for MAC eNB failed\n");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -482,6 +482,7 @@ int main ( int argc, char **argv )
|
||||
MessageDef *msg_p = itti_alloc_new_message (TASK_ENB_APP, 0, RRC_CONFIGURATION_REQ);
|
||||
RRC_CONFIGURATION_REQ(msg_p) = RC.rrc[enb_id]->configuration;
|
||||
itti_send_msg_to_task (TASK_RRC_ENB, ENB_MODULE_ID_TO_INSTANCE(enb_id), msg_p);
|
||||
rrc_enb_process_itti_msg(NULL);
|
||||
}
|
||||
node_type = RC.rrc[0]->node_type;
|
||||
}
|
||||
|
||||
+270
-275
File diff suppressed because it is too large
Load Diff
@@ -116,8 +116,8 @@ void read_config_and_init(void);
|
||||
int RCconfig_X2(MessageDef *msg_p, uint32_t i);
|
||||
int RCconfig_M2(MessageDef *msg_p, uint32_t i);
|
||||
|
||||
void fill_SL_configuration(MessageDef *msg_p, ccparams_sidelink_t *SLconfig,int cell_idx,int cc_idx,char *config_fname);
|
||||
void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, int cell_idx,int cc_idx,char *config_fname,char *brparamspath);
|
||||
void fill_SL_configuration(RrcConfigurationReq *RRCcfg, ccparams_sidelink_t *SLconfig, int cell_idx, int cc_idx, char *config_fname);
|
||||
void fill_eMTC_configuration(RrcConfigurationReq *RRCcfg, ccparams_eMTC_t *eMTCconfig, int cell_idx, int cc_idx, char *config_fname, char *brparamspath);
|
||||
|
||||
int RCconfig_DU_F1(MessageDef *msg_p, uint32_t i);
|
||||
void handle_f1ap_setup_resp(f1ap_setup_resp_t *resp);
|
||||
|
||||
+100
-100
@@ -40,254 +40,254 @@
|
||||
#include "enb_paramdef.h"
|
||||
#include "enb_paramdef_sidelink.h"
|
||||
|
||||
void fill_SL_configuration(MessageDef *msg_p, ccparams_sidelink_t *SLconfig,int cell_idx,int cc_idx,char *config_fname) {
|
||||
|
||||
void fill_SL_configuration(RrcConfigurationReq *RRCcfg, ccparams_sidelink_t *SLconfig, int cell_idx, int cc_idx, char *config_fname)
|
||||
{
|
||||
printf("Configuring SL\n");
|
||||
//SIB18
|
||||
if (strcmp(SLconfig->rxPool_sc_CP_Len,"normal")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
RRCcfg->rxPool_sc_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_CP_Len,"extended")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
RRCcfg->rxPool_sc_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for rxPool_sc_CP_Len choice: normal,extended!\n",
|
||||
config_fname, cell_idx, SLconfig->rxPool_sc_CP_Len);
|
||||
|
||||
if (strcmp(SLconfig->rxPool_sc_Period,"sf40")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf40;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf40;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf60")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf60;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf60;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf70")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf70;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf70;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf80")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf80;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf80;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf120")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf120;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf120;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf140")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf140;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf140;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf160")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf160;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf160;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf240")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf240;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf240;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf280")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf280;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf280;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"sf320")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf320;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_sf320;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare6")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare6;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare6;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare5")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare5;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare5;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare4")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare4;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare4;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare3")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare3;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare3;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare2")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare2;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare2;
|
||||
} else if (strcmp(SLconfig->rxPool_sc_Period,"spare")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare;
|
||||
RRCcfg->rxPool_sc_Period[cc_idx] = LTE_SL_PeriodComm_r12_spare;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for rxPool_sc_Period choice: sf40,sf60,sf70,sf80,sf120,sf140,sf160,sf240,sf280,sf320,spare6,spare5,spare4,spare3,spare2,spare!\n",
|
||||
config_fname, cell_idx, SLconfig->rxPool_sc_Period);
|
||||
|
||||
if (strcmp(SLconfig->rxPool_data_CP_Len,"normal")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_data_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
RRCcfg->rxPool_data_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
} else if (strcmp(SLconfig->rxPool_data_CP_Len,"extended")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_data_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
RRCcfg->rxPool_data_CP_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for rxPool_data_CP_Len choice: normal,extended!\n",
|
||||
config_fname, cell_idx, SLconfig->rxPool_data_CP_Len);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_prb_Num[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_Num;
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_prb_Start[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_Start;
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_prb_End[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_End;
|
||||
RRCcfg->rxPool_ResourceConfig_prb_Num[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_Num;
|
||||
RRCcfg->rxPool_ResourceConfig_prb_Start[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_Start;
|
||||
RRCcfg->rxPool_ResourceConfig_prb_End[cc_idx] = SLconfig->rxPool_ResourceConfig_prb_End;
|
||||
|
||||
if (strcmp(SLconfig->rxPool_ResourceConfig_offsetIndicator_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
RRCcfg->rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_offsetIndicator_present,"prSmall")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_offsetIndicator_present,"prLarge")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for rxPool_ResourceConfig_offsetIndicator_present choice: prNothing,prSmal,prLarge!\n",
|
||||
config_fname, cell_idx, SLconfig->rxPool_ResourceConfig_offsetIndicator_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->rxPool_ResourceConfig_offsetIndicator_choice;
|
||||
RRCcfg->rxPool_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->rxPool_ResourceConfig_offsetIndicator_choice;
|
||||
|
||||
if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs4")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs8")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs12")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs16")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs30")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs40")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
} else if (strcmp(SLconfig->rxPool_ResourceConfig_subframeBitmap_present,"prBs42")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for rxPool_ResourceConfig_subframeBitmap_present choice: prNothing,prBs4,prBs8,prBs12,prBs16,prBs30,prBs40,prBs42!\n",
|
||||
config_fname, cell_idx, SLconfig->rxPool_ResourceConfig_subframeBitmap_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRC_CONFIGURATION_REQ (msg_p).rxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRCcfg->rxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->rxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
|
||||
//SIB19 - for discRxPool
|
||||
if (strcmp(SLconfig->discRxPool_cp_Len,"normal")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
RRCcfg->discRxPool_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
} else if (strcmp(SLconfig->discRxPool_cp_Len,"extended")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
RRCcfg->discRxPool_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPool_cp_Len choice: normal,extended!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPool_cp_Len);
|
||||
|
||||
if (strcmp(SLconfig->discRxPool_discPeriod,"rf32")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf32;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf32;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf64")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf64;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf64;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf128")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf128;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf128;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf256")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf256;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf256;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf512")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf512;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf512;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf1024")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf1024;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf1024;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"rf16")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf16_v1310;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf16_v1310;
|
||||
} else if (strcmp(SLconfig->discRxPool_discPeriod,"spare")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_spare;
|
||||
RRCcfg->discRxPool_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_spare;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPool_discPeriod choice: rf32,rf64,rf128,rf512,rf1024,rf16,spare!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPool_discPeriod);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_numRetx[cc_idx] = SLconfig->discRxPool_numRetx;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_numRepetition[cc_idx] = SLconfig->discRxPool_numRepetition;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_prb_Num[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_Num;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_prb_Start[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_Start;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_prb_End[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_End;
|
||||
RRCcfg->discRxPool_numRetx[cc_idx] = SLconfig->discRxPool_numRetx;
|
||||
RRCcfg->discRxPool_numRepetition[cc_idx] = SLconfig->discRxPool_numRepetition;
|
||||
RRCcfg->discRxPool_ResourceConfig_prb_Num[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_Num;
|
||||
RRCcfg->discRxPool_ResourceConfig_prb_Start[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_Start;
|
||||
RRCcfg->discRxPool_ResourceConfig_prb_End[cc_idx] = SLconfig->discRxPool_ResourceConfig_prb_End;
|
||||
|
||||
if (strcmp(SLconfig->discRxPool_ResourceConfig_offsetIndicator_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
RRCcfg->discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_offsetIndicator_present,"prSmall")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_offsetIndicator_present,"prLarge")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPool_ResourceConfig_offsetIndicator_present choice: prNothing,prSmal,prLarge!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPool_ResourceConfig_offsetIndicator_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->discRxPool_ResourceConfig_offsetIndicator_choice;
|
||||
RRCcfg->discRxPool_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->discRxPool_ResourceConfig_offsetIndicator_choice;
|
||||
|
||||
if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs4")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs8")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs12")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs16")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs30")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs40")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
} else if (strcmp(SLconfig->discRxPool_ResourceConfig_subframeBitmap_present,"prBs42")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPool_ResourceConfig_subframeBitmap_present choice: prNothing,prBs4,prBs8,prBs12,prBs16,prBs30,prBs40,prBs42!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPool_ResourceConfig_subframeBitmap_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRCcfg->discRxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->discRxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
|
||||
//SIB19 - For discRxPoolPS
|
||||
if (strcmp(SLconfig->discRxPoolPS_cp_Len,"normal")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
RRCcfg->discRxPoolPS_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_normal;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_cp_Len,"extended")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
RRCcfg->discRxPoolPS_cp_Len[cc_idx] = LTE_SL_CP_Len_r12_extended;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPoolPS_cp_Len choice: normal,extended!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPoolPS_cp_Len);
|
||||
|
||||
if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf32")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf32;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf32;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf64")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf64;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf64;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf128")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf128;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf128;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf256")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf256;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf256;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf512")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf512;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf512;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf1024")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf1024;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf1024;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"rf16")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf16_v1310;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_rf16_v1310;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_discPeriod,"spare")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_spare;
|
||||
RRCcfg->discRxPoolPS_discPeriod[cc_idx] = LTE_SL_DiscResourcePool_r12__discPeriod_r12_spare;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPoolPS_discPeriod choice: rf32,rf64,rf128,rf512,rf1024,rf16,spare!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPoolPS_discPeriod);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_numRetx[cc_idx] = SLconfig->discRxPoolPS_numRetx;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_numRepetition[cc_idx] = SLconfig->discRxPoolPS_numRepetition;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_prb_Num[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_Num;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_prb_Start[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_Start;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_prb_End[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_End;
|
||||
RRCcfg->discRxPoolPS_numRetx[cc_idx] = SLconfig->discRxPoolPS_numRetx;
|
||||
RRCcfg->discRxPoolPS_numRepetition[cc_idx] = SLconfig->discRxPoolPS_numRepetition;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_prb_Num[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_Num;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_prb_Start[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_Start;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_prb_End[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_prb_End;
|
||||
|
||||
if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_present,"prSmall")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_small_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_present,"prLarge")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_offsetIndicator_present[cc_idx] = LTE_SL_OffsetIndicator_r12_PR_large_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPoolPS_ResourceConfig_offsetIndicator_present choice: prNothing,prSmal,prLarge!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_choice;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_offsetIndicator_choice[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_offsetIndicator_choice;
|
||||
|
||||
if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prNothing")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_NOTHING;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs4")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs4_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs8")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs8_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs12")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs12_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs16")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs16_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs30")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs30_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs40")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs40_r12;
|
||||
} else if (strcmp(SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present,"prBs42")==0) {
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_present[cc_idx] = LTE_SubframeBitmapSL_r12_PR_bs42_r12;
|
||||
} else
|
||||
AssertFatal (0,
|
||||
"Failed to parse eNB configuration file %s, enb %d unknown value \"%s\" for discRxPoolPS_ResourceConfig_subframeBitmap_present choice: prNothing,prBs4,prBs8,prBs12,prBs16,prBs30,prBs40,prBs42!\n",
|
||||
config_fname, cell_idx, SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_present);
|
||||
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRC_CONFIGURATION_REQ (msg_p).discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_buf[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_buf;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_size[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_size;
|
||||
RRCcfg->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_bits_unused[cc_idx] = SLconfig->discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_bits_unused;
|
||||
} // sidelink_configured==1
|
||||
|
||||
+325
-343
File diff suppressed because it is too large
Load Diff
@@ -353,12 +353,9 @@ int DU_handle_DL_RRC_MESSAGE_TRANSFER(instance_t instance,
|
||||
if (mac_MainConfig->drx_Config == NULL) {
|
||||
LOG_W(F1AP, "drx_Configuration parameter is NULL, cannot configure local UE parameters or CDRX is deactivated\n");
|
||||
} else {
|
||||
MessageDef *message_p = NULL;
|
||||
rrc_mac_drx_config_req_t req = {.rnti = ctxt.rntiMaybeUEid, .drx_Configuration = mac_MainConfig->drx_Config};
|
||||
/* Send DRX configuration to MAC task to configure timers of local UE context */
|
||||
message_p = itti_alloc_new_message(TASK_DU_F1, 0, RRC_MAC_DRX_CONFIG_REQ);
|
||||
RRC_MAC_DRX_CONFIG_REQ(message_p).rnti = ctxt.rntiMaybeUEid;
|
||||
RRC_MAC_DRX_CONFIG_REQ(message_p).drx_Configuration = mac_MainConfig->drx_Config;
|
||||
itti_send_msg_to_task(TASK_MAC_ENB, ctxt.instance, message_p);
|
||||
eNB_Config_Local_DRX(instance, &req);
|
||||
LOG_D(F1AP, "DRX configured in MAC Main Configuration for RRC Connection Reconfiguration\n");
|
||||
}
|
||||
|
||||
|
||||
@@ -470,7 +470,7 @@ check_ul_failure(module_id_t module_idP, int CC_id, int UE_id,
|
||||
if (UE_info->UE_sched_ctrl[UE_id].ul_failure_timer > 4000) {
|
||||
// note: probably ul_failure_timer should be less than UE radio link failure time(see T310/N310/N311)
|
||||
if (NODE_IS_DU(RC.rrc[module_idP]->node_type)) {
|
||||
MessageDef *m = itti_alloc_new_message(TASK_MAC_ENB, 0, F1AP_UE_CONTEXT_RELEASE_REQ);
|
||||
MessageDef *m = itti_alloc_new_message(TASK_PHY_ENB, 0, F1AP_UE_CONTEXT_RELEASE_REQ);
|
||||
F1AP_UE_CONTEXT_RELEASE_REQ(m).rnti = rnti;
|
||||
F1AP_UE_CONTEXT_RELEASE_REQ(m).cause = F1AP_CAUSE_RADIO_NETWORK;
|
||||
F1AP_UE_CONTEXT_RELEASE_REQ(m).cause_value = 1; // 1 = F1AP_CauseRadioNetwork_rl_failure
|
||||
|
||||
@@ -1396,10 +1396,16 @@ initiate_ra_proc(module_id_t module_idP,
|
||||
ra[i].RA_rnti = ra_rnti;
|
||||
ra[i].preamble_index = preamble_index;
|
||||
failure_cnt = 0;
|
||||
LOG_D(MAC,
|
||||
LOG_I(MAC,
|
||||
"[eNB %d][RAPROC] CC_id %d Frame %d Activating RAR generation in Frame %d, subframe %d for process %d, rnti %x, state %d\n",
|
||||
module_idP, CC_id, frameP, ra[i].Msg2_frame,
|
||||
ra[i].Msg2_subframe, i, ra[i].rnti, ra[i].state);
|
||||
module_idP,
|
||||
CC_id,
|
||||
frameP,
|
||||
ra[i].Msg2_frame,
|
||||
ra[i].Msg2_subframe,
|
||||
i,
|
||||
ra[i].rnti,
|
||||
ra[i].state);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3206,11 +3206,7 @@ void schedule_ulsch_rnti_fairRR(module_id_t module_idP,
|
||||
UE_template->nb_rb_ul[harq_pid] = rb_table[rb_table_index];
|
||||
UE_template->first_rb_ul[harq_pid] = first_rb[CC_id];
|
||||
UE_template->cqi_req[harq_pid] = cqi_req;
|
||||
UE_sched_ctrl->ul_scheduled |= (1<<harq_pid);
|
||||
|
||||
if (UE_id == UE_info->list.head)
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME(VCD_SIGNAL_DUMPER_VARIABLES_UE0_SCHEDULED,UE_sched_ctrl->ul_scheduled);
|
||||
|
||||
UE_sched_ctrl->ul_scheduled |= (1 << harq_pid);
|
||||
// adjust total UL buffer status by TBS, wait for UL sdus to do final update
|
||||
/*LOG_D(MAC,"[eNB %d] CC_id %d UE %d/%x : adjusting ul_total_buffer, old %d, TBS %d\n", module_idP,CC_id,UE_id,rnti,UE_template->ul_total_buffer,UE_template->TBS_UL[harq_pid]);
|
||||
if (UE_template->ul_total_buffer > UE_template->TBS_UL[harq_pid])
|
||||
|
||||
@@ -1989,12 +1989,11 @@ find_UE_id(module_id_t mod_idP,
|
||||
rnti_t rntiP)
|
||||
//------------------------------------------------------------------------------
|
||||
{
|
||||
int UE_id;
|
||||
UE_info_t *UE_info = &RC.mac[mod_idP]->UE_info;
|
||||
if(!UE_info)
|
||||
return -1;
|
||||
|
||||
for (UE_id = 0; UE_id < MAX_MOBILES_PER_ENB; UE_id++) {
|
||||
for (int UE_id = 0; UE_id < MAX_MOBILES_PER_ENB; UE_id++) {
|
||||
if (UE_info->active[UE_id] == true) {
|
||||
int CC_id = UE_PCCID(mod_idP, UE_id);
|
||||
if (CC_id>=0 && CC_id<NFAPI_CC_MAX && UE_info->UE_template[CC_id][UE_id].rnti == rntiP) {
|
||||
@@ -2144,6 +2143,7 @@ inline void add_ue_list(UE_list_t *listP, int UE_id) {
|
||||
while (*cur >= 0)
|
||||
cur = &listP->next[*cur];
|
||||
*cur = UE_id;
|
||||
LOG_D(MAC, "added UE %d in UE list\n", UE_id);
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
@@ -109,6 +109,7 @@ void lte_dump_mac_stats(eNB_MAC_INST *mac, FILE *fd)
|
||||
UE_info->eNB_UE_stats[CC_id][UE_id].dlsch_errors);
|
||||
}
|
||||
}
|
||||
fflush(fd);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -270,47 +271,3 @@ int l2_init_eNB(void)
|
||||
|
||||
return (1);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
/*
|
||||
* Main loop of MAC itti message handling
|
||||
*/
|
||||
void *mac_enb_task(void *arg)
|
||||
//-----------------------------------------------------------------------------
|
||||
{
|
||||
MessageDef *received_msg = NULL;
|
||||
int result;
|
||||
|
||||
itti_mark_task_ready(TASK_MAC_ENB); // void function 10/2019
|
||||
LOG_I(MAC,"Starting main loop of MAC message task\n");
|
||||
|
||||
while (1) {
|
||||
itti_receive_msg(TASK_MAC_ENB, &received_msg);
|
||||
|
||||
switch (ITTI_MSG_ID(received_msg)) {
|
||||
case RRC_MAC_DRX_CONFIG_REQ:
|
||||
LOG_I(MAC, "MAC Task Received RRC_MAC_DRX_CONFIG_REQ\n");
|
||||
/* Set timers and thresholds values in local MAC context of UE */
|
||||
eNB_Config_Local_DRX(ITTI_MSG_DESTINATION_INSTANCE(received_msg), &received_msg->ittiMsg.rrc_mac_drx_config_req);
|
||||
break;
|
||||
|
||||
case TERMINATE_MESSAGE:
|
||||
LOG_W(MAC, " *** Exiting MAC thread\n");
|
||||
itti_exit_task();
|
||||
break;
|
||||
|
||||
default:
|
||||
LOG_E(MAC, "MAC instance received unhandled message: %d:%s\n",
|
||||
ITTI_MSG_ID(received_msg),
|
||||
ITTI_MSG_NAME(received_msg));
|
||||
break;
|
||||
} // end switch
|
||||
|
||||
result = itti_free(ITTI_MSG_ORIGIN_ID(received_msg), received_msg);
|
||||
AssertFatal(result == EXIT_SUCCESS, "Failed to free memory (%d)!\n", result);
|
||||
|
||||
received_msg = NULL;
|
||||
} // end while
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
+68
-127
@@ -971,48 +971,50 @@ void release_UE_in_freeList(module_id_t mod_id) {
|
||||
|
||||
for(int ue_num = 0; ue_num < sizeofArray(eNB_MAC->UE_free_ctrl) ; ue_num++) {
|
||||
rnti_t rnti = eNB_MAC->UE_free_ctrl[ue_num].rnti;
|
||||
|
||||
if(rnti != 0) {
|
||||
if (!rnti)
|
||||
continue;
|
||||
protocol_ctxt_t ctxt;
|
||||
PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, mod_id, ENB_FLAG_YES, rnti, 0, 0,mod_id);
|
||||
PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, mod_id, ENB_FLAG_YES, rnti, 0, 0, mod_id);
|
||||
|
||||
for (int CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++) {
|
||||
eNB_PHY = RC.eNB[mod_id][CC_id];
|
||||
int id;
|
||||
// clean ULSCH entries for rnti
|
||||
id = find_ulsch(rnti,eNB_PHY,eNB_MAC->UE_free_ctrl[ue_num].raFlag ? SEARCH_EXIST_RA : SEARCH_EXIST);
|
||||
id = find_ulsch(rnti, eNB_PHY, eNB_MAC->UE_free_ctrl[ue_num].raFlag ? SEARCH_EXIST_RA : SEARCH_EXIST);
|
||||
|
||||
if (id>=0) clean_eNb_ulsch(eNB_PHY->ulsch[id]);
|
||||
if (id >= 0)
|
||||
clean_eNb_ulsch(eNB_PHY->ulsch[id]);
|
||||
|
||||
// clean DLSCH entries for rnti
|
||||
id = find_dlsch(rnti,eNB_PHY,eNB_MAC->UE_free_ctrl[ue_num].raFlag ? SEARCH_EXIST_RA : SEARCH_EXIST);
|
||||
id = find_dlsch(rnti, eNB_PHY, eNB_MAC->UE_free_ctrl[ue_num].raFlag ? SEARCH_EXIST_RA : SEARCH_EXIST);
|
||||
|
||||
if (id>=0) clean_eNb_dlsch(eNB_PHY->dlsch[id][0]);
|
||||
if (id >= 0)
|
||||
clean_eNb_dlsch(eNB_PHY->dlsch[id][0]);
|
||||
|
||||
// clean UCI entries for rnti
|
||||
for (int i=0; i<NUMBER_OF_UCI_MAX; i++) {
|
||||
if(eNB_PHY->uci_vars[i].rnti == rnti) {
|
||||
LOG_I(MAC, "clean eNb uci_vars[%d] UE %x \n",i, rnti);
|
||||
memset(&eNB_PHY->uci_vars[i],0,sizeof(LTE_eNB_UCI));
|
||||
for (int i = 0; i < NUMBER_OF_UCI_MAX; i++) {
|
||||
if (eNB_PHY->uci_vars[i].rnti == rnti) {
|
||||
LOG_I(MAC, "clean eNb uci_vars[%d] UE %x \n", i, rnti);
|
||||
memset(&eNB_PHY->uci_vars[i], 0, sizeof(LTE_eNB_UCI));
|
||||
}
|
||||
}
|
||||
|
||||
for(int j = 0; j < 10; j++) {
|
||||
nfapi_ul_config_request_body_t *ul_req_tmp = &eNB_MAC->UL_req_tmp[CC_id][j].ul_config_request_body;
|
||||
|
||||
if(ul_req_tmp) {
|
||||
if (ul_req_tmp) {
|
||||
int pdu_number = ul_req_tmp->number_of_pdus;
|
||||
|
||||
for(int pdu_index = pdu_number-1; pdu_index >= 0; pdu_index--) {
|
||||
if((ul_req_tmp->ul_config_pdu_list[pdu_index].ulsch_pdu.ulsch_pdu_rel8.rnti == rnti) ||
|
||||
(ul_req_tmp->ul_config_pdu_list[pdu_index].uci_harq_pdu.ue_information.ue_information_rel8.rnti == rnti) ||
|
||||
(ul_req_tmp->ul_config_pdu_list[pdu_index].uci_cqi_pdu.ue_information.ue_information_rel8.rnti == rnti) ||
|
||||
(ul_req_tmp->ul_config_pdu_list[pdu_index].uci_sr_pdu.ue_information.ue_information_rel8.rnti == rnti) ||
|
||||
(ul_req_tmp->ul_config_pdu_list[pdu_index].srs_pdu.srs_pdu_rel8.rnti == rnti)) {
|
||||
for (int pdu_index = pdu_number - 1; pdu_index >= 0; pdu_index--) {
|
||||
if ((ul_req_tmp->ul_config_pdu_list[pdu_index].ulsch_pdu.ulsch_pdu_rel8.rnti == rnti)
|
||||
|| (ul_req_tmp->ul_config_pdu_list[pdu_index].uci_harq_pdu.ue_information.ue_information_rel8.rnti == rnti)
|
||||
|| (ul_req_tmp->ul_config_pdu_list[pdu_index].uci_cqi_pdu.ue_information.ue_information_rel8.rnti == rnti)
|
||||
|| (ul_req_tmp->ul_config_pdu_list[pdu_index].uci_sr_pdu.ue_information.ue_information_rel8.rnti == rnti)
|
||||
|| (ul_req_tmp->ul_config_pdu_list[pdu_index].srs_pdu.srs_pdu_rel8.rnti == rnti)) {
|
||||
LOG_I(RRC, "remove UE %x from ul_config_pdu_list %d/%d\n", rnti, pdu_index, pdu_number);
|
||||
|
||||
if(pdu_index < pdu_number -1) {
|
||||
memcpy(&ul_req_tmp->ul_config_pdu_list[pdu_index], &ul_req_tmp->ul_config_pdu_list[pdu_index+1], (pdu_number-1-pdu_index) * sizeof(nfapi_ul_config_request_pdu_t));
|
||||
if (pdu_index < pdu_number - 1) {
|
||||
memcpy(&ul_req_tmp->ul_config_pdu_list[pdu_index], &ul_req_tmp->ul_config_pdu_list[pdu_index + 1], (pdu_number - 1 - pdu_index) * sizeof(nfapi_ul_config_request_pdu_t));
|
||||
}
|
||||
|
||||
ul_req_tmp->number_of_pdus--;
|
||||
@@ -1049,7 +1051,6 @@ void release_UE_in_freeList(module_id_t mod_id) {
|
||||
LOG_I(RRC, "[release_UE_in_freeList] remove UE %x from freeList ra context: %d\n", rnti, eNB_MAC->UE_free_ctrl[ue_num].raFlag);
|
||||
eNB_MAC->UE_free_ctrl[ue_num].rnti = 0;
|
||||
}
|
||||
}
|
||||
pthread_mutex_unlock(&lock_ue_freelist);
|
||||
}
|
||||
|
||||
@@ -2658,7 +2659,6 @@ void rrc_eNB_generate_defaultRRCConnectionReconfiguration(const protocol_ctxt_t
|
||||
uint8_t buffer[RRC_BUF_SIZE];
|
||||
uint16_t size;
|
||||
int i;
|
||||
MessageDef *message_p = NULL;
|
||||
/* Configure SRB1/SRB2, PhysicalConfigDedicated, LTE_MAC_MainConfig for UE */
|
||||
eNB_RRC_INST *rrc_inst = RC.rrc[ctxt_pP->module_id];
|
||||
struct LTE_PhysicalConfigDedicated **physicalConfigDedicated = &ue_context_pP->ue_context.physicalConfigDedicated;
|
||||
@@ -2854,10 +2854,8 @@ void rrc_eNB_generate_defaultRRCConnectionReconfiguration(const protocol_ctxt_t
|
||||
LOG_W(RRC, "drx_Configuration parameter is NULL, cannot configure local UE parameters or CDRX is deactivated\n");
|
||||
} else {
|
||||
/* Send DRX configuration to MAC task to configure timers of local UE context */
|
||||
message_p = itti_alloc_new_message(TASK_RRC_ENB, 0, RRC_MAC_DRX_CONFIG_REQ);
|
||||
RRC_MAC_DRX_CONFIG_REQ(message_p).rnti = rnti;
|
||||
RRC_MAC_DRX_CONFIG_REQ(message_p).drx_Configuration = mac_MainConfig->drx_Config;
|
||||
itti_send_msg_to_task(TASK_MAC_ENB, module_id, message_p);
|
||||
rrc_mac_drx_config_req_t req = {.rnti = rnti, .drx_Configuration = mac_MainConfig->drx_Config};
|
||||
eNB_Config_Local_DRX(module_id, &req);
|
||||
LOG_D(RRC, "DRX configured in MAC Main Configuration for RRC Connection Reconfiguration\n");
|
||||
}
|
||||
}
|
||||
@@ -5952,7 +5950,7 @@ rrc_eNB_decode_ccch(
|
||||
}
|
||||
|
||||
c_rnti = BIT_STRING_to_uint16(&rrcConnectionReestablishmentRequest->ue_Identity.c_RNTI);
|
||||
LOG_D(RRC, "c_rnti is %x\n", c_rnti);
|
||||
LOG_I(RRC, "reestablishment, previous c_rnti is %x (new is %x)\n", c_rnti, ctxt_pP->rnti);
|
||||
ue_context_p = rrc_eNB_get_ue_context(RC.rrc[ctxt_pP->module_id], c_rnti);
|
||||
|
||||
if (ue_context_p == NULL) {
|
||||
@@ -6008,7 +6006,7 @@ rrc_eNB_decode_ccch(
|
||||
if((RC.mac[ctxt_pP->module_id]->UE_info.UE_sched_ctrl[UE_id].ue_reestablishment_reject_timer > 0) &&
|
||||
(RC.mac[ctxt_pP->module_id]->UE_info.UE_sched_ctrl[UE_id].ue_reestablishment_reject_timer_thres > 20)) {
|
||||
LOG_E(RRC,
|
||||
PROTOCOL_RRC_CTXT_UE_FMT" RCConnectionReestablishmentComplete(Previous) don't receive, delete the Previous UE\n",
|
||||
PROTOCOL_RRC_CTXT_UE_FMT " RCConnectionReestablishmentComplete not received, but we get a new RRCConnectionReestablishmentRequest, we delete the Previous UE\n",
|
||||
PROTOCOL_RRC_CTXT_UE_ARGS(ctxt_pP));
|
||||
RC.mac[ctxt_pP->module_id]->UE_info.UE_sched_ctrl[UE_id].ue_reestablishment_reject_timer = 1000;
|
||||
rrc_eNB_previous_SRB2(ue_context_p);
|
||||
@@ -6027,10 +6025,9 @@ rrc_eNB_decode_ccch(
|
||||
|
||||
if(ue_context_p->ue_context.ue_reestablishment_timer > 0) {
|
||||
LOG_E(RRC,
|
||||
PROTOCOL_RRC_CTXT_UE_FMT" RRRCConnectionReconfigurationComplete(Previous) don't receive, delete the Previous UE,\nprevious Status %d, new Status RRC_RECONFIGURED\n",
|
||||
PROTOCOL_RRC_CTXT_UE_FMT " RRRCConnectionReconfigurationComplete not received, delete the Previous UE,\nprevious Status %d, new Status RRC_RECONFIGURED\n",
|
||||
PROTOCOL_RRC_CTXT_UE_ARGS(ctxt_pP),
|
||||
ue_context_p->ue_context.StatusRrc
|
||||
);
|
||||
ue_context_p->ue_context.StatusRrc);
|
||||
ue_context_p->ue_context.StatusRrc = RRC_RECONFIGURED;
|
||||
protocol_ctxt_t ctxt_old_p;
|
||||
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt_old_p,
|
||||
@@ -8082,13 +8079,14 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
protocol_ctxt_t ctxt;
|
||||
memset(&ctxt, 0, sizeof(ctxt));
|
||||
// Wait for a message
|
||||
itti_receive_msg(TASK_RRC_ENB, &msg_p);
|
||||
itti_poll_msg(TASK_RRC_ENB, &msg_p);
|
||||
while (msg_p) {
|
||||
msg_name_p = ITTI_MSG_NAME(msg_p);
|
||||
instance = ITTI_MSG_DESTINATION_INSTANCE(msg_p);
|
||||
|
||||
/* RRC_SUBFRAME_PROCESS is sent every subframe, do not log it */
|
||||
if (ITTI_MSG_ID(msg_p) != RRC_SUBFRAME_PROCESS)
|
||||
LOG_D(RRC,"Received message %s\n",msg_name_p);
|
||||
LOG_D(RRC, "Received message %s\n", msg_name_p);
|
||||
|
||||
switch (ITTI_MSG_ID(msg_p)) {
|
||||
case TERMINATE_MESSAGE:
|
||||
@@ -8102,51 +8100,28 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
|
||||
/* Messages from MAC */
|
||||
case RRC_MAC_CCCH_DATA_IND:
|
||||
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).enb_index,
|
||||
ENB_FLAG_YES,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).rnti,
|
||||
msg_p->ittiMsgHeader.lte_time.frame,
|
||||
msg_p->ittiMsgHeader.lte_time.slot);
|
||||
LOG_I(RRC,"Decoding CCCH : inst %ld, CC_id %d, ctxt %p, sib_info_p->Rx_buffer.payload_size %d\n",
|
||||
instance,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).CC_id,
|
||||
&ctxt,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size);
|
||||
PROTOCOL_CTXT_SET_BY_INSTANCE(
|
||||
&ctxt, RRC_MAC_CCCH_DATA_IND(msg_p).enb_index, ENB_FLAG_YES, RRC_MAC_CCCH_DATA_IND(msg_p).rnti, msg_p->ittiMsgHeader.lte_time.frame, msg_p->ittiMsgHeader.lte_time.slot);
|
||||
LOG_I(RRC, "Decoding CCCH : inst %ld, CC_id %d, ctxt %p, sib_info_p->Rx_buffer.payload_size %d\n", instance, RRC_MAC_CCCH_DATA_IND(msg_p).CC_id, &ctxt, RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size);
|
||||
|
||||
if (RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size >= CCCH_SDU_SIZE) {
|
||||
LOG_I(RRC, "CCCH message has size %d > %d\n",
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size,CCCH_SDU_SIZE);
|
||||
LOG_I(RRC, "CCCH message has size %d > %d\n", RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size, CCCH_SDU_SIZE);
|
||||
break;
|
||||
}
|
||||
|
||||
rrc_eNB_decode_ccch(&ctxt,
|
||||
(uint8_t *)RRC_MAC_CCCH_DATA_IND(msg_p).sdu,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size,
|
||||
RRC_MAC_CCCH_DATA_IND(msg_p).CC_id);
|
||||
rrc_eNB_decode_ccch(&ctxt, (uint8_t *)RRC_MAC_CCCH_DATA_IND(msg_p).sdu, RRC_MAC_CCCH_DATA_IND(msg_p).sdu_size, RRC_MAC_CCCH_DATA_IND(msg_p).CC_id);
|
||||
break;
|
||||
|
||||
/* Messages from PDCP */
|
||||
case RRC_DCCH_DATA_IND:
|
||||
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt,
|
||||
instance,
|
||||
ENB_FLAG_YES,
|
||||
RRC_DCCH_DATA_IND(msg_p).rnti,
|
||||
msg_p->ittiMsgHeader.lte_time.frame,
|
||||
msg_p->ittiMsgHeader.lte_time.slot);
|
||||
LOG_D(RRC, PROTOCOL_RRC_CTXT_UE_FMT" Received on DCCH %d %s\n",
|
||||
PROTOCOL_RRC_CTXT_UE_ARGS(&ctxt),
|
||||
RRC_DCCH_DATA_IND(msg_p).dcch_index,
|
||||
msg_name_p);
|
||||
rrc_eNB_decode_dcch(&ctxt,
|
||||
RRC_DCCH_DATA_IND(msg_p).dcch_index,
|
||||
RRC_DCCH_DATA_IND(msg_p).sdu_p,
|
||||
RRC_DCCH_DATA_IND(msg_p).sdu_size);
|
||||
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt, instance, ENB_FLAG_YES, RRC_DCCH_DATA_IND(msg_p).rnti, msg_p->ittiMsgHeader.lte_time.frame, msg_p->ittiMsgHeader.lte_time.slot);
|
||||
LOG_D(RRC, PROTOCOL_RRC_CTXT_UE_FMT " Received on DCCH %d %s\n", PROTOCOL_RRC_CTXT_UE_ARGS(&ctxt), RRC_DCCH_DATA_IND(msg_p).dcch_index, msg_name_p);
|
||||
rrc_eNB_decode_dcch(&ctxt, RRC_DCCH_DATA_IND(msg_p).dcch_index, RRC_DCCH_DATA_IND(msg_p).sdu_p, RRC_DCCH_DATA_IND(msg_p).sdu_size);
|
||||
// Message buffer has been processed, free it now.
|
||||
result = itti_free(ITTI_MSG_ORIGIN_ID(msg_p), RRC_DCCH_DATA_IND(msg_p).sdu_p);
|
||||
|
||||
if (result != EXIT_SUCCESS) {
|
||||
LOG_I(RRC, "Failed to free memory (%d)!\n",result);
|
||||
LOG_I(RRC, "Failed to free memory (%d)!\n", result);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -8218,15 +8193,15 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
|
||||
if (ue_context_p == NULL) {
|
||||
/* is it possible? */
|
||||
LOG_E(RRC, "could not find UE (rnti %x) while processing X2AP_HANDOVER_REQ_ACK\n",
|
||||
X2AP_HANDOVER_REQ_ACK(msg_p).rnti);
|
||||
LOG_E(RRC, "could not find UE (rnti %x) while processing X2AP_HANDOVER_REQ_ACK\n", X2AP_HANDOVER_REQ_ACK(msg_p).rnti);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
LOG_I(RRC, "[eNB %ld] source eNB receives the X2 HO ACK %s\n", instance, msg_name_p);
|
||||
DevAssert(ue_context_p != NULL);
|
||||
|
||||
if (ue_context_p->ue_context.handover_info->state != HO_REQUEST) abort();
|
||||
if (ue_context_p->ue_context.handover_info->state != HO_REQUEST)
|
||||
abort();
|
||||
|
||||
hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, ue_context_p->ue_context.rnti, (void **)>pv1u_ue_data_p);
|
||||
|
||||
@@ -8242,26 +8217,22 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
nb_e_rabs_tobesetup = x2ap_handover_req_ack->nb_e_rabs_tobesetup;
|
||||
ue_context_p->ue_context.nb_x2u_e_rabs = nb_e_rabs_tobesetup;
|
||||
|
||||
for(int i=0; i< nb_e_rabs_tobesetup; i++) {
|
||||
for (int i = 0; i < nb_e_rabs_tobesetup; i++) {
|
||||
ip_offset = 0;
|
||||
eps_bearer_id = x2ap_handover_req_ack->e_rabs_tobesetup[i].e_rab_id;
|
||||
ue_context_p->ue_context.enb_gtp_x2u_ebi[i] = eps_bearer_id;
|
||||
ue_context_p->ue_context.enb_gtp_x2u_teid[i] = x2ap_handover_req_ack->e_rabs_tobesetup[i].gtp_teid;
|
||||
gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_teNB = x2ap_handover_req_ack->e_rabs_tobesetup[i].gtp_teid;
|
||||
|
||||
if ((x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 4) ||
|
||||
(x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 20)) {
|
||||
if ((x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 4) || (x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 20)) {
|
||||
in_addr = *((in_addr_t *)x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.buffer);
|
||||
ip_offset = 4;
|
||||
gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].tenb_ip_addr = in_addr;
|
||||
ue_context_p->ue_context.enb_gtp_x2u_addrs[i] = x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr;
|
||||
}
|
||||
|
||||
if ((x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 16) ||
|
||||
(x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 20)) {
|
||||
memcpy(gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].tenb_ip6_addr.s6_addr,
|
||||
&x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.buffer[ip_offset],
|
||||
16);
|
||||
if ((x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 16) || (x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.length == 20)) {
|
||||
memcpy(gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].tenb_ip6_addr.s6_addr, &x2ap_handover_req_ack->e_rabs_tobesetup[i].eNB_addr.buffer[ip_offset], 16);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -8277,7 +8248,8 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
LOG_I(RRC, "[eNB %ld] source eNB receives the X2 UE CONTEXT RELEASE %s\n", instance, msg_name_p);
|
||||
DevAssert(ue_context_p != NULL);
|
||||
|
||||
if (ue_context_p->ue_context.handover_info->state != HO_COMPLETE) abort();
|
||||
if (ue_context_p->ue_context.handover_info->state != HO_COMPLETE)
|
||||
abort();
|
||||
|
||||
ue_context_p->ue_context.handover_info->state = HO_RELEASE;
|
||||
break;
|
||||
@@ -8303,13 +8275,8 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
|
||||
ue_context_p = rrc_eNB_get_ue_context(RC.rrc[instance], X2AP_HANDOVER_CANCEL(msg_p).rnti);
|
||||
|
||||
if (ue_context_p != NULL &&
|
||||
ue_context_p->ue_context.handover_info != NULL) {
|
||||
LOG_I(RRC, "[eNB %ld] eNB receives X2 HANDOVER CANCEL for rnti %x, cause %s [%s]\n",
|
||||
instance,
|
||||
X2AP_HANDOVER_CANCEL(msg_p).rnti,
|
||||
cause,
|
||||
msg_name_p);
|
||||
if (ue_context_p != NULL && ue_context_p->ue_context.handover_info != NULL) {
|
||||
LOG_I(RRC, "[eNB %ld] eNB receives X2 HANDOVER CANCEL for rnti %x, cause %s [%s]\n", instance, X2AP_HANDOVER_CANCEL(msg_p).rnti, cause, msg_name_p);
|
||||
|
||||
if (X2AP_HANDOVER_CANCEL(msg_p).cause == X2AP_T_RELOC_PREP_TIMEOUT) {
|
||||
/* for prep timeout, simply return to normal state */
|
||||
@@ -8330,8 +8297,7 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
else
|
||||
failure_cause = "UE not in handover";
|
||||
|
||||
LOG_W(RRC, "[eNB %ld] cannot process (%s) X2 HANDOVER CANCEL for rnti %x, cause %s, ignoring\n",
|
||||
instance, failure_cause, X2AP_HANDOVER_CANCEL(msg_p).rnti, cause);
|
||||
LOG_W(RRC, "[eNB %ld] cannot process (%s) X2 HANDOVER CANCEL for rnti %x, cause %s, ignoring\n", instance, failure_cause, X2AP_HANDOVER_CANCEL(msg_p).rnti, cause);
|
||||
}
|
||||
|
||||
break;
|
||||
@@ -8364,9 +8330,8 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
|
||||
/* Messages from F1AP task */
|
||||
case F1AP_SETUP_REQ:
|
||||
AssertFatal(NODE_IS_CU(RC.rrc[instance]->node_type),
|
||||
"should not receive F1AP_SETUP_REQUEST, need call by CU!\n");
|
||||
LOG_I(RRC,"[eNB %ld] Received %s : %p\n", instance, msg_name_p, &F1AP_SETUP_REQ(msg_p));
|
||||
AssertFatal(NODE_IS_CU(RC.rrc[instance]->node_type), "should not receive F1AP_SETUP_REQUEST, need call by CU!\n");
|
||||
LOG_I(RRC, "[eNB %ld] Received %s : %p\n", instance, msg_name_p, &F1AP_SETUP_REQ(msg_p));
|
||||
handle_f1_setup_req(&F1AP_SETUP_REQ(msg_p));
|
||||
break;
|
||||
|
||||
@@ -8375,47 +8340,43 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
break;
|
||||
|
||||
case M2AP_SETUP_RESP:
|
||||
rrc_eNB_process_M2AP_SETUP_RESP(&ctxt,0/*CC_id*/,ENB_INSTANCE_TO_MODULE_ID(instance),&M2AP_SETUP_RESP(msg_p));
|
||||
rrc_eNB_process_M2AP_SETUP_RESP(&ctxt, 0 /*CC_id*/, ENB_INSTANCE_TO_MODULE_ID(instance), &M2AP_SETUP_RESP(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_MBMS_SCHEDULING_INFORMATION:
|
||||
rrc_eNB_process_M2AP_MBMS_SCHEDULING_INFORMATION(&ctxt,0/*CC_id*/,ENB_INSTANCE_TO_MODULE_ID(instance),&M2AP_MBMS_SCHEDULING_INFORMATION(msg_p));
|
||||
rrc_eNB_process_M2AP_MBMS_SCHEDULING_INFORMATION(&ctxt, 0 /*CC_id*/, ENB_INSTANCE_TO_MODULE_ID(instance), &M2AP_MBMS_SCHEDULING_INFORMATION(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_MBMS_SESSION_START_REQ:
|
||||
rrc_eNB_process_M2AP_MBMS_SESSION_START_REQ(&ctxt,0/*CC_id*/,ENB_INSTANCE_TO_MODULE_ID(instance),&M2AP_MBMS_SESSION_START_REQ(msg_p));
|
||||
rrc_eNB_process_M2AP_MBMS_SESSION_START_REQ(&ctxt, 0 /*CC_id*/, ENB_INSTANCE_TO_MODULE_ID(instance), &M2AP_MBMS_SESSION_START_REQ(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_MBMS_SESSION_STOP_REQ:
|
||||
rrc_eNB_process_M2AP_MBMS_SESSION_STOP_REQ(&ctxt,&M2AP_MBMS_SESSION_STOP_REQ(msg_p));
|
||||
rrc_eNB_process_M2AP_MBMS_SESSION_STOP_REQ(&ctxt, &M2AP_MBMS_SESSION_STOP_REQ(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_RESET:
|
||||
rrc_eNB_process_M2AP_RESET(&ctxt,&M2AP_RESET(msg_p));
|
||||
rrc_eNB_process_M2AP_RESET(&ctxt, &M2AP_RESET(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_ENB_CONFIGURATION_UPDATE_ACK:
|
||||
rrc_eNB_process_M2AP_ENB_CONFIGURATION_UPDATE_ACK(&ctxt,&M2AP_ENB_CONFIGURATION_UPDATE_ACK(msg_p));
|
||||
rrc_eNB_process_M2AP_ENB_CONFIGURATION_UPDATE_ACK(&ctxt, &M2AP_ENB_CONFIGURATION_UPDATE_ACK(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_ERROR_INDICATION:
|
||||
rrc_eNB_process_M2AP_ERROR_INDICATION(&ctxt,&M2AP_ERROR_INDICATION(msg_p));
|
||||
rrc_eNB_process_M2AP_ERROR_INDICATION(&ctxt, &M2AP_ERROR_INDICATION(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_MBMS_SERVICE_COUNTING_REQ:
|
||||
rrc_eNB_process_M2AP_MBMS_SERVICE_COUNTING_REQ(&ctxt,&M2AP_MBMS_SERVICE_COUNTING_REQ(msg_p));
|
||||
rrc_eNB_process_M2AP_MBMS_SERVICE_COUNTING_REQ(&ctxt, &M2AP_MBMS_SERVICE_COUNTING_REQ(msg_p));
|
||||
break;
|
||||
|
||||
case M2AP_MCE_CONFIGURATION_UPDATE:
|
||||
rrc_eNB_process_M2AP_MCE_CONFIGURATION_UPDATE(&ctxt,&M2AP_MCE_CONFIGURATION_UPDATE(msg_p));
|
||||
rrc_eNB_process_M2AP_MCE_CONFIGURATION_UPDATE(&ctxt, &M2AP_MCE_CONFIGURATION_UPDATE(msg_p));
|
||||
break;
|
||||
|
||||
case RLC_SDU_INDICATION:
|
||||
process_rlc_sdu_indication(instance,
|
||||
RLC_SDU_INDICATION(msg_p).rnti,
|
||||
RLC_SDU_INDICATION(msg_p).is_successful,
|
||||
RLC_SDU_INDICATION(msg_p).srb_id,
|
||||
RLC_SDU_INDICATION(msg_p).message_id);
|
||||
process_rlc_sdu_indication(instance, RLC_SDU_INDICATION(msg_p).rnti, RLC_SDU_INDICATION(msg_p).is_successful, RLC_SDU_INDICATION(msg_p).srb_id, RLC_SDU_INDICATION(msg_p).message_id);
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -8426,32 +8387,11 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
|
||||
result = itti_free(ITTI_MSG_ORIGIN_ID(msg_p), msg_p);
|
||||
|
||||
if (result != EXIT_SUCCESS) {
|
||||
LOG_I(RRC, "Failed to free memory (%d)!\n",result);
|
||||
}
|
||||
|
||||
msg_p = NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
void *
|
||||
rrc_enb_task(
|
||||
void *args_p
|
||||
)
|
||||
//-----------------------------------------------------------------------------
|
||||
{
|
||||
rrc_enb_init();
|
||||
itti_mark_task_ready(TASK_RRC_ENB);
|
||||
LOG_I(RRC,"Entering main loop of RRC message task\n");
|
||||
|
||||
while (1) {
|
||||
(void) rrc_enb_process_itti_msg(NULL);
|
||||
{
|
||||
//extern volatile int go_nr;
|
||||
void rrc_go_nr(void);
|
||||
//if (go_nr) rrc_go_nr();
|
||||
LOG_I(RRC, "Failed to free memory (%d)!\n", result);
|
||||
}
|
||||
itti_poll_msg(TASK_RRC_ENB, &msg_p);
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------*/
|
||||
@@ -8799,5 +8739,6 @@ rrc_rx_tx(
|
||||
RRC_SUBFRAME_PROCESS(message_p).ctxt = *ctxt_pP;
|
||||
RRC_SUBFRAME_PROCESS(message_p).CC_id = CC_id;
|
||||
itti_send_msg_to_task(TASK_RRC_ENB, ctxt_pP->module_id, message_p);
|
||||
rrc_enb_process_itti_msg(NULL);
|
||||
return RRC_OK;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user