Merge remote-tracking branch 'origin/NR_RRC_MAC_CellGroup' into integration_2022_wk24
This commit is contained in:
@@ -588,10 +588,6 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
|
||||
|
||||
if (CellGroup) {
|
||||
|
||||
const NR_ServingCellConfig_t *servingCellConfig = NULL;
|
||||
if(CellGroup->spCellConfig && CellGroup->spCellConfig->spCellConfigDedicated)
|
||||
servingCellConfig = CellGroup->spCellConfig->spCellConfigDedicated;
|
||||
|
||||
if (add_ue == 1 && get_softmodem_params()->phy_test) {
|
||||
NR_UE_info_t* UE = add_new_nr_ue(RC.nrmac[Mod_idP], rnti, CellGroup);
|
||||
if (UE) {
|
||||
@@ -646,31 +642,30 @@ 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_UE_info_t * UE = find_nr_UE(&RC.nrmac[Mod_idP]->UE_info,rnti);
|
||||
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;
|
||||
}
|
||||
|
||||
UE->CellGroup = CellGroup;
|
||||
LOG_I(NR_MAC,"Modified rnti %04x with CellGroup\n",rnti);
|
||||
/* copy CellGroup by calling asn1c encode
|
||||
this is a temporary hack to avoid the gNB having
|
||||
a pointer to RRC CellGroup structure
|
||||
(otherwise it would be applied to early)
|
||||
TODO remove once we have a proper implementation */
|
||||
UE->enc_rval = uper_encode_to_buffer(&asn_DEF_NR_CellGroupConfig,
|
||||
NULL,
|
||||
(void *) CellGroup,
|
||||
UE->cg_buf,
|
||||
32768);
|
||||
|
||||
if (UE->enc_rval.encoded == -1) {
|
||||
LOG_E(NR_MAC, "ASN1 message CellGroupConfig encoding failed (%s, %lu)!\n",
|
||||
UE->enc_rval.failed_type->name, UE->enc_rval.encoded);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
process_CellGroup(CellGroup,&UE->UE_sched_ctrl);
|
||||
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
|
||||
|
||||
const NR_PDSCH_ServingCellConfig_t *pdsch = servingCellConfig ? servingCellConfig->pdsch_ServingCellConfig->choice.setup : NULL;
|
||||
if (get_softmodem_params()->sa) {
|
||||
// add all available DL HARQ processes for this UE in SA
|
||||
create_dl_harq_list(sched_ctrl, pdsch);
|
||||
}
|
||||
|
||||
sched_ctrl->maxL = 2;
|
||||
|
||||
if (CellGroup->spCellConfig &&
|
||||
CellGroup->spCellConfig->spCellConfigDedicated &&
|
||||
CellGroup->spCellConfig->spCellConfigDedicated->csi_MeasConfig &&
|
||||
CellGroup->spCellConfig->spCellConfigDedicated->csi_MeasConfig->choice.setup) {
|
||||
compute_csi_bitlen(CellGroup->spCellConfig->spCellConfigDedicated->csi_MeasConfig->choice.setup, UE);
|
||||
}
|
||||
}
|
||||
}
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RRC_MAC_CONFIG, VCD_FUNCTION_OUT);
|
||||
|
||||
@@ -1952,6 +1952,7 @@ void nr_generate_Msg4(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
|
||||
// If the UE used MSG3 to transfer a DCCH or DTCH message, then contention resolution is successful upon transmission of PDCCH
|
||||
LOG_A(NR_MAC, "(ue rnti 0x%04x) CBRA procedure succeeded!\n", ra->rnti);
|
||||
nr_clear_ra_proc(module_idP, CC_id, frameP, ra);
|
||||
UE->Msg3_dcch_dtch = true;
|
||||
UE->Msg4_ACKed = true;
|
||||
|
||||
remove_front_nr_list(&sched_ctrl->feedback_dl_harq);
|
||||
@@ -1960,6 +1961,24 @@ void nr_generate_Msg4(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
|
||||
add_tail_nr_list(&sched_ctrl->available_dl_harq, current_harq_pid);
|
||||
harq->round = 0;
|
||||
harq->ndi ^= 1;
|
||||
|
||||
// Pause scheduling according to:
|
||||
// 3GPP TS 38.331 Section 12 Table 12.1-1: UE performance requirements for RRC procedures for UEs
|
||||
const NR_COMMON_channels_t *common_channels = &RC.nrmac[module_idP]->common_channels[0];
|
||||
const NR_SIB1_t *sib1 = common_channels->sib1 ? common_channels->sib1->message.choice.c1->choice.systemInformationBlockType1 : NULL;
|
||||
const NR_ServingCellConfig_t *servingCellConfig = UE->CellGroup ? UE->CellGroup->spCellConfig->spCellConfigDedicated : NULL;
|
||||
NR_BWP_t *genericParameters = get_dl_bwp_genericParameters(sched_ctrl->active_bwp,
|
||||
common_channels->ServingCellConfigCommon,
|
||||
sib1);
|
||||
uint32_t delay_ms = servingCellConfig && servingCellConfig->downlinkBWP_ToAddModList ?
|
||||
NR_RRC_SETUP_DELAY_MS + NR_RRC_BWP_SWITCHING_DELAY_MS : NR_RRC_SETUP_DELAY_MS;
|
||||
|
||||
sched_ctrl->rrc_processing_timer = (delay_ms << genericParameters->subcarrierSpacing);
|
||||
LOG_I(NR_MAC, "(%d.%d) Activating RRC processing timer for UE %04x with %d ms\n", frameP, slotP, UE->rnti, delay_ms);
|
||||
|
||||
// Reset uplink failure flags/counters/timers at MAC so gNB will resume again scheduling resources for this UE
|
||||
UE->UE_sched_ctrl.pusch_consecutive_dtx_cnt = 0;
|
||||
UE->UE_sched_ctrl.ul_failure = 0;
|
||||
} else {
|
||||
ra->state = WAIT_Msg4_ACK;
|
||||
LOG_D(NR_MAC,"[gNB %d][RAPROC] Frame %d, Subframe %d: RA state %d\n", module_idP, frameP, slotP, ra->state);
|
||||
|
||||
@@ -576,26 +576,6 @@ void nr_set_pdsch_semi_static(const NR_SIB1_t *sib1,
|
||||
bwpd = (NR_BWP_DownlinkDedicated_t*)bwpd0;
|
||||
}
|
||||
|
||||
// Prevent gNB to enable 256QAM table while the RRCProcessing timer is running.
|
||||
// For example, after the RRC created RRC Reconfiguration message we need to prevent gNB to apply another MCS table
|
||||
// before the RRC Reconfiguration being received by the UE, otherwise UE will not be able to decode PDSCH
|
||||
// and the connection will drop.
|
||||
if (sched_ctrl->rrc_processing_timer == 0) {
|
||||
if (bwpd &&
|
||||
bwpd->pdsch_Config &&
|
||||
bwpd->pdsch_Config->choice.setup &&
|
||||
bwpd->pdsch_Config->choice.setup->mcs_Table) {
|
||||
if (*bwpd->pdsch_Config->choice.setup->mcs_Table == 0) {
|
||||
ps->mcsTableIdx = 1;
|
||||
} else {
|
||||
ps->mcsTableIdx = 2;
|
||||
}
|
||||
} else {
|
||||
ps->mcsTableIdx = 0;
|
||||
}
|
||||
}
|
||||
LOG_D(NR_MAC,"MCS Table Index: %d\n",ps->mcsTableIdx);
|
||||
|
||||
NR_PDSCH_Config_t *pdsch_Config = NULL;
|
||||
if (bwpd && bwpd->pdsch_Config) pdsch_Config = bwpd->pdsch_Config->choice.setup;
|
||||
LOG_D(NR_MAC,"tda %d, ps->time_domain_allocation %d,layers %d, ps->nrOfLayers %d, pdsch_config %p\n",tda,ps->time_domain_allocation,layers,ps->nrOfLayers,pdsch_Config);
|
||||
@@ -2512,6 +2492,44 @@ void create_dl_harq_list(NR_UE_sched_ctrl_t *sched_ctrl,
|
||||
}
|
||||
}
|
||||
|
||||
void reset_dl_harq_list(NR_UE_sched_ctrl_t *sched_ctrl) {
|
||||
int harq;
|
||||
while ((harq = sched_ctrl->feedback_dl_harq.head) >= 0) {
|
||||
remove_front_nr_list(&sched_ctrl->feedback_dl_harq);
|
||||
add_tail_nr_list(&sched_ctrl->available_dl_harq, harq);
|
||||
}
|
||||
|
||||
while ((harq = sched_ctrl->retrans_dl_harq.head) >= 0) {
|
||||
remove_front_nr_list(&sched_ctrl->retrans_dl_harq);
|
||||
add_tail_nr_list(&sched_ctrl->available_dl_harq, harq);
|
||||
}
|
||||
|
||||
for (int i = 0; i < NR_MAX_NB_HARQ_PROCESSES; i++) {
|
||||
sched_ctrl->harq_processes[i].feedback_slot = -1;
|
||||
sched_ctrl->harq_processes[i].round = 0;
|
||||
sched_ctrl->harq_processes[i].is_waiting = false;
|
||||
}
|
||||
}
|
||||
|
||||
void reset_ul_harq_list(NR_UE_sched_ctrl_t *sched_ctrl) {
|
||||
int harq;
|
||||
while ((harq = sched_ctrl->feedback_ul_harq.head) >= 0) {
|
||||
remove_front_nr_list(&sched_ctrl->feedback_ul_harq);
|
||||
add_tail_nr_list(&sched_ctrl->available_ul_harq, harq);
|
||||
}
|
||||
|
||||
while ((harq = sched_ctrl->retrans_ul_harq.head) >= 0) {
|
||||
remove_front_nr_list(&sched_ctrl->retrans_ul_harq);
|
||||
add_tail_nr_list(&sched_ctrl->available_ul_harq, harq);
|
||||
}
|
||||
|
||||
for (int i = 0; i < NR_MAX_NB_HARQ_PROCESSES; i++) {
|
||||
sched_ctrl->ul_harq_processes[i].feedback_slot = -1;
|
||||
sched_ctrl->ul_harq_processes[i].round = 0;
|
||||
sched_ctrl->ul_harq_processes[i].is_waiting = false;
|
||||
}
|
||||
}
|
||||
|
||||
void mac_remove_nr_ue(gNB_MAC_INST *nr_mac, rnti_t rnti)
|
||||
{
|
||||
NR_UEs_t *UE_info = &nr_mac->UE_info;
|
||||
@@ -2877,62 +2895,116 @@ void nr_mac_update_timers(module_id_t module_id,
|
||||
LOG_I(NR_MAC, "(%d.%d) De-activating RRC processing timer for UE %04x\n", frame, slot, UE->rnti);
|
||||
|
||||
const NR_SIB1_t *sib1 = RC.nrmac[module_id]->common_channels[0].sib1 ? RC.nrmac[module_id]->common_channels[0].sib1->message.choice.c1->choice.systemInformationBlockType1 : NULL;
|
||||
NR_CellGroupConfig_t *cg = UE->CellGroup;
|
||||
|
||||
NR_CellGroupConfig_t *cg = NULL;
|
||||
uper_decode(NULL,
|
||||
&asn_DEF_NR_CellGroupConfig, //might be added prefix later
|
||||
(void **)&cg,
|
||||
(uint8_t *)UE->cg_buf,
|
||||
(UE->enc_rval.encoded+7)/8, 0, 0);
|
||||
UE->CellGroup = cg;
|
||||
|
||||
if (LOG_DEBUGFLAG(DEBUG_ASN1)) {
|
||||
xer_fprint(stdout, &asn_DEF_NR_CellGroupConfig, (const void *) UE->CellGroup);
|
||||
}
|
||||
|
||||
NR_ServingCellConfigCommon_t *scc = RC.nrmac[module_id]->common_channels[0].ServingCellConfigCommon;
|
||||
const NR_ServingCellConfig_t *spCellConfigDedicated = cg && cg->spCellConfig ? cg->spCellConfig->spCellConfigDedicated : NULL;
|
||||
|
||||
LOG_I(NR_MAC,"Modified rnti %04x with CellGroup\n", UE->rnti);
|
||||
process_CellGroup(cg,&UE->UE_sched_ctrl);
|
||||
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
|
||||
|
||||
const NR_PDSCH_ServingCellConfig_t *pdsch = spCellConfigDedicated ? spCellConfigDedicated->pdsch_ServingCellConfig->choice.setup : NULL;
|
||||
if (get_softmodem_params()->sa) {
|
||||
// add all available DL HARQ processes for this UE in SA
|
||||
create_dl_harq_list(sched_ctrl, pdsch);
|
||||
}
|
||||
|
||||
// If needed, update the Dedicated BWP
|
||||
const int current_bwp_id = sched_ctrl->active_bwp ? sched_ctrl->active_bwp->bwp_Id : 0;
|
||||
const int current_ubwp_id = sched_ctrl->active_ubwp ? sched_ctrl->active_ubwp->bwp_Id : 0;
|
||||
if (spCellConfigDedicated &&
|
||||
spCellConfigDedicated->downlinkBWP_ToAddModList &&
|
||||
spCellConfigDedicated->uplinkConfig &&
|
||||
spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList) {
|
||||
if (UE->Msg3_dcch_dtch) {
|
||||
// 3GPP TS 38.321 Section 5.15 Bandwidth Part (BWP) operation
|
||||
// Currently there are no PRACH occasions configured for any Dedicated BWP, so UE will switch to the initialDownlinkBWP
|
||||
sched_ctrl->active_bwp = NULL;
|
||||
if (current_bwp_id != 0) {
|
||||
LOG_I(NR_MAC, "(%d.%d) Switching to initialDownlinkBWP\n", frame, slot);
|
||||
}
|
||||
// 3GPP TS 38.321 Section 5.15 Bandwidth Part (BWP) operation
|
||||
// Currently there are no PRACH occasions configured for any Dedicated BWP, so UE will switch to the initialUplinkBWP
|
||||
sched_ctrl->active_ubwp = NULL;
|
||||
if (current_ubwp_id != 0) {
|
||||
LOG_I(NR_MAC, "(%d.%d) Switching to initialUplinkBWP\n", frame, slot);
|
||||
}
|
||||
UE->Msg3_dcch_dtch = false;
|
||||
} else if (spCellConfigDedicated &&
|
||||
spCellConfigDedicated->downlinkBWP_ToAddModList &&
|
||||
spCellConfigDedicated->uplinkConfig &&
|
||||
spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList) {
|
||||
sched_ctrl->active_bwp = spCellConfigDedicated->downlinkBWP_ToAddModList->list.array[*spCellConfigDedicated->firstActiveDownlinkBWP_Id - 1];
|
||||
if (*spCellConfigDedicated->firstActiveDownlinkBWP_Id != current_bwp_id) {
|
||||
sched_ctrl->active_bwp = spCellConfigDedicated->downlinkBWP_ToAddModList->list.array[*spCellConfigDedicated->firstActiveDownlinkBWP_Id - 1];
|
||||
LOG_I(NR_MAC, "Changing to DL-BWP %li\n", sched_ctrl->active_bwp->bwp_Id);
|
||||
LOG_I(NR_MAC, "(%d.%d) Switching to DL-BWP %li\n", frame, slot, sched_ctrl->active_bwp->bwp_Id);
|
||||
}
|
||||
sched_ctrl->active_ubwp = spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList->list.array[*spCellConfigDedicated->uplinkConfig->firstActiveUplinkBWP_Id - 1];
|
||||
if (*spCellConfigDedicated->uplinkConfig->firstActiveUplinkBWP_Id != current_ubwp_id) {
|
||||
sched_ctrl->active_ubwp = spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList->list.array[*spCellConfigDedicated->uplinkConfig->firstActiveUplinkBWP_Id - 1];
|
||||
LOG_I(NR_MAC, "Changing to UL-BWP %li\n", sched_ctrl->active_ubwp->bwp_Id);
|
||||
LOG_I(NR_MAC, "(%d.%d) Switching to UL-BWP %li\n", frame, slot, sched_ctrl->active_ubwp->bwp_Id);
|
||||
}
|
||||
}
|
||||
|
||||
// Update coreset/searchspace
|
||||
NR_BWP_Downlink_t *bwp = sched_ctrl->active_bwp;
|
||||
NR_BWP_DownlinkDedicated_t *bwpd = cg &&
|
||||
cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated ?
|
||||
cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP : NULL;
|
||||
|
||||
// update coreset/searchspace
|
||||
int target_ss = NR_SearchSpace__searchSpaceType_PR_common;
|
||||
NR_BWP_DownlinkDedicated_t *bwpd = NULL;
|
||||
NR_BWP_t *genericParameters = NULL;
|
||||
if (sched_ctrl->active_bwp) {
|
||||
int target_ss = NR_SearchSpace__searchSpaceType_PR_common;
|
||||
if (bwp) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
bwpd = (void*)sched_ctrl->active_bwp->bwp_Dedicated;
|
||||
bwpd = 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)) {
|
||||
} else if (cg &&
|
||||
cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated &&
|
||||
(cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP)) {
|
||||
target_ss = NR_SearchSpace__searchSpaceType_PR_ue_Specific;
|
||||
bwpd = cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP;
|
||||
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->search_space = get_searchspace(sib1, scc, (void*)bwpd, target_ss);
|
||||
sched_ctrl->coreset = get_coreset(RC.nrmac[module_id], scc, (void*)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);
|
||||
sched_ctrl->maxL = 2;
|
||||
if (cg &&
|
||||
cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated &&
|
||||
cg->spCellConfig->spCellConfigDedicated->csi_MeasConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated->csi_MeasConfig->choice.setup) {
|
||||
compute_csi_bitlen (cg->spCellConfig->spCellConfigDedicated->csi_MeasConfig->choice.setup, UE);
|
||||
}
|
||||
|
||||
NR_pdsch_semi_static_t *ps = &sched_ctrl->pdsch_semi_static;
|
||||
|
||||
const uint8_t layers = set_dl_nrOfLayers(sched_ctrl);
|
||||
const int tda = get_dl_tda(RC.nrmac[module_id], scc, slot);
|
||||
|
||||
// Update downlink MCS table
|
||||
if (bwpd &&
|
||||
bwpd->pdsch_Config &&
|
||||
bwpd->pdsch_Config->choice.setup &&
|
||||
bwpd->pdsch_Config->choice.setup->mcs_Table) {
|
||||
if (*bwpd->pdsch_Config->choice.setup->mcs_Table == 0) {
|
||||
ps->mcsTableIdx = 1;
|
||||
} else {
|
||||
ps->mcsTableIdx = 2;
|
||||
}
|
||||
} else {
|
||||
ps->mcsTableIdx = 0;
|
||||
}
|
||||
LOG_D(NR_MAC,"MCS Table Index: %d\n",ps->mcsTableIdx);
|
||||
|
||||
nr_set_pdsch_semi_static(sib1,
|
||||
scc,
|
||||
cg,
|
||||
@@ -2944,14 +3016,17 @@ void nr_mac_update_timers(module_id_t module_id,
|
||||
ps);
|
||||
|
||||
NR_BWP_Uplink_t *ubwp = sched_ctrl->active_ubwp;
|
||||
NR_BWP_UplinkDedicated_t *ubwpd = cg &&
|
||||
cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated &&
|
||||
cg->spCellConfig->spCellConfigDedicated->uplinkConfig ?
|
||||
cg->spCellConfig->spCellConfigDedicated->uplinkConfig->initialUplinkBWP : NULL;
|
||||
NR_BWP_UplinkDedicated_t *ubwpd = NULL;
|
||||
if (ubwp) {
|
||||
ubwpd = sched_ctrl->active_ubwp->bwp_Dedicated;
|
||||
} else if (cg &&
|
||||
cg->spCellConfig &&
|
||||
cg->spCellConfig->spCellConfigDedicated &&
|
||||
(cg->spCellConfig->spCellConfigDedicated->initialDownlinkBWP)) {
|
||||
ubwpd = cg->spCellConfig->spCellConfigDedicated->uplinkConfig->initialUplinkBWP;
|
||||
}
|
||||
|
||||
NR_pusch_semi_static_t *ups = &sched_ctrl->pusch_semi_static;
|
||||
|
||||
int dci_format = get_dci_format(sched_ctrl);
|
||||
const uint8_t num_dmrs_cdm_grps_no_data = (ubwp || ubwpd) ? 1 : 2;
|
||||
const uint8_t nrOfLayers = 1;
|
||||
|
||||
@@ -710,10 +710,12 @@ void nr_rx_sdu(const module_id_t gnb_mod_idP,
|
||||
return;
|
||||
} else {
|
||||
// The UE identified by C-RNTI still exists at the gNB
|
||||
// Reset uplink failure flags/counters/timers at MAC and at RRC so gNB will resume again scheduling resources for this UE
|
||||
UE_C->UE_sched_ctrl.pusch_consecutive_dtx_cnt = 0;
|
||||
UE_C->UE_sched_ctrl.ul_failure = 0;
|
||||
// Reset uplink failure flags/counters/timers at RRC
|
||||
nr_mac_gNB_rrc_ul_failure_reset(gnb_mod_idP, frameP, slotP, ra->crnti);
|
||||
|
||||
// Reset HARQ processes
|
||||
reset_dl_harq_list(&UE_C->UE_sched_ctrl);
|
||||
reset_ul_harq_list(&UE_C->UE_sched_ctrl);
|
||||
}
|
||||
}
|
||||
LOG_I(NR_MAC, "Scheduling RA-Msg4 for TC_RNTI 0x%04x (state %d, frame %d, slot %d)\n",
|
||||
|
||||
@@ -472,6 +472,10 @@ void nr_rx_sdu(const module_id_t gnb_mod_idP,
|
||||
void create_dl_harq_list(NR_UE_sched_ctrl_t *sched_ctrl,
|
||||
const NR_PDSCH_ServingCellConfig_t *pdsch);
|
||||
|
||||
void reset_dl_harq_list(NR_UE_sched_ctrl_t *sched_ctrl);
|
||||
|
||||
void reset_ul_harq_list(NR_UE_sched_ctrl_t *sched_ctrl);
|
||||
|
||||
void handle_nr_ul_harq(const int CC_idP,
|
||||
module_id_t mod_id,
|
||||
frame_t frame,
|
||||
|
||||
@@ -710,10 +710,13 @@ typedef struct {
|
||||
NR_UE_sched_ctrl_t UE_sched_ctrl;
|
||||
NR_mac_stats_t mac_stats;
|
||||
NR_CellGroupConfig_t *CellGroup;
|
||||
char cg_buf[32768]; /* arbitrary size */
|
||||
asn_enc_rval_t enc_rval;
|
||||
/// CCE indexing
|
||||
int m;
|
||||
// UE selected beam index
|
||||
uint8_t UE_beam_index;
|
||||
bool Msg3_dcch_dtch;
|
||||
bool Msg4_ACKed;
|
||||
/// Sched CSI-RS: scheduling decisions
|
||||
NR_gNB_UCI_STATS_t uci_statS;
|
||||
|
||||
+40
-12
@@ -808,6 +808,19 @@ rrc_gNB_generate_defaultRRCReconfiguration(
|
||||
}
|
||||
|
||||
if (NODE_IS_DU(rrc->node_type) || NODE_IS_MONOLITHIC(rrc->node_type)) {
|
||||
rrc_mac_config_req_gNB(rrc->module_id,
|
||||
rrc->configuration.ssb_SubcarrierOffset,
|
||||
rrc->configuration.pdsch_AntennaPorts,
|
||||
rrc->configuration.pusch_AntennaPorts,
|
||||
rrc->configuration.sib1_tda,
|
||||
rrc->configuration.minRXTXTIME,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
ue_p->rnti,
|
||||
ue_p->masterCellGroup);
|
||||
|
||||
uint32_t delay_ms = ue_context_pP->ue_context.masterCellGroup &&
|
||||
ue_context_pP->ue_context.masterCellGroup->spCellConfig &&
|
||||
ue_context_pP->ue_context.masterCellGroup->spCellConfig->spCellConfigDedicated &&
|
||||
@@ -1061,6 +1074,19 @@ rrc_gNB_generate_dedicatedRRCReconfiguration(
|
||||
#endif
|
||||
|
||||
if (NODE_IS_DU(rrc->node_type) || NODE_IS_MONOLITHIC(rrc->node_type)) {
|
||||
rrc_mac_config_req_gNB(rrc->module_id,
|
||||
rrc->configuration.ssb_SubcarrierOffset,
|
||||
rrc->configuration.pdsch_AntennaPorts,
|
||||
rrc->configuration.pusch_AntennaPorts,
|
||||
rrc->configuration.sib1_tda,
|
||||
rrc->configuration.minRXTXTIME,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
ue_context_pP->ue_context.rnti,
|
||||
ue_context_pP->ue_context.masterCellGroup);
|
||||
|
||||
uint32_t delay_ms = ue_context_pP->ue_context.masterCellGroup &&
|
||||
ue_context_pP->ue_context.masterCellGroup->spCellConfig &&
|
||||
ue_context_pP->ue_context.masterCellGroup->spCellConfig->spCellConfigDedicated &&
|
||||
@@ -1435,18 +1461,6 @@ rrc_gNB_process_RRCReconfigurationComplete(
|
||||
/* Refresh SRBs/DRBs */
|
||||
|
||||
if (!NODE_IS_CU(RC.nrrrc[ctxt_pP->module_id]->node_type)) {
|
||||
rrc_mac_config_req_gNB(rrc->module_id,
|
||||
rrc->configuration.ssb_SubcarrierOffset,
|
||||
rrc->configuration.pdsch_AntennaPorts,
|
||||
rrc->configuration.pusch_AntennaPorts,
|
||||
rrc->configuration.sib1_tda,
|
||||
rrc->configuration.minRXTXTIME,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
ue_context_pP->ue_context.rnti,
|
||||
ue_context_pP->ue_context.masterCellGroup);
|
||||
LOG_D(NR_RRC,"Configuring RLC DRBs/SRBs for UE %x\n",ue_context_pP->ue_context.rnti);
|
||||
nr_rrc_rlc_config_asn1_req(ctxt_pP,
|
||||
SRB_configList, // NULL,
|
||||
@@ -1980,6 +1994,20 @@ int nr_rrc_reconfiguration_req(rrc_gNB_ue_context_t *const ue_context_pP
|
||||
NULL,
|
||||
masterCellGroup);
|
||||
|
||||
gNB_RrcConfigurationReq *configuration = &RC.nrrrc[ctxt_pP->module_id]->configuration;
|
||||
rrc_mac_config_req_gNB(ctxt_pP->module_id,
|
||||
configuration->ssb_SubcarrierOffset,
|
||||
configuration->pdsch_AntennaPorts,
|
||||
configuration->pusch_AntennaPorts,
|
||||
configuration->sib1_tda,
|
||||
configuration->minRXTXTIME,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
ue_context_pP->ue_context.rnti,
|
||||
masterCellGroup);
|
||||
|
||||
nr_rrc_data_req(ctxt_pP,
|
||||
DCCH,
|
||||
rrc_gNB_mui++,
|
||||
|
||||
Reference in New Issue
Block a user