X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrsch%2Fsch_common.c;h=c1dee263a6740ac2936b932e248c364111b8c876;hb=a0b19d81aa8c12107f409b1d06a5e900614697c2;hp=d7b4016a7d9d42c9ae89df3a54ca741981e6f285;hpb=f73456bd55152c329601f8286ae67fe9875025bc;p=o-du%2Fl2.git diff --git a/src/5gnrsch/sch_common.c b/src/5gnrsch/sch_common.c index d7b4016a7..c1dee263a 100644 --- a/src/5gnrsch/sch_common.c +++ b/src/5gnrsch/sch_common.c @@ -485,6 +485,9 @@ uint8_t schUlResAlloc(SchCellCb *cell, Inst schInst) UlSchedInfo ulSchedInfo; SchUlSlotInfo *schUlSlotInfo = NULLP; SlotTimingInfo ulTimingInfo; + CmLList *node = NULLP; + TotalPrbUsage *ulTotalPrbUsage = NULLP; + memset(&ulSchedInfo, 0, sizeof(UlSchedInfo)); /* add PHY delta */ @@ -543,11 +546,14 @@ uint8_t schUlResAlloc(SchCellCb *cell, Inst schInst) DU_LOG("\nERROR --> SCH : Sending UL Sch info from SCH to MAC failed"); } - /* Update UL statistics */ - if(schCb[schInst].statistics.ulTotalPrbUsage) + /* Update DL PRB Usage for all stats group which requested for DL Total PRB Usage */ + node = cmLListFirst(&schCb[schInst].statistics.activeKpiList.ulTotPrbUseList); + while(node) { - schCb[schInst].statistics.ulTotalPrbUsage->numPrbUsedForTx += schUlSlotInfo->prbAlloc.numPrbAlloc; - schCb[schInst].statistics.ulTotalPrbUsage->totalPrbAvailForTx += MAX_NUM_RB; + ulTotalPrbUsage = (TotalPrbUsage *)node->node; + ulTotalPrbUsage->numPrbUsedForTx += schUlSlotInfo->prbAlloc.numPrbAlloc; + ulTotalPrbUsage->totalPrbAvailForTx += MAX_NUM_RB; + node = node->next; } /* Re-initialize UL Slot */