fix indentation and removing an if in scheduler
This commit is contained in:
@@ -321,67 +321,65 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
|
|||||||
// Check if there are downlink symbols in the slot,
|
// Check if there are downlink symbols in the slot,
|
||||||
if (is_nr_DL_slot(cc->ServingCellConfigCommon,slot_txP)) {
|
if (is_nr_DL_slot(cc->ServingCellConfigCommon,slot_txP)) {
|
||||||
|
|
||||||
memset(RC.nrmac[module_idP]->cce_list[1][0],0,MAX_NUM_CCE*sizeof(int));
|
memset(RC.nrmac[module_idP]->cce_list[1][0],0,MAX_NUM_CCE*sizeof(int));
|
||||||
for (CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++) {
|
for (CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++) {
|
||||||
//mbsfn_status[CC_id] = 0;
|
//mbsfn_status[CC_id] = 0;
|
||||||
|
|
||||||
// clear vrb_maps
|
// clear vrb_maps
|
||||||
memset(cc[CC_id].vrb_map, 0, 100);
|
memset(cc[CC_id].vrb_map, 0, 100);
|
||||||
memset(cc[CC_id].vrb_map_UL, 0, 100);
|
memset(cc[CC_id].vrb_map_UL, 0, 100);
|
||||||
|
|
||||||
clear_nr_nfapi_information(RC.nrmac[module_idP], CC_id, frame_txP, slot_txP);
|
clear_nr_nfapi_information(RC.nrmac[module_idP], CC_id, frame_txP, slot_txP);
|
||||||
}
|
}
|
||||||
|
|
||||||
// refresh UE list based on UEs dropped by PHY in previous subframe
|
// refresh UE list based on UEs dropped by PHY in previous subframe
|
||||||
/*
|
/*
|
||||||
for (i = 0; i < MAX_MOBILES_PER_GNB; i++) {
|
for (i = 0; i < MAX_MOBILES_PER_GNB; i++) {
|
||||||
if (UE_list->active[i]) {
|
if (UE_list->active[i]) {
|
||||||
|
|
||||||
nfapi_nr_config_request_t *cfg = &RC.nrmac[module_idP]->config[CC_id];
|
nfapi_nr_config_request_t *cfg = &RC.nrmac[module_idP]->config[CC_id];
|
||||||
|
|
||||||
|
rnti = 0;//UE_RNTI(module_idP, i);
|
||||||
|
CC_id = 0;//UE_PCCID(module_idP, i);
|
||||||
|
|
||||||
rnti = 0;//UE_RNTI(module_idP, i);
|
} //END if (UE_list->active[i])
|
||||||
CC_id = 0;//UE_PCCID(module_idP, i);
|
} //END for (i = 0; i < MAX_MOBILES_PER_GNB; i++)
|
||||||
|
*/
|
||||||
|
PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, module_idP, ENB_FLAG_YES,NOT_A_RNTI, frame_txP, slot_txP,module_idP);
|
||||||
|
|
||||||
} //END if (UE_list->active[i])
|
// This schedules MIB
|
||||||
} //END for (i = 0; i < MAX_MOBILES_PER_GNB; i++)
|
if((slot_txP == 0) && (frame_txP & 7) == 0){
|
||||||
*/
|
schedule_nr_mib(module_idP, frame_txP, slot_txP);
|
||||||
PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, module_idP, ENB_FLAG_YES,NOT_A_RNTI, frame_txP, slot_txP,module_idP);
|
}
|
||||||
|
|
||||||
// This schedules MIB
|
// TbD once RACH is available, start ta_timer when UE is connected
|
||||||
if((slot_txP == 0) && (frame_txP & 7) == 0){
|
if (ue_sched_ctl->ta_timer) ue_sched_ctl->ta_timer--;
|
||||||
schedule_nr_mib(module_idP, frame_txP, slot_txP);
|
|
||||||
}
|
|
||||||
|
|
||||||
// TbD once RACH is available, start ta_timer when UE is connected
|
if (ue_sched_ctl->ta_timer == 0) {
|
||||||
if (ue_sched_ctl->ta_timer) ue_sched_ctl->ta_timer--;
|
gNB->ta_command = ue_sched_ctl->ta_update;
|
||||||
|
/* if time is up, then set the timer to not send it for 5 frames
|
||||||
|
// regardless of the TA value */
|
||||||
|
ue_sched_ctl->ta_timer = 100;
|
||||||
|
/* reset ta_update */
|
||||||
|
ue_sched_ctl->ta_update = 31;
|
||||||
|
/* MAC CE flag indicating TA length */
|
||||||
|
gNB->ta_len = 2;
|
||||||
|
}
|
||||||
|
|
||||||
if (ue_sched_ctl->ta_timer == 0) {
|
|
||||||
gNB->ta_command = ue_sched_ctl->ta_update;
|
|
||||||
/* if time is up, then set the timer to not send it for 5 frames
|
|
||||||
// regardless of the TA value */
|
|
||||||
ue_sched_ctl->ta_timer = 100;
|
|
||||||
/* reset ta_update */
|
|
||||||
ue_sched_ctl->ta_update = 31;
|
|
||||||
/* MAC CE flag indicating TA length */
|
|
||||||
gNB->ta_len = 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (is_nr_DL_slot(cc->ServingCellConfigCommon,slot_rxP))
|
|
||||||
nr_schedule_RA(module_idP, frame_txP, slot_txP);
|
nr_schedule_RA(module_idP, frame_txP, slot_txP);
|
||||||
|
|
||||||
// Phytest scheduling
|
// Phytest scheduling
|
||||||
if (phy_test && slot_txP==1){
|
if (phy_test && slot_txP==1){
|
||||||
//nr_schedule_uss_dlsch_phytest(module_idP, frame_txP, slot_txP,NULL);
|
//nr_schedule_uss_dlsch_phytest(module_idP, frame_txP, slot_txP,NULL);
|
||||||
// resetting ta flag
|
// resetting ta flag
|
||||||
gNB->ta_len = 0;
|
gNB->ta_len = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
// Allocate CCEs for good after scheduling is done
|
// Allocate CCEs for good after scheduling is done
|
||||||
for (CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++)
|
for (CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++)
|
||||||
allocate_CCEs(module_idP, CC_id, subframeP, 0);
|
allocate_CCEs(module_idP, CC_id, subframeP, 0);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
} //is_nr_DL_slot
|
} //is_nr_DL_slot
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user