update ss and coreset after updating bwp
This commit is contained in:
@@ -646,13 +646,11 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
|
||||
ra->msg3_dcch_dtch = false;
|
||||
LOG_I(NR_MAC,"Added new RA process for UE RNTI %04x with initial CellGroup\n", rnti);
|
||||
} else { // CellGroup has been updated
|
||||
NR_ServingCellConfigCommon_t *scc = RC.nrmac[Mod_idP]->common_channels[0].ServingCellConfigCommon;
|
||||
NR_UE_info_t * UE = find_nr_UE(&RC.nrmac[Mod_idP]->UE_info,rnti);
|
||||
if (!UE) {
|
||||
LOG_E(NR_MAC, "Can't find UE %04x\n", rnti);
|
||||
return -1;
|
||||
}
|
||||
int target_ss;
|
||||
|
||||
UE->CellGroup = CellGroup;
|
||||
LOG_I(NR_MAC,"Modified rnti %04x with CellGroup\n",rnti);
|
||||
@@ -664,30 +662,7 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
|
||||
// add all available DL HARQ processes for this UE in SA
|
||||
create_dl_harq_list(sched_ctrl, pdsch);
|
||||
}
|
||||
// update coreset/searchspace
|
||||
void *bwpd = NULL;
|
||||
NR_BWP_t *genericParameters = NULL;
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_common;
|
||||
if ((sched_ctrl->active_bwp)) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
bwpd = (void*)sched_ctrl->active_bwp->bwp_Dedicated;
|
||||
genericParameters = &sched_ctrl->active_bwp->bwp_Common->genericParameters;
|
||||
}
|
||||
else if (CellGroup->spCellConfig &&
|
||||
CellGroup->spCellConfig->spCellConfigDedicated &&
|
||||
(CellGroup->spCellConfig->spCellConfigDedicated->initialDownlinkBWP)) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
bwpd = (void*)CellGroup->spCellConfig->spCellConfigDedicated->initialDownlinkBWP;
|
||||
genericParameters = &scc->downlinkConfigCommon->initialDownlinkBWP->genericParameters;
|
||||
}
|
||||
sched_ctrl->search_space = get_searchspace(sib1 ? sib1->message.choice.c1->choice.systemInformationBlockType1 : NULL, scc, bwpd, target_ss);
|
||||
sched_ctrl->coreset = get_coreset(RC.nrmac[Mod_idP], scc, bwpd, sched_ctrl->search_space, target_ss);
|
||||
sched_ctrl->sched_pdcch = set_pdcch_structure(RC.nrmac[Mod_idP],
|
||||
sched_ctrl->search_space,
|
||||
sched_ctrl->coreset,
|
||||
scc,
|
||||
genericParameters,
|
||||
RC.nrmac[Mod_idP]->type0_PDCCH_CSS_config);
|
||||
|
||||
sched_ctrl->maxL = 2;
|
||||
if (CellGroup->spCellConfig &&
|
||||
CellGroup->spCellConfig->spCellConfigDedicated &&
|
||||
|
||||
@@ -2896,6 +2896,30 @@ void nr_mac_update_timers(module_id_t module_id,
|
||||
cg->spCellConfig->spCellConfigDedicated ?
|
||||
cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP : NULL;
|
||||
|
||||
// update coreset/searchspace
|
||||
int target_ss = NR_SearchSpace__searchSpaceType_PR_common;
|
||||
NR_BWP_t *genericParameters = NULL;
|
||||
if (sched_ctrl->active_bwp) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
bwpd = (void*)sched_ctrl->active_bwp->bwp_Dedicated;
|
||||
genericParameters = &sched_ctrl->active_bwp->bwp_Common->genericParameters;
|
||||
}
|
||||
else if (cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated &&
|
||||
(cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP)) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
genericParameters = &scc->downlinkConfigCommon->initialDownlinkBWP->genericParameters;
|
||||
}
|
||||
NR_BCCH_DL_SCH_Message_t *SIB1 = RC.nrmac[module_id]->common_channels[0].sib1;
|
||||
sched_ctrl->search_space = get_searchspace(SIB1 ? SIB1->message.choice.c1->choice.systemInformationBlockType1 : NULL, scc, bwpd, target_ss);
|
||||
sched_ctrl->coreset = get_coreset(RC.nrmac[module_id], scc, bwpd, sched_ctrl->search_space, target_ss);
|
||||
sched_ctrl->sched_pdcch = set_pdcch_structure(RC.nrmac[module_id],
|
||||
sched_ctrl->search_space,
|
||||
sched_ctrl->coreset,
|
||||
scc,
|
||||
genericParameters,
|
||||
RC.nrmac[module_id]->type0_PDCCH_CSS_config);
|
||||
|
||||
NR_pdsch_semi_static_t *ps = &sched_ctrl->pdsch_semi_static;
|
||||
|
||||
const uint8_t layers = set_dl_nrOfLayers(sched_ctrl);
|
||||
|
||||
@@ -944,7 +944,7 @@ void tci_handling(NR_UE_info_t *UE, frame_t frame, slot_t slot) {
|
||||
uint8_t idx = 0;
|
||||
|
||||
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
|
||||
const int bwp_id = sched_ctrl->active_bwp ? 1 : 0;
|
||||
const int bwp_id = sched_ctrl->active_bwp ? sched_ctrl->active_bwp->bwp_Id : 0;
|
||||
NR_CellGroupConfig_t *CellGroup = UE->CellGroup;
|
||||
|
||||
//bwp indicator
|
||||
|
||||
Reference in New Issue
Block a user