From 2413e14540477c9cf427915adf9342b45f9958b2 Mon Sep 17 00:00:00 2001 From: svaidhya Date: Tue, 5 Dec 2023 16:23:48 +0530 Subject: [PATCH] [Epic-ID: ODUHIGH-517][Task-ID: ODUHIGH-539][SubTask-Id: ODUHIGH-542] Multi UE| DL Candidate Selection| Correction in SearchSpace.MontinoringSlotOffset and Use of Coreset1 for PDCCH alloc of DL Ded Msg Change-Id: Ib76b3c329ae7bd01ed4e92dc364c568b3ed60b4a Signed-off-by: svaidhya --- src/5gnrmac/mac_ue_mgr.c | 6 +- src/5gnrsch/sch.h | 3 + src/5gnrsch/sch_common.c | 34 ++++++++-- src/5gnrsch/sch_utils.c | 85 +++++++++++++++++++++++ src/5gnrsch/sch_utils.h | 2 + src/cm/du_app_mac_inf.h | 38 ++++++----- src/cm/mac_sch_interface.h | 39 ++++++----- src/du_app/du_f1ap_msg_hdl.c | 158 +++++++++++++++++++++++++++++++++++++++++-- src/du_app/du_ue_mgr.c | 4 +- 9 files changed, 325 insertions(+), 44 deletions(-) diff --git a/src/5gnrmac/mac_ue_mgr.c b/src/5gnrmac/mac_ue_mgr.c index e38ef9491..862f3dabd 100644 --- a/src/5gnrmac/mac_ue_mgr.c +++ b/src/5gnrmac/mac_ue_mgr.c @@ -1215,8 +1215,10 @@ uint8_t fillInitDlBwpPdcchCfg(PdcchConfig macPdcchCfg, SchPdcchConfig *schPdcchC macPdcchCfg.searchSpcToAddModList[idx].searchSpaceId; schPdcchCfg->searchSpcToAddModList[idx].cRSetId = \ macPdcchCfg.searchSpcToAddModList[idx].cRSetId; - schPdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset = \ - macPdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset; + schPdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotPeriodicity = \ + macPdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotPeriodicity; + schPdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotOffset = + macPdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotOffset; memcpy(&schPdcchCfg->searchSpcToAddModList[idx].mSymbolsWithinSlot, &macPdcchCfg.searchSpcToAddModList[idx].mSymbolsWithinSlot, \ MONITORING_SYMB_WITHIN_SLOT_SIZE); diff --git a/src/5gnrsch/sch.h b/src/5gnrsch/sch.h index 3d5e9f1ed..95f37f74e 100644 --- a/src/5gnrsch/sch.h +++ b/src/5gnrsch/sch.h @@ -79,6 +79,9 @@ #define SCH_TQ_SIZE 10 +/*3GPP 38.331,'frequencyDomainResources' :Number of PRBs per Resource Block Group*/ +#define NUM_PRBS_PER_RBG 6 + typedef struct schDlHqProcCb SchDlHqProcCb; typedef struct schUlHqEnt SchUlHqEnt; typedef struct schRaReq SchRaReq; diff --git a/src/5gnrsch/sch_common.c b/src/5gnrsch/sch_common.c index c1dee263a..4869129ab 100644 --- a/src/5gnrsch/sch_common.c +++ b/src/5gnrsch/sch_common.c @@ -819,12 +819,13 @@ uint8_t schDlRsrcAllocDlMsg(SchCellCb *cell, SlotTimingInfo slotTime, uint16_t c uint8_t pdschNumSymbols, bool isRetx, SchDlHqProcCb *hqP) { uint8_t ueId=0; - uint8_t cwCount = 0; + uint8_t cwCount = 0, rbgCount = 0, pdcchStartSymbol = 0; PdcchCfg *pdcch = NULLP; PdschCfg *pdsch = NULLP; BwpCfg *bwp = NULLP; SchUeCb ueCb; SchControlRsrcSet coreset1; + SchSearchSpace searchSpace; SchPdschConfig pdschCfg; uint8_t dmrsStartSymbol, startSymbol, numSymbol; @@ -840,6 +841,7 @@ uint8_t schDlRsrcAllocDlMsg(SchCellCb *cell, SlotTimingInfo slotTime, uint16_t c GET_UE_ID(crnti, ueId); ueCb = cell->ueCb[ueId-1]; coreset1 = ueCb.ueCfg.spCellCfg.servCellRecfg.initDlBwp.pdcchCfg.cRSetToAddModList[0]; + searchSpace = ueCb.ueCfg.spCellCfg.servCellRecfg.initDlBwp.pdcchCfg.searchSpcToAddModList[0]; pdschCfg = ueCb.ueCfg.spCellCfg.servCellRecfg.initDlBwp.pdschCfg; /* fill BWP */ @@ -849,22 +851,44 @@ uint8_t schDlRsrcAllocDlMsg(SchCellCb *cell, SlotTimingInfo slotTime, uint16_t c bwp->cyclicPrefix = cell->sib1SchCfg.bwp.cyclicPrefix; /* fill the PDCCH PDU */ - //Considering coreset1 also starts from same symbol as coreset0 - pdcch->coresetCfg.startSymbolIndex = coresetIdxTable[0][3]; + /*StartSymbol of PDCCH*/ + pdcchStartSymbol = findSsStartSymbol(searchSpace.mSymbolsWithinSlot); + if(pdcchStartSymbol < MAX_SYMB_PER_SLOT) + pdcch->coresetCfg.startSymbolIndex = pdcchStartSymbol; + else + { + DU_LOG("\nERROR --> SCH : Invalid SymbolIndex in schDlRsrcAllocDlMsg"); + return RFAILED; + } pdcch->coresetCfg.durationSymbols = coreset1.duration; memcpy(pdcch->coresetCfg.freqDomainResource, coreset1.freqDomainRsrc, FREQ_DOM_RSRC_SIZE); pdcch->coresetCfg.cceRegMappingType = coreset1.cceRegMappingType; /* non-interleaved */ pdcch->coresetCfg.regBundleSize = 6; /* must be 6 for non-interleaved */ pdcch->coresetCfg.interleaverSize = 0; /* NA for non-interleaved */ pdcch->coresetCfg.coreSetType = 1; /* non PBCH coreset */ - //Considering number of RBs in coreset1 is same as coreset0 - pdcch->coresetCfg.coreSetSize = coresetIdxTable[0][1]; + + /*Size of coreset: Number of PRBs in a coreset*/ + rbgCount = countRBGFrmCoresetFreqRsrc(coreset1.freqDomainRsrc); + if(rbgCount) + { + pdcch->coresetCfg.coreSetSize = ((rbgCount) * NUM_PRBS_PER_RBG); + } + else + { + DU_LOG("\nERROR --> SCH : CORESETSize is zero in schDlRsrcAllocDlMsg"); + return RFAILED; + } + pdcch->coresetCfg.shiftIndex = cell->cellCfg.phyCellId; pdcch->coresetCfg.precoderGranularity = coreset1.precoderGranularity; pdcch->numDlDci = 1; pdcch->dci.rnti = ueCb.crnti; pdcch->dci.scramblingId = cell->cellCfg.phyCellId; pdcch->dci.scramblingRnti = 0; + + /*TODO below assumptions of CCE Index is wrong: + * Range 0 to 135 as per ORAN.WG8.AAD Table 9-35 CORESET configuration and + * it has to be calculated using the formula given in 3GPP TS 38.213, Sec 10.1 */ pdcch->dci.cceIndex = 0; /* 0-3 for UL and 4-7 for DL */ pdcch->dci.aggregLevel = 4; pdcch->dci.beamPdcchInfo.numPrgs = 1; diff --git a/src/5gnrsch/sch_utils.c b/src/5gnrsch/sch_utils.c index e4775eb27..218b70b81 100644 --- a/src/5gnrsch/sch_utils.c +++ b/src/5gnrsch/sch_utils.c @@ -1786,6 +1786,91 @@ uint8_t calculateSlotPatternLength(uint8_t scs, uint8_t periodicity) } #endif +/** + * @brief Function to find start Symbol Index of Coreset defined in SearchSpace(SS) + * + * @details + * + * Function: findSsStartSymbol + * + * This function finds first the startSymbol Index of a CORESET + * which is defined in SearchSpace.monitoringSymbolWithinSlot parameter + * + * @param[in] uint8_t mSymbolsWithinSlot[2] + * mSymbolsWithinSlot[0] >> MSB as 7th Symbol to LSB as 0th Symbol + * mSymbolsWithinSlot[1] >> 0th bit as 8th Symbol, 1st bit as 9th, + * ...,5th bit as 13th symbol + * @return Success : First SS Symbol Index + * Failure : MAX_SYMB_PER_SLOT(Invalid value of SymbolIndex = 14) +**/ +uint8_t findSsStartSymbol(uint8_t *mSymbolsWithinSlot) +{ + uint8_t symbolIdx = 0; + uint8_t i = 1, symPos = 0; + + for(symbolIdx = 0; symbolIdx < MONITORING_SYMB_WITHIN_SLOT_SIZE; symbolIdx++) + { + i = 1, symPos = 0; + while(i) + { + /*The first Symbol(or bit) enabled(set) is the StartSymbol of SS thus + *returning if we find that bitPosition */ + if(mSymbolsWithinSlot[symbolIdx] & i) + { + /*Adding (SymbolIdx*8) for SymbolIndex between 8 and 13*/ + return (symPos + (symbolIdx * 8)); + } + i = i << 1; + symPos++; + } + } + return(MAX_SYMB_PER_SLOT); +} + +/** + * @brief Function to count number of RBG from Coreset's FreqDomainResource + * + * @details + * + * Function: countRBGFrmCoresetFreqRsrc + * + * This function counts RBG for calculating the coresetSize using CORESET.freqDomainResource + * In this, we will find the number of RBG groups which are allowed for this + * coreset + * + * @param[in] uint8_t freqDomainRsrc[6] (As per Spec 38.331, ControlResourceSet.frequencyDomainResources) + * freqDomainRsrc[0] =RBG0 to RBG7 + * freqDomainRsrc[1] =RBG8 to RBG15 + * ... + * freqDomainRsrc[5] =RBG40 to RBG47 + * (Every RBG has 6 PRBs) + * @return Success : Total Number of RGBs in CORESET which can be allocated + * Failure : 0 +**/ +uint8_t countRBGFrmCoresetFreqRsrc(uint8_t *freqDomainRsrc) +{ + uint8_t freqIdx = 0, idx = 1; + uint8_t count = 0; + + for(freqIdx = 0; freqIdx < FREQ_DOM_RSRC_SIZE; freqIdx++) + { + if(freqDomainRsrc[freqIdx] & 0xFF) + { + idx = 1; + count = 0; + while(idx) + { + if(freqDomainRsrc[freqIdx] & idx) + { + count++; + } + idx = idx << 1; + } + } + } + return count; +} + /********************************************************************** End of file **********************************************************************/ diff --git a/src/5gnrsch/sch_utils.h b/src/5gnrsch/sch_utils.h index 433c33e49..c6b7fab6e 100644 --- a/src/5gnrsch/sch_utils.h +++ b/src/5gnrsch/sch_utils.h @@ -136,6 +136,8 @@ void deleteLcLL(CmLListCp *lcLL); CmLList *schPageInfoSearchFromPageList(SlotTimingInfo slotInfo, CmLListCp *storedPageList); void schDeleteFromPageInfoList(CmLListCp *list, CmLList *node); +uint8_t countRBGFrmCoresetFreqRsrc(uint8_t *freqDomainRsrc); +uint8_t findSsStartSymbol(uint8_t *mSymbolsWithinSlot); #if 0 /*Will be enabled for debugging*/ void printLcLL(CmLListCp *lcLL); diff --git a/src/cm/du_app_mac_inf.h b/src/cm/du_app_mac_inf.h index 9631cc597..32cd057b3 100644 --- a/src/cm/du_app_mac_inf.h +++ b/src/cm/du_app_mac_inf.h @@ -364,22 +364,22 @@ typedef enum typedef enum { - SLOTPERIODICITYANDOFFSET_PR_SL1 = 1, - SLOTPERIODICITYANDOFFSET_PR_SL2, - SLOTPERIODICITYANDOFFSET_PR_SL4, - SLOTPERIODICITYANDOFFSET_PR_SL5, - SLOTPERIODICITYANDOFFSET_PR_SL8, - SLOTPERIODICITYANDOFFSET_PR_SL10, - SLOTPERIODICITYANDOFFSET_PR_SL16, - SLOTPERIODICITYANDOFFSET_PR_SL20, - SLOTPERIODICITYANDOFFSET_PR_SL40, - SLOTPERIODICITYANDOFFSET_PR_SL80, - SLOTPERIODICITYANDOFFSET_PR_SL160, - SLOTPERIODICITYANDOFFSET_PR_SL320, - SLOTPERIODICITYANDOFFSET_PR_SL640, - SLOTPERIODICITYANDOFFSET_PR_SL1280, - SLOTPERIODICITYANDOFFSET_PR_SL2560 -}MSlotPeriodAndOffset; + SLOTPERIODICITY_PR_SL1 = 1, + SLOTPERIODICITY_PR_SL2, + SLOTPERIODICITY_PR_SL4, + SLOTPERIODICITY_PR_SL5, + SLOTPERIODICITY_PR_SL8, + SLOTPERIODICITY_PR_SL10, + SLOTPERIODICITY_PR_SL16, + SLOTPERIODICITY_PR_SL20, + SLOTPERIODICITY_PR_SL40, + SLOTPERIODICITY_PR_SL80, + SLOTPERIODICITY_PR_SL160, + SLOTPERIODICITY_PR_SL320, + SLOTPERIODICITY_PR_SL640, + SLOTPERIODICITY_PR_SL1280, + SLOTPERIODICITY_PR_SL2560 +}MSlotPeriodicity; typedef enum { @@ -1010,6 +1010,12 @@ typedef struct controlRsrcSet uint16_t dmrsScramblingId; }ControlRsrcSet; +typedef struct mSlotPeriodAndOffset +{ + MSlotPeriodicity mSlotPeriodicity; + uint16_t mSlotOffset; +}MSlotPeriodAndOffset; + /* Search Space info */ typedef struct searchSpace { diff --git a/src/cm/mac_sch_interface.h b/src/cm/mac_sch_interface.h index 769ff9d52..4166a8e9c 100644 --- a/src/cm/mac_sch_interface.h +++ b/src/cm/mac_sch_interface.h @@ -292,22 +292,22 @@ typedef enum typedef enum { - SLOT_PERIODICITY_AND_OFFSET_SL_1 = 1, - SLOT_PERIODICITY_AND_OFFSET_SL_2, - SLOT_PERIODICITY_AND_OFFSET_SL_4, - SLOT_PERIODICITY_AND_OFFSET_SL_5, - SLOT_PERIODICITY_AND_OFFSET_SL_8, - SLOT_PERIODICITY_AND_OFFSET_SL_10, - SLOT_PERIODICITY_AND_OFFSET_SL_16, - SLOT_PERIODICITY_AND_OFFSET_SL_20, - SLOT_PERIODICITY_AND_OFFSET_SL_40, - SLOT_PERIODICITY_AND_OFFSET_SL_80, - SLOT_PERIODICITY_AND_OFFSET_SL_160, - SLOT_PERIODICITY_AND_OFFSET_SL_320, - SLOT_PERIODICITY_AND_OFFSET_SL_640, - SLOT_PERIODICITY_AND_OFFSET_SL_1280, - SLOT_PERIODICITY_AND_OFFSET_SL_2560 -}SchMSlotPeriodAndOffset; + SLOT_PERIODICITY_SL_1 = 1, + SLOT_PERIODICITY_SL_2, + SLOT_PERIODICITY_SL_4, + SLOT_PERIODICITY_SL_5, + SLOT_PERIODICITY_SL_8, + SLOT_PERIODICITY_SL_10, + SLOT_PERIODICITY_SL_16, + SLOT_PERIODICITY_SL_20, + SLOT_PERIODICITY_SL_40, + SLOT_PERIODICITY_SL_80, + SLOT_PERIODICITY_SL_160, + SLOT_PERIODICITY_SL_320, + SLOT_PERIODICITY_SL_640, + SLOT_PERIODICITY_SL_1280, + SLOT_PERIODICITY_SL_2560 +}SchMSlotPeriodicity; typedef enum { @@ -1442,6 +1442,13 @@ typedef struct schControlRsrcSet uint16_t dmrsScramblingId; }SchControlRsrcSet; +/*Slot Perioicity and Offset*/ +typedef struct schMSlotPeriodAndOffset +{ + SchMSlotPeriodicity mSlotPeriodicity; + uint16_t mSlotOffset; +}SchMSlotPeriodAndOffset; + /* Search Space info */ typedef struct schSearchSpace { diff --git a/src/du_app/du_f1ap_msg_hdl.c b/src/du_app/du_f1ap_msg_hdl.c index d9b5022d7..85f3396e4 100644 --- a/src/du_app/du_f1ap_msg_hdl.c +++ b/src/du_app/du_f1ap_msg_hdl.c @@ -3954,6 +3954,76 @@ uint8_t BuildControlRSetToAddModList(PdcchConfig *pdcchCfg, struct PDCCH_Config_ return ROK; } /* End BuildControlRSetToAddModList */ +/******************************************************************* + * + * @brief build SlotOffset for SearchSpace + * + * @details + * + * Function : BuildSearchSpcSlotOffset + * + * Functionality: Build Slot Offset for search space to add/modify list + * + * @params[in] SearchSpace__monitoringSlotPeriodicityAndOffset *mSlotPeriodicityAndOffset + * uint16_t slotOffset + * @return void + * + * ****************************************************************/ +void BuildSearchSpcSlotOffset(struct SearchSpace__monitoringSlotPeriodicityAndOffset *mSlotPeriodicityAndOffset, uint16_t slotOffset) +{ + switch(mSlotPeriodicityAndOffset->present) + { + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1: + mSlotPeriodicityAndOffset->choice.sl1 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl2: + mSlotPeriodicityAndOffset->choice.sl2 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl4: + mSlotPeriodicityAndOffset->choice.sl4 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl5: + mSlotPeriodicityAndOffset->choice.sl5 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl8: + mSlotPeriodicityAndOffset->choice.sl8 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl10: + mSlotPeriodicityAndOffset->choice.sl10 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl16: + mSlotPeriodicityAndOffset->choice.sl16 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl20: + mSlotPeriodicityAndOffset->choice.sl20 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl40: + mSlotPeriodicityAndOffset->choice.sl40 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl80: + mSlotPeriodicityAndOffset->choice.sl80 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl160: + mSlotPeriodicityAndOffset->choice.sl160 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl320: + mSlotPeriodicityAndOffset->choice.sl320 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl640: + mSlotPeriodicityAndOffset->choice.sl640 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1280: + mSlotPeriodicityAndOffset->choice.sl1280 = slotOffset; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl2560: + mSlotPeriodicityAndOffset->choice.sl2560 = slotOffset; + break; + default: + break; + } +} + + /******************************************************************* * * @brief Build search space to add/modify list @@ -4036,7 +4106,12 @@ uint8_t BuildSearchSpcToAddModList(PdcchConfig *pdcchCfg, struct PDCCH_Config__s if(pdcchCfg == NULLP) searchSpc->monitoringSlotPeriodicityAndOffset->present = SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1; else - searchSpc->monitoringSlotPeriodicityAndOffset->present = pdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset; + { + searchSpc->monitoringSlotPeriodicityAndOffset->present = \ + pdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotPeriodicity; + BuildSearchSpcSlotOffset(searchSpc->monitoringSlotPeriodicityAndOffset, \ + pdcchCfg->searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotOffset); + } searchSpc->duration = NULLP; searchSpc->monitoringSymbolsWithinSlot = NULLP; @@ -4182,7 +4257,6 @@ uint8_t BuildBWPDlDedPdcchCfg(PdcchConfig *pdcchCfgDb, struct PDCCH_Config *pdcc } /******************************************************************* - * * @brief Builds DMRS DL PDSCH Mapping type A * * @details @@ -11036,6 +11110,80 @@ void extractTagReconfig(TAG_Config_t *cuTagCfg, TagCfg *macTagCfg) } } +/******************************************************************* + * + * @brief Fills SlotOffset value for SearchSpace received by CU + * + * @details + * + * Function : extractSlotOffset + * + * Functionality: Fills SlotOffset received by CU + * + * @params[in] SearchSpace__monitoringSlotPeriodicityAndOffset *mSlotPeriodicityOffset, + * uint16_t *slotOffset + * @return void + * + * + ****************************************************************/ +void extractSlotOffset(struct SearchSpace__monitoringSlotPeriodicityAndOffset *mSlotPeriodicityAndOffset, uint16_t *slotOffset) +{ + switch(mSlotPeriodicityAndOffset->present) + { + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_NOTHING: + *slotOffset = NULLD; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl1; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl2: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl2; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl4: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl4; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl5: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl5; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl8: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl8; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl10: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl10; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl16: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl16; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl20: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl20; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl40: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl40; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl80: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl80; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl160: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl160; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl320: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl320; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl640: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl640; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl1280: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl1280; + break; + case SearchSpace__monitoringSlotPeriodicityAndOffset_PR_sl2560: + *slotOffset = mSlotPeriodicityAndOffset->choice.sl2560; + break; + default: + *slotOffset = 0; + } +} + + /******************************************************************* * * @brief Fills PdcchCfg received by CU @@ -11128,8 +11276,10 @@ void extractPdcchCfg(PDCCH_Config_t *cuPdcchCfg, PdcchConfig *macPdcchCfg) *(srchSpcToAddModList->list.array[srchSpcIdx]->controlResourceSetId); if(srchSpcToAddModList->list.array[srchSpcIdx]->monitoringSlotPeriodicityAndOffset) { - macPdcchCfg->searchSpcToAddModList[srchSpcIdx].mSlotPeriodicityAndOffset =\ - srchSpcToAddModList->list.array[srchSpcIdx]->monitoringSlotPeriodicityAndOffset->present; + macPdcchCfg->searchSpcToAddModList[srchSpcIdx].mSlotPeriodicityAndOffset.mSlotPeriodicity =\ + srchSpcToAddModList->list.array[srchSpcIdx]->monitoringSlotPeriodicityAndOffset->present; + extractSlotOffset(srchSpcToAddModList->list.array[srchSpcIdx]->monitoringSlotPeriodicityAndOffset,\ + &macPdcchCfg->searchSpcToAddModList[srchSpcIdx].mSlotPeriodicityAndOffset.mSlotOffset); } if(srchSpcToAddModList->list.array[srchSpcIdx]->monitoringSymbolsWithinSlot) { diff --git a/src/du_app/du_ue_mgr.c b/src/du_app/du_ue_mgr.c index 7d75f003e..86f4b7e16 100644 --- a/src/du_app/du_ue_mgr.c +++ b/src/du_app/du_ue_mgr.c @@ -737,7 +737,9 @@ uint8_t fillDefaultInitDlBwp(InitialDlBwp *initDlBwp) { initDlBwp->pdcchCfg.searchSpcToAddModList[idx].searchSpaceId = PDCCH_SRCH_SPC_TWO_ID; initDlBwp->pdcchCfg.searchSpcToAddModList[idx].cRSetId = PDCCH_CTRL_RSRC_SET_ONE_ID; - initDlBwp->pdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset = SLOTPERIODICITYANDOFFSET_PR_SL1; + initDlBwp->pdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotPeriodicity\ + = SLOTPERIODICITY_PR_SL1; + initDlBwp->pdcchCfg.searchSpcToAddModList[idx].mSlotPeriodicityAndOffset.mSlotOffset = 0; memset(initDlBwp->pdcchCfg.searchSpcToAddModList[idx].mSymbolsWithinSlot, 0, MONITORING_SYMB_WITHIN_SLOT_SIZE); initDlBwp->pdcchCfg.searchSpcToAddModList[idx].mSymbolsWithinSlot[idx] = PDCCH_SYMBOL_WITHIN_SLOT; initDlBwp->pdcchCfg.searchSpcToAddModList[idx].numCandidatesAggLevel1 = AGGREGATIONLEVEL_N8; -- 2.16.6