for testing with another machine.
This commit is contained in:
@@ -2423,7 +2423,7 @@ int32_t get_l_prime(uint8_t duration_in_symbols, uint8_t mapping_type, pusch_dmr
|
||||
uint8_t row, colomn;
|
||||
int32_t l_prime;
|
||||
|
||||
LOG_D(MAC, "PUSCH: NrofSymbols:%d, startSymbol:%d, mappingtype:%d, dmrs_TypeA_Position:%d\n", duration_in_symbols, start_symbol, mapping_type, dmrs_typeA_position);
|
||||
LOG_I(MAC, "PUSCH: NrofSymbols:%d, startSymbol:%d, mappingtype:%d, dmrs_TypeA_Position:%d\n", duration_in_symbols, start_symbol, mapping_type, dmrs_typeA_position);
|
||||
|
||||
// Section 6.4.1.1.3 in Spec 38.211
|
||||
// For PDSCH Mapping TypeA, ld is duration between first OFDM of the slot and last OFDM symbol of the scheduled PUSCH resources
|
||||
@@ -2450,11 +2450,11 @@ int32_t get_l_prime(uint8_t duration_in_symbols, uint8_t mapping_type, pusch_dmr
|
||||
l0 = 1<<l0 | 1<<(l0+1);
|
||||
}
|
||||
|
||||
LOG_D(MAC, "PUSCH - l0:%d, ld:%d,row:%d, column:%d, addpos:%d, maxlen:%d\n", l0, ld, row, colomn, additional_pos, pusch_maxLength);
|
||||
LOG_I(MAC, "PUSCH - l0:%d, ld:%d,row:%d, column:%d, addpos:%d, maxlen:%d\n", l0, ld, row, colomn, additional_pos, pusch_maxLength);
|
||||
AssertFatal(l_prime>=0,"invalid l_prime < 0\n");
|
||||
|
||||
l_prime = (mapping_type == typeA) ? (l_prime | l0) : (l_prime << start_symbol);
|
||||
LOG_D(MAC, " PUSCH DMRS MASK in HEX:%x\n", l_prime);
|
||||
LOG_I(MAC, " PUSCH DMRS MASK in HEX:%x\n", l_prime);
|
||||
|
||||
return l_prime;
|
||||
|
||||
|
||||
@@ -1236,6 +1236,7 @@ void nr_generate_Msg4(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
|
||||
const int delta_PRI=0;
|
||||
int r_pucch = ((CCEIndex<<1)/N_cce)+(delta_PRI<<1);
|
||||
|
||||
LOG_I(NR_MAC,"[RAPROC] Msg4 r_pucch %d (CCEIndex %d, N_cce %d, nb_of_candidates %d,delta_PRI %d)\n",r_pucch,CCEIndex,N_cce,nr_of_candidates,delta_PRI);
|
||||
int alloc = nr_acknack_scheduling(module_idP, UE_id, frameP, slotP, r_pucch);
|
||||
AssertFatal(alloc>=0,"Couldn't find a pucch allocation for ack nack (msg4)\n");
|
||||
NR_sched_pucch_t *pucch = &sched_ctrl->sched_pucch[alloc];
|
||||
@@ -1418,7 +1419,7 @@ void nr_generate_Msg4(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
|
||||
dci_pdu_rel15_t dci_payload;
|
||||
dci_payload.frequency_domain_assignment.val = PRBalloc_to_locationandbandwidth0(pdsch_pdu_rel15->rbSize,
|
||||
pdsch_pdu_rel15->rbStart,
|
||||
pdsch_pdu_rel15->BWPSize);
|
||||
BWPSize);
|
||||
|
||||
dci_payload.format_indicator = 1;
|
||||
dci_payload.time_domain_assignment.val = time_domain_assignment;
|
||||
@@ -1433,8 +1434,8 @@ void nr_generate_Msg4(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
|
||||
dci_payload.pucch_resource_indicator = delta_PRI; // This is delta_PRI from 9.2.1 in 38.213
|
||||
dci_payload.pdsch_to_harq_feedback_timing_indicator.val = pucch->timing_indicator;
|
||||
|
||||
LOG_D(NR_MAC,
|
||||
"[RAPROC] DCI type 1 payload: freq_alloc %d (%d,%d,%d), time_alloc %d, vrb to prb %d, mcs %d tb_scaling %d pucchres %d harqtiming %d\n",
|
||||
LOG_I(NR_MAC,
|
||||
"[RAPROC] DCI 1_0 payload: freq_alloc %d (%d,%d,%d), time_alloc %d, vrb to prb %d, mcs %d tb_scaling %d pucchres %d harqtiming %d\n",
|
||||
dci_payload.frequency_domain_assignment.val,
|
||||
pdsch_pdu_rel15->rbStart,
|
||||
pdsch_pdu_rel15->rbSize,
|
||||
|
||||
@@ -1067,7 +1067,6 @@ void fill_dci_pdu_rel15(const NR_ServingCellConfigCommon_t *scc,
|
||||
int dci_size = nr_dci_size(scc->uplinkConfigCommon->initialUplinkBWP, CellGroup, dci_pdu_rel15, dci_format, rnti_type, N_RB, bwp_id);
|
||||
pdcch_dci_pdu->PayloadSizeBits = dci_size;
|
||||
AssertFatal(dci_size <= 64, "DCI sizes above 64 bits not yet supported");
|
||||
|
||||
if (dci_format == NR_DL_DCI_FORMAT_1_1 || dci_format == NR_UL_DCI_FORMAT_0_1)
|
||||
prepare_dci(CellGroup, dci_pdu_rel15, dci_format, bwp_id);
|
||||
|
||||
@@ -1332,6 +1331,7 @@ void fill_dci_pdu_rel15(const NR_ServingCellConfigCommon_t *scc,
|
||||
case NR_UL_DCI_FORMAT_0_0:
|
||||
switch (rnti_type) {
|
||||
case NR_RNTI_C:
|
||||
LOG_I(NR_MAC,"Filling format 0_0 DCI for CRNTI (size %d bits)\n",dci_size);
|
||||
// indicating a UL DCI format 1bit
|
||||
pos=1;
|
||||
*dci_pdu |= ((uint64_t)dci_pdu_rel15->format_indicator & 1) << (dci_size - pos);
|
||||
@@ -2053,6 +2053,7 @@ bool find_free_CCE(module_id_t module_id,
|
||||
const int cid = sched_ctrl->coreset->controlResourceSetId;
|
||||
const uint16_t Y = RC.nrmac[module_id]->UE_info.Y[UE_id][cid][slot];
|
||||
const int m = RC.nrmac[module_id]->UE_info.num_pdcch_cand[UE_id][cid];
|
||||
if (UE_id >= 0) LOG_I(NR_MAC,"calling allocate_nr_CCEs with L %d, nr_of_candidates %d, Y %x\n",sched_ctrl->aggregation_level,nr_of_candidates,Y);
|
||||
sched_ctrl->cce_index = allocate_nr_CCEs(RC.nrmac[module_id],
|
||||
sched_ctrl->active_bwp,
|
||||
sched_ctrl->coreset,
|
||||
|
||||
@@ -1110,6 +1110,7 @@ void pf_ul(module_id_t module_id,
|
||||
LOG_D(NR_MAC, "%4d.%2d no free CCE for UL DCI UE %04x\n", frame, slot, UE_info->rnti[UE_id]);
|
||||
continue;
|
||||
}
|
||||
else LOG_I(NR_MAC, "%4d.%2d free CCE for UL DCI UE %04x\n",frame,slot, UE_info->rnti[UE_id]);
|
||||
|
||||
/* reduce max_num_ue once we are sure UE can be allocated, i.e., has CCE */
|
||||
max_num_ue--;
|
||||
@@ -1134,6 +1135,7 @@ void pf_ul(module_id_t module_id,
|
||||
UE_id, UE_info->rnti[UE_id],rbStart,min_rb,bwpSize);
|
||||
return;
|
||||
}
|
||||
else LOG_I(NR_MAC,"allocating UL data for UE %d/RNTI %04x (rbStsart %d, min_rb %d, bwpSize %d\n",UE_id, UE_info->rnti[UE_id],rbStart,min_rb,bwpSize);
|
||||
|
||||
/* Save PUSCH field */
|
||||
/* we want to avoid a lengthy deduction of DMRS and other parameters in
|
||||
@@ -1163,8 +1165,8 @@ void pf_ul(module_id_t module_id,
|
||||
&rbSize);
|
||||
sched_pusch->rbSize = rbSize;
|
||||
sched_pusch->tb_size = TBS;
|
||||
LOG_D(NR_MAC,"rbSize %d, TBS %d, est buf %d, sched_ul %d, B %d\n",
|
||||
rbSize, sched_pusch->tb_size, sched_ctrl->estimated_ul_buffer, sched_ctrl->sched_ul_bytes, B);
|
||||
LOG_I(NR_MAC,"rbSize %d, TBS %d, est buf %d, sched_ul %d, B %d, CCE %d\n",
|
||||
rbSize, sched_pusch->tb_size, sched_ctrl->estimated_ul_buffer, sched_ctrl->sched_ul_bytes, B,sched_ctrl->cce_index);
|
||||
|
||||
/* Mark the corresponding RBs as used */
|
||||
n_rb_sched -= sched_pusch->rbSize;
|
||||
@@ -1395,8 +1397,8 @@ void nr_schedule_ulsch(module_id_t module_id, frame_t frame, sub_frame_t slot)
|
||||
sched_ctrl->last_ul_frame = sched_pusch->frame;
|
||||
sched_ctrl->last_ul_slot = sched_pusch->slot;
|
||||
|
||||
LOG_D(NR_MAC,
|
||||
"%4d.%2d RNTI %04x UL sched %4d.%2d start %2d RBS %3d startSymbol %2d nb_symbol %2d MCS %2d TBS %4d HARQ PID %2d round %d NDI %d est %6d sched %6d est BSR %6d\n",
|
||||
LOG_I(NR_MAC,
|
||||
"%4d.%2d RNTI %04x UL sched %4d.%2d start %2d RBS %3d startSymbol %2d nb_symbol %2d dmrs_pos %x MCS %2d TBS %4d HARQ PID %2d round %d RV %d NDI %d est %6d sched %6d est BSR %6d\n",
|
||||
frame,
|
||||
slot,
|
||||
rnti,
|
||||
@@ -1406,10 +1408,12 @@ void nr_schedule_ulsch(module_id_t module_id, frame_t frame, sub_frame_t slot)
|
||||
sched_pusch->rbSize,
|
||||
ps->startSymbolIndex,
|
||||
ps->nrOfSymbols,
|
||||
ps->ul_dmrs_symb_pos,
|
||||
sched_pusch->mcs,
|
||||
sched_pusch->tb_size,
|
||||
harq_id,
|
||||
cur_harq->round,
|
||||
nr_rv_round_map[cur_harq->round],
|
||||
cur_harq->ndi,
|
||||
sched_ctrl->estimated_ul_buffer,
|
||||
sched_ctrl->sched_ul_bytes,
|
||||
@@ -1559,7 +1563,7 @@ void nr_schedule_ulsch(module_id_t module_id, frame_t frame, sub_frame_t slot)
|
||||
pdcch_pdu_bwp_coreset[bwpid][coresetid] = pdcch_pdu;
|
||||
}
|
||||
|
||||
LOG_D(NR_MAC,"Configuring ULDCI/PDCCH in %d.%d\n", frame,slot);
|
||||
LOG_I(NR_MAC,"Configuring ULDCI/PDCCH in %d.%d at CCE %d, rnti %x\n", frame,slot,sched_ctrl->cce_index,rnti);
|
||||
|
||||
/* Fill PDCCH DL DCI PDU */
|
||||
nfapi_nr_dl_dci_pdu_t *dci_pdu = &pdcch_pdu->dci_pdu[pdcch_pdu->numDlDci];
|
||||
|
||||
@@ -452,7 +452,7 @@ uint8_t do_SIB1_NR(rrc_gNB_carrier_data_t *carrier,
|
||||
ss1->monitoringSlotPeriodicityAndOffset->present = NR_SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1;
|
||||
ss1->monitoringSymbolsWithinSlot = calloc(1,sizeof(*ss1->monitoringSymbolsWithinSlot));
|
||||
ss1->monitoringSymbolsWithinSlot->buf = calloc(1,2);
|
||||
// should be '1100 0000 0000 00'B (LSB first!), first two symols in slot, adjust if needed
|
||||
// should be '1000 0000 0000 00'B (LSB first!), first symbol in slot, adjust if needed
|
||||
ss1->monitoringSymbolsWithinSlot->buf[1] = 0;
|
||||
ss1->monitoringSymbolsWithinSlot->buf[0] = (1<<7);
|
||||
ss1->monitoringSymbolsWithinSlot->size = 2;
|
||||
@@ -460,7 +460,7 @@ uint8_t do_SIB1_NR(rrc_gNB_carrier_data_t *carrier,
|
||||
ss1->nrofCandidates = calloc(1,sizeof(*ss1->nrofCandidates));
|
||||
ss1->nrofCandidates->aggregationLevel1 = NR_SearchSpace__nrofCandidates__aggregationLevel1_n0;
|
||||
ss1->nrofCandidates->aggregationLevel2 = NR_SearchSpace__nrofCandidates__aggregationLevel2_n0;
|
||||
ss1->nrofCandidates->aggregationLevel4 = NR_SearchSpace__nrofCandidates__aggregationLevel4_n4;
|
||||
ss1->nrofCandidates->aggregationLevel4 = NR_SearchSpace__nrofCandidates__aggregationLevel4_n2;
|
||||
ss1->nrofCandidates->aggregationLevel8 = NR_SearchSpace__nrofCandidates__aggregationLevel8_n0;
|
||||
ss1->nrofCandidates->aggregationLevel16 = NR_SearchSpace__nrofCandidates__aggregationLevel16_n0;
|
||||
ss1->searchSpaceType = calloc(1,sizeof(*ss1->searchSpaceType));
|
||||
@@ -1083,7 +1083,7 @@ void fill_initial_SpCellConfig(rnti_t rnti,
|
||||
ss2->nrofCandidates=calloc(1,sizeof(*ss2->nrofCandidates));
|
||||
ss2->nrofCandidates->aggregationLevel1 = NR_SearchSpace__nrofCandidates__aggregationLevel1_n0;
|
||||
ss2->nrofCandidates->aggregationLevel2 = NR_SearchSpace__nrofCandidates__aggregationLevel2_n0;
|
||||
ss2->nrofCandidates->aggregationLevel4 = NR_SearchSpace__nrofCandidates__aggregationLevel4_n1;
|
||||
ss2->nrofCandidates->aggregationLevel4 = NR_SearchSpace__nrofCandidates__aggregationLevel4_n2;
|
||||
ss2->nrofCandidates->aggregationLevel8 = NR_SearchSpace__nrofCandidates__aggregationLevel8_n0;
|
||||
ss2->nrofCandidates->aggregationLevel16 = NR_SearchSpace__nrofCandidates__aggregationLevel16_n0;
|
||||
ss2->searchSpaceType=calloc(1,sizeof(*ss2->searchSpaceType));
|
||||
|
||||
Reference in New Issue
Block a user