From: svaidhya Date: Thu, 14 Dec 2023 08:10:26 +0000 (+0530) Subject: [Epic-ID: ODUHIGH-517][Task-ID: ODUHIGH-540][SubTask-Id: ODUHIGH-549] Multi PDSCH... X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=commitdiff_plain;h=73da3ffdd36c5ade0c1cccbe7d2ad4d457897b2f;p=o-du%2Fl2.git [Epic-ID: ODUHIGH-517][Task-ID: ODUHIGH-540][SubTask-Id: ODUHIGH-549] Multi PDSCH alloc Change-Id: Icd03c9cfbccff11d7d6ed47215539c98783a154e Signed-off-by: svaidhya --- diff --git a/src/5gnrsch/sch.h b/src/5gnrsch/sch.h index 1e3f9c7ce..39aa04249 100644 --- a/src/5gnrsch/sch.h +++ b/src/5gnrsch/sch.h @@ -326,7 +326,6 @@ typedef struct schDlSlotInfo SsbInfo ssbInfo[MAX_SSB_IDX]; /*!< SSB info */ bool sib1Pres; /*!< Flag to determine if SIB1 is present in this slot */ uint8_t pdcchUe; /*!< UE for which PDCCH Common is scheduled in this slot */ - uint8_t pdschUe; /*!< UE for which PDSCH is scheduled in this slot */ RarAlloc *rarAlloc[MAX_NUM_UE]; /*!< RAR allocation per UE*/ DciInfo *ulGrant; DlMsgSchInfo *dlMsgAlloc[MAX_NUM_UE]; /*!< Dl msg allocation per UE*/ diff --git a/src/5gnrsch/sch_common.c b/src/5gnrsch/sch_common.c index d8c677fca..5454db2b9 100644 --- a/src/5gnrsch/sch_common.c +++ b/src/5gnrsch/sch_common.c @@ -1896,7 +1896,6 @@ uint8_t schProcessMsg4Req(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId schAllocPucchResource(cell, pucchTime, cell->raCb[ueId-1].tcrnti, &cell->ueCb[ueId-1], isRetxMsg4, *msg4HqProc); cell->schDlSlotInfo[pdcchTime.slot]->pdcchUe = ueId; - cell->schDlSlotInfo[pdschTime.slot]->pdschUe = ueId; cell->schUlSlotInfo[pucchTime.slot]->pucchUe = ueId; cell->raCb[ueId-1].msg4recvd = FALSE; if(isRetxMsg4) diff --git a/src/5gnrsch/sch_fcfs.c b/src/5gnrsch/sch_fcfs.c index 09e2c64b1..28cc528a3 100644 --- a/src/5gnrsch/sch_fcfs.c +++ b/src/5gnrsch/sch_fcfs.c @@ -1158,12 +1158,13 @@ void schFcfsScheduleSlot(SchCellCb *cell, SlotTimingInfo *slotInd, Inst schInst) bool isMsg4Pending = false, isMsg4Scheduled = false; bool isDlMsgPending = false, isDlMsgScheduled = false; bool isUlGrantPending = false, isUlGrantScheduled = false; + bool isNodeFreed = false; fcfsCell = (SchFcfsCellCb *)cell->schSpcCell; /* Select first UE in the linked list to be scheduled next */ pendingUeNode = fcfsCell->ueToBeScheduled.first; - if(pendingUeNode) + while(pendingUeNode) { if(pendingUeNode->node) { @@ -1215,6 +1216,7 @@ void schFcfsScheduleSlot(SchCellCb *cell, SlotTimingInfo *slotInd, Inst schInst) if(isRarScheduled || isMsg4Scheduled) { schFcfsRemoveUeFrmScheduleLst(cell, pendingUeNode); + isNodeFreed = true; } /* If RAR/MSG4 is pending but couldnt be scheduled then, * put this UE at the end of linked list to be scheduled later */ @@ -1319,9 +1321,23 @@ void schFcfsScheduleSlot(SchCellCb *cell, SlotTimingInfo *slotInd, Inst schInst) else { schFcfsRemoveUeFrmScheduleLst(cell, pendingUeNode); + isNodeFreed = true; } } } + if(cell->schDlSlotInfo[slotInd->slot]->prbAlloc.numPrbAlloc >= MAX_NUM_RB) + { + DU_LOG("\nINFO --> SCH: No PRB available to proceed with next UE"); + return; + } + if(isNodeFreed == false) + { + pendingUeNode= pendingUeNode->next; + } + else + { + pendingUeNode = fcfsCell->ueToBeScheduled.first; + } } } diff --git a/src/5gnrsch/sch_rach.c b/src/5gnrsch/sch_rach.c index e4f6fb468..c002ea744 100644 --- a/src/5gnrsch/sch_rach.c +++ b/src/5gnrsch/sch_rach.c @@ -596,10 +596,6 @@ bool schProcessRaReq(Inst schInst, SchCellCb *cell, SlotTimingInfo currTime, uin ADD_DELTA_TO_TIME(dciTime, rarTime, k0, cell->numSlots); rarSlot = rarTime.slot; - /* If PDSCH is already scheduled on this slot, cannot schedule PDSCH for another UE here. */ - if(cell->schDlSlotInfo[rarSlot]->pdschUe != 0) - continue; - /* If Contention-FREE RA is in progress, allocate resources for * PUCCH for next UL message */ if(cell->raReq[ueId-1]->isCFRA) @@ -784,7 +780,6 @@ bool schProcessRaReq(Inst schInst, SchCellCb *cell, SlotTimingInfo currTime, uin } cell->schDlSlotInfo[dciSlot]->pdcchUe = ueId; - cell->schDlSlotInfo[rarSlot]->pdschUe = ueId; if(cell->raReq[ueId-1]->isCFRA) cell->schUlSlotInfo[pucchTime.slot]->pucchUe = ueId; else diff --git a/src/5gnrsch/sch_slot_ind.c b/src/5gnrsch/sch_slot_ind.c index 4830bd17f..e83a04104 100644 --- a/src/5gnrsch/sch_slot_ind.c +++ b/src/5gnrsch/sch_slot_ind.c @@ -238,7 +238,6 @@ bool schFillBoGrantDlSchedInfo(SchCellCb *cell, SlotTimingInfo currTime, uint8_t schAllocPucchResource(cell, pucchTime, crnti, ueCb, isRetx, *hqP); - cell->schDlSlotInfo[pdschTime.slot]->pdschUe = ueId; cell->schUlSlotInfo[pucchTime.slot]->pucchUe = ueId; /*Re-setting the BO's of all DL LCs in this UE*/ @@ -476,10 +475,6 @@ bool findValidK0K1Value(SchCellCb *cell, SlotTimingInfo currTime, uint8_t ueId, continue; } #endif - if(cell->schDlSlotInfo[pdschTime->slot]->pdschUe != 0) - { - continue; - } numK1 = k0K1InfoTbl->k0k1TimingInfo[pdcchTime->slot].k0Indexes[k0TblIdx].k1TimingInfo.numK1; for(k1TblIdx = 0; k1TblIdx < numK1; k1TblIdx++) diff --git a/src/cm/common_def.h b/src/cm/common_def.h index 9e7bef4cb..c5b8bf6f5 100644 --- a/src/cm/common_def.h +++ b/src/cm/common_def.h @@ -61,7 +61,7 @@ #define MAX_NUM_CELL 2 /* Changed to 2 to support cell Id 2 even if there is only one cell in DU */ #define MAX_NUM_MU 4 #define MAX_NUM_UE 3 -#define MAX_NUM_UE_PER_TTI 1 +#define MAX_NUM_UE_PER_TTI 2 #define MAX_NUM_LC MAX_DRB_LCID + 1 /*Spec 38.331: Sec 6.4: maxLC-ID Keyword*/ #define MAX_NUM_SRB 3 /* Max. no of Srbs */ #define MAX_NUM_DRB 29 /* spec 38.331, maxDRB */