Merge remote-tracking branch 'origin/nzp_csi_pdsch_ratematching' into integration_2025_w37 (!3514)
NR UE: add support for PDSCH rate matching with NZP CSI-RS Currently only ZP CSI-RS is considered in function configure_ratematching_csi, add support for NZP CSI-RS. Closes #975
This commit is contained in:
@@ -699,7 +699,7 @@ static uint32_t compute_csi_rm_unav_res(fapi_nr_dl_config_dlsch_pdu_rel15_t *dls
|
|||||||
int num_symb = num_l0[csi_pdu->row - 1];
|
int num_symb = num_l0[csi_pdu->row - 1];
|
||||||
for (int s = 0; s < num_symb; s++) {
|
for (int s = 0; s < num_symb; s++) {
|
||||||
int l0_symb = csi_pdu->symb_l0 + s;
|
int l0_symb = csi_pdu->symb_l0 + s;
|
||||||
if (l0_symb >= dlsch_config->start_symbol && l0_symb <= dlsch_config->start_symbol + dlsch_config->number_symbols)
|
if (l0_symb >= dlsch_config->start_symbol && l0_symb < dlsch_config->start_symbol + dlsch_config->number_symbols)
|
||||||
num_overlap_symb++;
|
num_overlap_symb++;
|
||||||
}
|
}
|
||||||
// check also l1 if relevant
|
// check also l1 if relevant
|
||||||
@@ -707,7 +707,7 @@ static uint32_t compute_csi_rm_unav_res(fapi_nr_dl_config_dlsch_pdu_rel15_t *dls
|
|||||||
num_symb += 2;
|
num_symb += 2;
|
||||||
for (int s = 0; s < 2; s++) { // two consecutive symbols including l1
|
for (int s = 0; s < 2; s++) { // two consecutive symbols including l1
|
||||||
int l1_symb = csi_pdu->symb_l1 + s;
|
int l1_symb = csi_pdu->symb_l1 + s;
|
||||||
if (l1_symb >= dlsch_config->start_symbol && l1_symb <= dlsch_config->start_symbol + dlsch_config->number_symbols)
|
if (l1_symb >= dlsch_config->start_symbol && l1_symb < dlsch_config->start_symbol + dlsch_config->number_symbols)
|
||||||
num_overlap_symb++;
|
num_overlap_symb++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -284,7 +284,8 @@ static void configure_ratematching_csi(fapi_nr_dl_config_dlsch_pdu_rel15_t *dlsc
|
|||||||
int slot,
|
int slot,
|
||||||
int mu,
|
int mu,
|
||||||
int slots_per_frame,
|
int slots_per_frame,
|
||||||
const NR_PDSCH_Config_t *pdsch_config)
|
const NR_PDSCH_Config_t *pdsch_config,
|
||||||
|
NR_CSI_MeasConfig_t *csi_MeasConfig)
|
||||||
{
|
{
|
||||||
// only for C-RNTI, MCS-C-RNTI, CS-RNTI (and only C-RNTI is supported for now)
|
// only for C-RNTI, MCS-C-RNTI, CS-RNTI (and only C-RNTI is supported for now)
|
||||||
if (rnti_type != TYPE_C_RNTI_)
|
if (rnti_type != TYPE_C_RNTI_)
|
||||||
@@ -319,6 +320,25 @@ static void configure_ratematching_csi(fapi_nr_dl_config_dlsch_pdu_rel15_t *dlsc
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Handle NZP CSI-RS for rate matching
|
||||||
|
if (csi_MeasConfig && csi_MeasConfig->nzp_CSI_RS_ResourceToAddModList) {
|
||||||
|
for (int i = 0; i < csi_MeasConfig->nzp_CSI_RS_ResourceToAddModList->list.count; i++) {
|
||||||
|
NR_NZP_CSI_RS_Resource_t *nzp_res = csi_MeasConfig->nzp_CSI_RS_ResourceToAddModList->list.array[i];
|
||||||
|
if (nzp_res->periodicityAndOffset) {
|
||||||
|
int period, offset;
|
||||||
|
csi_period_offset(NULL, nzp_res->periodicityAndOffset, &period, &offset);
|
||||||
|
if ((frame * slots_per_frame + slot - offset) % period != 0)
|
||||||
|
continue;
|
||||||
|
AssertFatal(dlsch_pdu->numCsiRsForRateMatching < NFAPI_MAX_NUM_CSI_RATEMATCH, "csiRsForRateMatching out of bounds\n");
|
||||||
|
fapi_nr_dl_config_csirs_pdu_rel15_t *csi_pdu = &dlsch_pdu->csiRsForRateMatching[dlsch_pdu->numCsiRsForRateMatching];
|
||||||
|
csi_pdu->csi_type = 1; // NZP CSI-RS
|
||||||
|
csi_pdu->subcarrier_spacing = mu;
|
||||||
|
configure_csi_resource_mapping(csi_pdu, &nzp_res->resourceMapping, dlsch_pdu->BWPSize, dlsch_pdu->BWPStart);
|
||||||
|
dlsch_pdu->numCsiRsForRateMatching++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
for (int i = 0; i < dl_config->number_pdus; i++) {
|
for (int i = 0; i < dl_config->number_pdus; i++) {
|
||||||
// This assumes that CSI-RS are scheduled before this moment which is true in current implementation
|
// This assumes that CSI-RS are scheduled before this moment which is true in current implementation
|
||||||
const fapi_nr_dl_config_request_pdu_t *csi_req = &dl_config->dl_config_list[i];
|
const fapi_nr_dl_config_request_pdu_t *csi_req = &dl_config->dl_config_list[i];
|
||||||
@@ -769,8 +789,15 @@ static int nr_ue_process_dci_dl_10(NR_UE_MAC_INST_t *mac,
|
|||||||
|
|
||||||
dlsch_pdu->numCsiRsForRateMatching = 0;
|
dlsch_pdu->numCsiRsForRateMatching = 0;
|
||||||
int slots_frame = mac->frame_structure.numb_slots_frame;
|
int slots_frame = mac->frame_structure.numb_slots_frame;
|
||||||
configure_ratematching_csi(dlsch_pdu, dl_config, rnti_type, frame, slot, dlsch_pdu->SubcarrierSpacing, slots_frame, pdsch_config);
|
configure_ratematching_csi(dlsch_pdu,
|
||||||
|
dl_config,
|
||||||
|
rnti_type,
|
||||||
|
frame,
|
||||||
|
slot,
|
||||||
|
dlsch_pdu->SubcarrierSpacing,
|
||||||
|
slots_frame,
|
||||||
|
pdsch_config,
|
||||||
|
mac->sc_info.csi_MeasConfig);
|
||||||
|
|
||||||
/* IDENTIFIER_DCI_FORMATS */
|
/* IDENTIFIER_DCI_FORMATS */
|
||||||
/* FREQ_DOM_RESOURCE_ASSIGNMENT_DL */
|
/* FREQ_DOM_RESOURCE_ASSIGNMENT_DL */
|
||||||
@@ -1105,7 +1132,15 @@ static int nr_ue_process_dci_dl_11(NR_UE_MAC_INST_t *mac,
|
|||||||
nr_rnti_type_t rnti_type = get_rnti_type(mac, dci_ind->rnti);
|
nr_rnti_type_t rnti_type = get_rnti_type(mac, dci_ind->rnti);
|
||||||
dlsch_pdu->numCsiRsForRateMatching = 0;
|
dlsch_pdu->numCsiRsForRateMatching = 0;
|
||||||
int slots_frame = mac->frame_structure.numb_slots_frame;
|
int slots_frame = mac->frame_structure.numb_slots_frame;
|
||||||
configure_ratematching_csi(dlsch_pdu, dl_config, rnti_type, frame, slot, current_DL_BWP->scs, slots_frame, pdsch_Config);
|
configure_ratematching_csi(dlsch_pdu,
|
||||||
|
dl_config,
|
||||||
|
rnti_type,
|
||||||
|
frame,
|
||||||
|
slot,
|
||||||
|
current_DL_BWP->scs,
|
||||||
|
slots_frame,
|
||||||
|
pdsch_Config,
|
||||||
|
mac->sc_info.csi_MeasConfig);
|
||||||
|
|
||||||
/* IDENTIFIER_DCI_FORMATS */
|
/* IDENTIFIER_DCI_FORMATS */
|
||||||
/* CARRIER_IND */
|
/* CARRIER_IND */
|
||||||
|
|||||||
Reference in New Issue
Block a user