Commit bc5677f4 authored by Melissa Elkadi's avatar Melissa Elkadi

Triggering works, not using OAI mechanism

gNB is crashing when setting up the tunnel interface
between the NR UE and itself.
parent 63ca5f69
...@@ -4436,6 +4436,10 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint ...@@ -4436,6 +4436,10 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint
LTE_MeasObjectId_t measObjId; LTE_MeasObjectId_t measObjId;
LTE_ReportConfigId_t reportConfigId; LTE_ReportConfigId_t reportConfigId;
UE_RRC_INST *ue = &UE_rrc_inst[ctxt_pP->module_id]; UE_RRC_INST *ue = &UE_rrc_inst[ctxt_pP->module_id];
bool is_in_period = false;
bool is_state_connected = false;
bool is_t304_inactive = false;
bool have_meas_flag = false;
for(i=0 ; i<NB_CNX_UE ; i++) { for(i=0 ; i<NB_CNX_UE ; i++) {
for(j=0 ; j<MAX_MEAS_ID ; j++) { for(j=0 ; j<MAX_MEAS_ID ; j++) {
if(ue->MeasId[i][j] != NULL) { if(ue->MeasId[i][j] != NULL) {
...@@ -4527,15 +4531,24 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint ...@@ -4527,15 +4531,24 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint
if (!does_rrcConnReconfig_have_nr(ue)) if (!does_rrcConnReconfig_have_nr(ue))
break; break;
LTE_TimeToTrigger_t trig_per = ue->ReportConfig[i][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.triggerType.choice.event.timeToTrigger; LTE_TimeToTrigger_t trig_per = ue->ReportConfig[i][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.triggerType.choice.event.timeToTrigger;
hys = ue->ReportConfig[i][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.triggerType.choice.event.hysteresis;
ttt_ms = timeToTrigger_ms[trig_per]; ttt_ms = timeToTrigger_ms[trig_per];
bool is_in_period = check_trigger_meas_event(ctxt_pP->module_id, LOG_I(RRC, "[UE %d] Frame %d: B1_NR_r15 event. nr_meas %d, period %d, state %d, t304 %d, measfalg %d count %ld, ttt %ld\n",
ctxt_pP->frame, ctxt_pP->module_id, ctxt_pP->frame,
eNB_index, does_rrcConnReconfig_have_nr(ue),
i, j, 5, 0, hys, 0, 0, ttt_ms); is_in_period,
bool is_state_connected = false; is_state_connected,
bool is_t304_inactive = false; is_t304_inactive,
bool have_meas_flag = false; have_meas_flag,
ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount,
ttt_ms);
if (ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount < ttt_ms) {
ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount = ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount + 1;
break;
}
else {
ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount = 0;
is_in_period = true;
}
if (ue->Info[0].State >= RRC_CONNECTED) if (ue->Info[0].State >= RRC_CONNECTED)
is_state_connected = true; is_state_connected = true;
if (ue->Info[0].T304_active == 0) if (ue->Info[0].T304_active == 0)
...@@ -4543,17 +4556,9 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint ...@@ -4543,17 +4556,9 @@ void ue_measurement_report_triggering(protocol_ctxt_t *const ctxt_pP, const uint
if (ue->HandoverInfoUe.measFlag == 1); if (ue->HandoverInfoUe.measFlag == 1);
have_meas_flag = true; have_meas_flag = true;
LOG_I(RRC,"[UE %d] Frame %d: B1_NR_r15 event. nr_meas %d, period %d, state %d, t304 %d, measfalg %d \n",
ctxt_pP->module_id, ctxt_pP->frame,
does_rrcConnReconfig_have_nr(ue),
is_in_period,
is_state_connected,
is_t304_inactive,
have_meas_flag);
if (does_rrcConnReconfig_have_nr(ue) && is_in_period && is_state_connected && is_t304_inactive && have_meas_flag) { if (does_rrcConnReconfig_have_nr(ue) && is_in_period && is_state_connected && is_t304_inactive && have_meas_flag) {
LOG_I(RRC,"[UE %d] Frame %d: Triggering generation of Meas Report for NR_r15\n", LOG_I(RRC,"[UE %d] MELISSA ELAKDI! Frame %d: Triggering generation of Meas Report for NR_r15. count = %d\n",
ctxt_pP->module_id, ctxt_pP->frame); ctxt_pP->module_id, ctxt_pP->frame, ue->ReportConfig[eNB_index][reportConfigId-1]->reportConfig.choice.reportConfigInterRAT.subframeCount);
if (ue->measReportList[i][j] == NULL) { if (ue->measReportList[i][j] == NULL) {
ue->measReportList[i][j] = malloc(sizeof(MEAS_REPORT_LIST)); ue->measReportList[i][j] = malloc(sizeof(MEAS_REPORT_LIST));
......
...@@ -3451,6 +3451,7 @@ void rrc_eNB_generate_defaultRRCConnectionReconfiguration(const protocol_ctxt_t ...@@ -3451,6 +3451,7 @@ void rrc_eNB_generate_defaultRRCConnectionReconfiguration(const protocol_ctxt_t
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.triggerType.choice.event.timeToTrigger = LTE_TimeToTrigger_ms80; ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.triggerType.choice.event.timeToTrigger = LTE_TimeToTrigger_ms80;
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.maxReportCells = 4; ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.maxReportCells = 4;
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.reportInterval = LTE_ReportInterval_ms120; ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.reportInterval = LTE_ReportInterval_ms120;
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.subframeCount = 0;
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.reportAmount = LTE_ReportConfigInterRAT__reportAmount_infinity; ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.reportAmount = LTE_ReportConfigInterRAT__reportAmount_infinity;
ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.ext7 = calloc(1, sizeof(struct LTE_ReportConfigInterRAT__ext7)); ReportConfig_NR->reportConfig.choice.reportConfigInterRAT.ext7 = calloc(1, sizeof(struct LTE_ReportConfigInterRAT__ext7));
......
...@@ -1731,7 +1731,7 @@ int x2ap_eNB_generate_ENDC_x2_SgNB_addition_request( ...@@ -1731,7 +1731,7 @@ int x2ap_eNB_generate_ENDC_x2_SgNB_addition_request(
X2AP_ERROR("Failed to encode ENDC X2 SgNB_addition request message\n"); X2AP_ERROR("Failed to encode ENDC X2 SgNB_addition request message\n");
return -1; return -1;
} }
free(ie->value.choice.MeNBtoSgNBContainer.buf); //free(ie->value.choice.MeNBtoSgNBContainer.buf);
MSC_LOG_TX_MESSAGE (MSC_X2AP_SRC_ENB, MSC_X2AP_TARGET_ENB, NULL, 0, "0 X2Setup/initiatingMessage assoc_id %u", x2ap_eNB_data_p->assoc_id); MSC_LOG_TX_MESSAGE (MSC_X2AP_SRC_ENB, MSC_X2AP_TARGET_ENB, NULL, 0, "0 X2Setup/initiatingMessage assoc_id %u", x2ap_eNB_data_p->assoc_id);
x2ap_eNB_itti_send_sctp_data_req(instance_p->instance, x2ap_eNB_data_p->assoc_id, buffer, len, 0); x2ap_eNB_itti_send_sctp_data_req(instance_p->instance, x2ap_eNB_data_p->assoc_id, buffer, len, 0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment