X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrsch%2Fsch_slot_ind.c;h=0efd930a5d404ffe2f514fbc1f555d7a32bda1c4;hb=e96cb439cd4a7a6f55e3fab7caed978e38bd62b4;hp=8b423b27aa622554463157709a15ec7a9fbd7dee;hpb=d18d80cc82c8bae113c62a45b30345bfb4ca570f;p=o-du%2Fl2.git diff --git a/src/5gnrsch/sch_slot_ind.c b/src/5gnrsch/sch_slot_ind.c index 8b423b27a..0efd930a5 100644 --- a/src/5gnrsch/sch_slot_ind.c +++ b/src/5gnrsch/sch_slot_ind.c @@ -242,8 +242,6 @@ bool schFillBoGrantDlSchedInfo(SchCellCb *cell, SlotTimingInfo currTime, uint8_t } } - cell->schUlSlotInfo[pucchTime.slot]->pucchUe = ueId; - /*Re-setting the BO's of all DL LCs in this UE*/ for(lcIdx = 0; lcIdx < MAX_NUM_LC; lcIdx++) { @@ -313,11 +311,11 @@ void schCalcSlotValues(SlotTimingInfo slotInd, SchSlotValue *schSlotValue, uint1 * on PHY_DELTA + SCHED_DELTA + BO_DELTA * ****************************************************************/ - ADD_DELTA_TO_TIME(slotInd, schSlotValue->currentTime, PHY_DELTA_DL, numOfSlots); - ADD_DELTA_TO_TIME(slotInd, schSlotValue->broadcastTime, PHY_DELTA_DL + SCHED_DELTA, numOfSlots); - ADD_DELTA_TO_TIME(slotInd, schSlotValue->rarTime, PHY_DELTA_DL + SCHED_DELTA, numOfSlots); - ADD_DELTA_TO_TIME(slotInd, schSlotValue->dlMsgTime, PHY_DELTA_DL + SCHED_DELTA, numOfSlots); - ADD_DELTA_TO_TIME(slotInd, schSlotValue->ulDciTime, PHY_DELTA_DL + SCHED_DELTA, numOfSlots); + ADD_DELTA_TO_TIME(slotInd, schSlotValue->currentTime, gConfigInfo.gPhyDeltaDl, numOfSlots); + ADD_DELTA_TO_TIME(slotInd, schSlotValue->broadcastTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, numOfSlots); + ADD_DELTA_TO_TIME(slotInd, schSlotValue->rarTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, numOfSlots); + ADD_DELTA_TO_TIME(slotInd, schSlotValue->dlMsgTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, numOfSlots); + ADD_DELTA_TO_TIME(slotInd, schSlotValue->ulDciTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, numOfSlots); } /******************************************************************* @@ -421,10 +419,11 @@ bool findValidK0K1Value(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId, uint8_t numK0 = 0, k0TblIdx = 0, k0Val = 0, k0Index =0 ; uint8_t k1TblIdx = 0, k1Index = 0, k1Val = 0, numK1 = 0; uint8_t ret = RFAILED; + uint16_t crnti = 0; SchUeCb *ueCb = NULLP; SchK0K1TimingInfoTbl *k0K1InfoTbl; - ADD_DELTA_TO_TIME(currTime, (*pdcchTime), PHY_DELTA_DL + SCHED_DELTA, cell->numSlots); + ADD_DELTA_TO_TIME(currTime, (*pdcchTime), gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots); #ifdef NR_TDD if(schGetSlotSymbFrmt(pdcchTime->slot, cell->slotFrmtBitMap) != DL_SLOT) { @@ -434,6 +433,7 @@ bool findValidK0K1Value(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId, #endif ueCb = &cell->ueCb[ueId-1]; + GET_CRNTI(crnti, ueId); if(dedMsg == true) { k0K1InfoTbl = &ueCb->k0K1InfoTbl; @@ -508,7 +508,7 @@ bool findValidK0K1Value(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId, continue; } #endif - if(cell->schUlSlotInfo[pucchTime->slot]->pucchUe != 0) + if(cell->schUlSlotInfo[pucchTime->slot]->schPucchInfo[ueId - 1].crnti == crnti) { continue; } @@ -518,11 +518,11 @@ bool findValidK0K1Value(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId, } pdcchTime->cellId = cell->cellId; pdschTime->cellId = cell->cellId; - - cell->schUlSlotInfo[pucchTime->slot]->pucchUe = ueId; + + cell->schUlSlotInfo[pucchTime->slot]->schPucchInfo[ueId - 1].crnti = crnti; /*Availability of PUCCH for HARQ resources*/ - ret = schAllocPucchResource(cell, *pucchTime, ueCb, hqP, pdcchAllocInfo); + ret = schAllocPucchResource(cell, ueId, *pucchTime, ueCb, hqP, pdcchAllocInfo); if(ret == RFAILED) { /*DL allocation can't go through as PUCCH is unavailable*/ @@ -577,7 +577,7 @@ uint8_t schProcDlPageAlloc(SchCellCb *cell, SlotTimingInfo currTime, Inst schIns { dlPageAlloc.cellId = currTime.cellId; - ADD_DELTA_TO_TIME(currTime, dlPageAlloc.dlPageTime, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots); + ADD_DELTA_TO_TIME(currTime, dlPageAlloc.dlPageTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots); dlPageAlloc.shortMsgInd = FALSE; pdschTime = dlPageAlloc.dlPageTime;