X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrsch%2Fsch_common.c;h=7e611455cb12cfb8b34d558c5cc4af51ac0889c2;hb=cfe7ea3ab6cb69d18ed91d79c1bf66b3bc8bdc98;hp=c9bc50fd0a35ff0727e9c04e88b4a01af44f591e;hpb=45d134510deb6902b870b4a0fb574b6075fba601;p=o-du%2Fl2.git diff --git a/src/5gnrsch/sch_common.c b/src/5gnrsch/sch_common.c index c9bc50fd0..7e611455c 100644 --- a/src/5gnrsch/sch_common.c +++ b/src/5gnrsch/sch_common.c @@ -106,10 +106,17 @@ uint8_t schBroadcastAlloc(SchCellCb *cell, DlBrdcstAlloc *dlBrdcstAlloc, /* SIB1 allocation */ if(dlBrdcstAlloc->sib1Trans) { + uint16_t tbSize = 0; + uint8_t numPdschSymbols = 12; /* considering pdsch region from 2 to 13 */ + uint8_t mcs = 4; /* MCS fixed to 4 */ + uint8_t numSib1Prb = 0; schDlSlotInfo->sib1Pres = true; + + tbSize = schCalcTbSize(cell->cellCfg.sib1SchCfg.sib1PduLen); /* send this value to the func in bytes when considering sib1 size */ + numSib1Prb = schCalcNumPrb(tbSize,mcs,numPdschSymbols); for(idx=0; idxassignedPrb[idx] = ssbStartPrb + SCH_SSB_NUM_PRB + 1 + 10; /* 10 PRBs for sib1 */ + schDlSlotInfo->assignedPrb[idx] = ssbStartPrb + SCH_SSB_NUM_PRB + 1 + numSib1Prb; /* 10 PRBs for sib1 */ } memcpy(&dlBrdcstAlloc->sib1Alloc.bwp, &cell->cellCfg.sib1SchCfg.bwp, sizeof(BwpCfg)); memcpy(&dlBrdcstAlloc->sib1Alloc.sib1PdcchCfg, &cell->cellCfg.sib1SchCfg.sib1PdcchCfg, sizeof(PdcchCfg)); @@ -246,8 +253,8 @@ uint16_t fillPucchResourceInfo(SchPucchInfo *schPucchInfo, Inst inst) schPucchInfo->numHarqBits = 1; /* 1 bit for HARQ */ /* set SR and UCI flag to false */ - schPucchInfo->srFlag = false; - schPucchInfo->uciFlag = false; + schPucchInfo->srFlag = true; + schPucchInfo->uciFlag = true; return ROK; } @@ -309,8 +316,8 @@ uint8_t schUlResAlloc(SchCellCb *cell, Inst schInst) { DU_LOG("\nSending UL Sch info from SCH to MAC failed"); } - memset(cell->schUlSlotInfo[ulTimingInfo.slot], 0, sizeof(SchUlSlotInfo)); + schInitUlSlot(schUlSlotInfo); return ret; } @@ -384,7 +391,7 @@ uint8_t schDlRsrcAllocMsg4(Msg4Alloc *msg4Alloc, SchCellCb *cell, uint16_t slot) pdcch->coreset0Cfg.regBundleSize = 6; /* spec-38.211 sec 7.3.2.2 */ pdcch->coreset0Cfg.interleaverSize = 2; /* spec-38.211 sec 7.3.2.2 */ pdcch->coreset0Cfg.coreSetType = 0; - pdcch->coreset0Cfg.coreSet0Size = numRbs; + pdcch->coreset0Cfg.coreSetSize = numRbs; pdcch->coreset0Cfg.shiftIndex = cell->cellCfg.phyCellId; pdcch->coreset0Cfg.precoderGranularity = 0; /* sameAsRegBundle */ pdcch->numDlDci = 1;