Commit 46b0a9fb authored by Louis Adrien Dufrene's avatar Louis Adrien Dufrene

Remove bypass_cdrx variable and add cdrx_waiting_ack. The CDRX is now...

Remove bypass_cdrx variable and add cdrx_waiting_ack. The CDRX is now activated at RRC COnnection Reconfiguration Complete reception. To Test
parent 62fba7c0
...@@ -1059,8 +1059,8 @@ void eNB_Config_Local_DRX( ...@@ -1059,8 +1059,8 @@ void eNB_Config_Local_DRX(
} }
/* Modify scheduling control structure according to DRX configuration: doesn't support every configurations! */ /* Modify scheduling control structure according to DRX configuration: doesn't support every configurations! */
UE_scheduling_control->cdrx_configured = TRUE; UE_scheduling_control->cdrx_configured = FALSE; // will be set to true when ACK is received
UE_scheduling_control->bypass_cdrx = TRUE; // set to true first, waiting for the UE to configure CDRX on its side UE_scheduling_control->cdrx_waiting_ack = TRUE; // set to true first, waiting for the UE to configure CDRX on its side
UE_scheduling_control->in_active_time = FALSE; UE_scheduling_control->in_active_time = FALSE;
UE_scheduling_control->on_duration_timer = 0; UE_scheduling_control->on_duration_timer = 0;
......
...@@ -1013,11 +1013,11 @@ typedef struct { ...@@ -1013,11 +1013,11 @@ typedef struct {
/// is TRUE if the following drx parameters are configured for UE /// is TRUE if the following drx parameters are configured for UE
boolean_t cdrx_configured; boolean_t cdrx_configured;
/* /*
* if TRUE, the scheduler should bypass in_active_time and consider the UE as active * if TRUE, the eNB has configured the CDRX locally, but is waiting for the UE to acknowledge
* This can be needed, especially during the RRC configuration process, when the context is * the activation. This is needed, during the RRC configuration process, when the context is
* configured on the eNB side, but not yet on the UE side... * configured on the eNB side, but not yet on the UE side...
*/ */
boolean_t bypass_cdrx; boolean_t cdrx_waiting_ack;
/// is TRUE if the UE is in "Active Time", hence listening to PDCCH /// is TRUE if the UE is in "Active Time", hence listening to PDCCH
boolean_t in_active_time; boolean_t in_active_time;
/// OnDurationTimer /// OnDurationTimer
......
...@@ -480,7 +480,7 @@ void sort_UEs(module_id_t Mod_idP, ...@@ -480,7 +480,7 @@ void sort_UEs(module_id_t Mod_idP,
/* Check CDRX configuration and if UE is in active time for this subframe */ /* Check CDRX configuration and if UE is in active time for this subframe */
if (UE_scheduling_control->cdrx_configured == TRUE) { if (UE_scheduling_control->cdrx_configured == TRUE) {
if ((UE_scheduling_control->bypass_cdrx == FALSE) && (UE_scheduling_control->in_active_time == FALSE)) { if (UE_scheduling_control->in_active_time == FALSE) {
continue; continue;
} }
} }
...@@ -2017,7 +2017,7 @@ void sort_ue_ul(module_id_t module_idP, ...@@ -2017,7 +2017,7 @@ void sort_ue_ul(module_id_t module_idP,
/* Check CDRX configuration and if UE is in active time for this subframe */ /* Check CDRX configuration and if UE is in active time for this subframe */
if (UE_scheduling_control->cdrx_configured == TRUE) { if (UE_scheduling_control->cdrx_configured == TRUE) {
if ((UE_scheduling_control->bypass_cdrx == FALSE) && (UE_scheduling_control->in_active_time == FALSE)) { if (UE_scheduling_control->in_active_time == FALSE) {
continue; continue;
} }
} }
......
...@@ -5474,9 +5474,14 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete( ...@@ -5474,9 +5474,14 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
ue_context_pP->ue_context.ue_reestablishment_timer = 0; ue_context_pP->ue_context.ue_reestablishment_timer = 0;
ue_context_pP->ue_context.ue_rrc_inactivity_timer = 1; // reset rrc inactivity timer ue_context_pP->ue_context.ue_rrc_inactivity_timer = 1; // reset rrc inactivity timer
/* CDRX: activated because acknowledged */ /* CDRX: activated if ack was expected */
int UE_id_mac = find_UE_id(ctxt_pP->module_id, ue_context_pP->ue_context.rnti); int UE_id_mac = find_UE_id(ctxt_pP->module_id, ue_context_pP->ue_context.rnti);
RC.mac[ctxt_pP->module_id]->UE_list.UE_sched_ctrl[UE_id_mac].bypass_cdrx = FALSE; UE_sched_ctrl *UE_scheduling_control = &(RC.mac[ctxt_pP->module_id]->UE_list.UE_sched_ctrl[UE_id_mac])
if (UE_scheduling_control.cdrx_waiting_ack) == TRUE {
UE_scheduling_control.cdrx_waiting_ack = FALSE;
UE_scheduling_control.cdrx_configured = TRUE;
}
T(T_ENB_RRC_CONNECTION_RECONFIGURATION_COMPLETE, T(T_ENB_RRC_CONNECTION_RECONFIGURATION_COMPLETE,
T_INT(ctxt_pP->module_id), T_INT(ctxt_pP->module_id),
......
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