<DU_ID>1</DU_ID>
<DU_NAME>ORAN OAM DU</DU_NAME>
<MAX_NUM_DRB>29</MAX_NUM_DRB>
- <MAX_NUM_UE_SUPPORTED>3</MAX_NUM_UE_SUPPORTED>
- <MAX_NUM_UE>32</MAX_NUM_UE>
<DU_IP_V4_ADDR>192.168.130.81</DU_IP_V4_ADDR>
<CU_IP_V4_ADDR>192.168.130.82</CU_IP_V4_ADDR>
<RIC_IP_V4_ADDR>192.168.130.80</RIC_IP_V4_ADDR>
</RRM_POLICY_RATIO>
</MAC_SLICE_RRM_POLICY>
</SLICE_CFG>
- <RADIO_FRAME_DURATION>10</RADIO_FRAME_DURATION>
- <MAX_NUM_CELL>2</MAX_NUM_CELL>
- <MAX_NUM_MU>4</MAX_NUM_MU>
- <MAX_NUM_UE_PER_TTI>1</MAX_NUM_UE_PER_TTI>
- <MAX_DRB_LCID>32</MAX_DRB_LCID>
- <MAX_NUM_SRB>3</MAX_NUM_SRB>
- <MAX_NUM_SSB>64</MAX_NUM_SSB>
- <MAX_NUM_HARQ_PROC>16</MAX_NUM_HARQ_PROC>
- <MAX_NUM_TB_PER_UE>2</MAX_NUM_TB_PER_UE>
- <PHY_DELTA_DL>1</PHY_DELTA_DL>
- <ODU_START_CRNTI>100</ODU_START_CRNTI>
- <ODU_END_CRNTI>500</ODU_END_CRNTI>
- <DEFAULT_MCS>4</DEFAULT_MCS>
- <BANDWIDTH>20</BANDWIDTH>
- <MAX_NUM_RB>106</MAX_NUM_RB>
- <ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL>5</ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL>
- <ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL>60000</ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL>
- <MAX_PO_PER_PF>4</MAX_PO_PER_PF>
- <MAX_SLOTS>10</MAX_SLOTS>
- <MAX_SFN>1024</MAX_SFN>
- <BASE_SCS>15</BASE_SCS>
- <MAX_SYMB_PER_SLOT>14</MAX_SYMB_PER_SLOT>
<DU_TIMER_INFO>
<TIMER_TQ_CP>
<TIMER_LEN>2</TIMER_LEN>
</RAN_FUNCTION>
</RAN_FUNCTION_LIST>
</E2AP_CFG>
+ <GLOBAL_CFG>
+ <RADIO_FRAME_DURATION>10</RADIO_FRAME_DURATION>
+ <PHY_DELTA_DL>1</PHY_DELTA_DL>
+ <PHY_DELTA_UL>1</PHY_DELTA_UL>
+ <ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL>5</ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL>
+ <ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL>60000</ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL>
+<!--
+ <MAX_NUM_CELL>2</MAX_NUM_CELL>
+ <MAX_NUM_MU>4</MAX_NUM_MU>
+ <MAX_NUM_UE>3</MAX_NUM_UE>
+ <MAX_NUM_UE_PER_TTI>1</MAX_NUM_UE_PER_TTI>
+ <MAX_DRB_LCID>32</MAX_DRB_LCID>
+ <MAX_NUM_SRB>3</MAX_NUM_SRB>
+ <MAX_NUM_DRB>29</MAX_NUM_DRB>
+ <MAX_NUM_SSB>64</MAX_NUM_SSB>
+ <MAX_NUM_HARQ_PROC>16</MAX_NUM_HARQ_PROC>
+ <MAX_NUM_TB_PER_UE>2</MAX_NUM_TB_PER_UE>
+ <ODU_START_CRNTI>100</ODU_START_CRNTI>
+ <ODU_END_CRNTI>500</ODU_END_CRNTI>
+ <BANDWIDTH>20</BANDWIDTH>
+ <MAX_NUM_RB>106</MAX_NUM_RB>
+ <MAX_SLOTS>10</MAX_SLOTS>
+ <MAX_SFN>1024</MAX_SFN>
+ <MAX_SYMB_PER_SLOT>14</MAX_SYMB_PER_SLOT>
+ <MAX_NUM_STATS_GRP>5</MAX_NUM_STATS_GRP>
+ <MAX_NUM_STATS>10</MAX_NUM_STATS>
+ <MAX_TDD_PERIODICITY_SLOTS>100</MAX_TDD_PERIODICITY_SLOTS>
+-->
+ </GLOBAL_CFG>
</DU_CFG_PARAMS>
{
GET_CELL_IDX(currTimingInfo.cellId, cellIdx);
/* consider phy delay */
- ADD_DELTA_TO_TIME(currTimingInfo,dlTtiReqTimingInfo,PHY_DELTA_DL, macCb.macCell[cellIdx]->numOfSlots);
+ ADD_DELTA_TO_TIME(currTimingInfo,dlTtiReqTimingInfo,gConfigInfo.gPhyDeltaDl, macCb.macCell[cellIdx]->numOfSlots);
dlTtiReqTimingInfo.cellId = currTimingInfo.cellId;
macCellCfg = macCb.macCell[cellIdx]->macCellCfg;
macCellCfg = macCb.macCell[cellIdx]->macCellCfg;
/* add PHY delta */
- ADD_DELTA_TO_TIME(currTimingInfo,ulTtiReqTimingInfo,PHY_DELTA_UL, macCb.macCell[cellIdx]->numOfSlots);
+ ADD_DELTA_TO_TIME(currTimingInfo,ulTtiReqTimingInfo,gConfigInfo.gPhyDeltaUl, macCb.macCell[cellIdx]->numOfSlots);
currUlSlot = &macCb.macCell[cellIdx]->ulSlot[ulTtiReqTimingInfo.slot % macCb.macCell[cellIdx]->numOfSlots];
LWR_MAC_ALLOC(ulTtiElem, (sizeof(fapi_api_queue_elem_t) + sizeof(fapi_ul_tti_req_t)));
uint8_t MacProcCellStart(Pst *pst, CellStartInfo *cellStart)
{
DU_LOG("\nINFO --> MAC : Handling cell start request");
- gSlotCount = 0;
+ gConfigInfo.gSlotCount = 0;
sendToLowerMac(START_REQUEST, 0, cellStart);
MAC_FREE_SHRABL_BUF(pst->region, pst->pool, cellStart, \
GET_CELL_IDX(currTimingInfo.cellId, cellIdx);
- ADD_DELTA_TO_TIME(currTimingInfo, muxTimingInfo, PHY_DELTA_DL, macCb.macCell[cellIdx]->numOfSlots);
+ ADD_DELTA_TO_TIME(currTimingInfo, muxTimingInfo, gConfigInfo.gPhyDeltaDl, macCb.macCell[cellIdx]->numOfSlots);
currDlSlot = &macCb.macCell[cellIdx]->dlSlot[muxTimingInfo.slot];
for(ueIdx=0; ueIdx<MAX_NUM_UE; ueIdx++)
#endif
/*starting Task*/
ODU_START_TASK(&startTime, PID_MAC_TTI_IND);
- gSlotCount++;
+ gConfigInfo.gSlotCount++;
- if(gSlotCount == 1)
+ if(gConfigInfo.gSlotCount == 1)
{
GET_CELL_IDX(slotInd->cellId, cellIdx);
macCb.macCell[cellIdx]->state = CELL_STATE_UP;
/*First Slot Ind is for CellUp. Any other Slot, will be notified to DUAPP as
* SLOT_IND*/
- if(gSlotCount == 1)
+ if(gConfigInfo.gSlotCount == 1)
{
/* send cell up indication to du app */
ret = sendCellUpIndMacToDuApp(slotInd->cellId);
case EVENT_RLC_UE_THROUGHPUT_TMR:
{
RlcThpt *thptCb = (RlcThpt *)cb;
- TMR_CALCUATE_WAIT(arg.wait, ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL, gCb->genCfg.timeRes);
+ TMR_CALCUATE_WAIT(arg.wait, gConfigInfo.gUeThrptTimeIntervl, gCb->genCfg.timeRes);
arg.timers = &thptCb->ueTputInfo.ueThptTmr;
arg.max = RLC_MAX_THPT_TMR;
break;
case EVENT_RLC_SNSSAI_THROUGHPUT_TMR:
{
RlcThpt *thptCb = (RlcThpt *)cb;
- TMR_CALCUATE_WAIT(arg.wait, ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL, gCb->genCfg.timeRes);
+ TMR_CALCUATE_WAIT(arg.wait, gConfigInfo.gSnssaiThrptTimeIntervl, gCb->genCfg.timeRes);
arg.timers = &thptCb->snssaiTputInfo.snssaiThptTmr;
arg.max = RLC_MAX_THPT_TMR;
break;
RlcThpt *rlcThptCb = (RlcThpt*)cb;
/* If cell is not up, throughput details cannot be printed */
- if(gCellStatus != CELL_UP)
+ if(gConfigInfo.gCellStatus != CELL_UP)
{
/* Restart timer */
rlcStartTmr(RLC_GET_RLCCB(rlcThptCb->inst), (PTR)(rlcThptCb), EVENT_RLC_UE_THROUGHPUT_TMR);
* Since our dataVol is in bytes, multiplying 0.008 to covert into kilobits i.e.
* Throughput[kbits/sec] = (dataVol * 0.008 * 1000)/time in ms
*/
- tpt = (double)(rlcThptCb->ueTputInfo.thptPerUe[ueIdx].dataVol * 8)/(double)ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL;
+ tpt = (double)(rlcThptCb->ueTputInfo.thptPerUe[ueIdx].dataVol * 8)/(double)gConfigInfo.gUeThrptTimeIntervl;
DU_LOG("\nUE Id : %d DL Tpt : %.2Lf", rlcThptCb->ueTputInfo.thptPerUe[ueIdx].ueId, tpt);
rlcThptCb->ueTputInfo.thptPerUe[ueIdx].dataVol = 0;
static uint8_t snssaiTputBitmap = DIR_NONE;
/* If cell is not up, throughput details cannot be printed */
- if(gCellStatus != CELL_UP)
+ if(gConfigInfo.gCellStatus != CELL_UP)
{
/* Restart timer */
rlcStartTmr(RLC_GET_RLCCB(rlcThptCb->inst), (PTR)(rlcThptCb), EVENT_RLC_SNSSAI_THROUGHPUT_TMR);
while(node)
{
snssaiNode = (RlcTptPerSnssai *)node->node;
- snssaiNode->tpt = (double)(snssaiNode->dataVol * 8)/(double)(ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL * 0.001);
+ snssaiNode->tpt = (double)(snssaiNode->dataVol * 8)/(double)(gConfigInfo.gSnssaiThrptTimeIntervl * 0.001);
if(dir == DIR_DL)
{
memset(&ulSchedInfo, 0, sizeof(UlSchedInfo));
/* add PHY delta */
- ADD_DELTA_TO_TIME(cell->slotInfo,ulTimingInfo,PHY_DELTA_UL+SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo,ulTimingInfo,gConfigInfo.gPhyDeltaUl+SCHED_DELTA, cell->numSlots);
ulSchedInfo.cellId = cell->cellId;
ulSchedInfo.slotIndInfo.cellId = ulSchedInfo.cellId;
}
/* Calculating time frame to send DCI for SR */
- ADD_DELTA_TO_TIME(currTime, dciTime, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(currTime, dciTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
#ifdef NR_TDD
if(schGetSlotSymbFrmt(dciTime.slot, cell->slotFrmtBitMap) == DL_SLOT)
#endif
currTime = cell->slotInfo;
/* Calculating time frame to send DCI for MSG3 Retx*/
- ADD_DELTA_TO_TIME(currTime, dciTime, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(currTime, dciTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
#ifdef NR_TDD
/* Consider this slot for sending DCI, only if it is a DL slot */
if(schGetSlotSymbFrmt(dciSlot, raCb->cell->slotFrmtBitMap) == DL_SLOT)
if((ueCb->drxUeCb.onDurationExpiryDistance != SCH_DRX_INVALID_DISTANCE) && (ueCb->drxUeCb.onDurationExpiryIndex != SCH_DRX_INVALID_INDEX))
{
currentSlotTime = cell->slotInfo.sfn * cell->numSlots + cell->slotInfo.slot;
- currentSlotIndx = (currentSlotTime + PHY_DELTA_DL + SCHED_DELTA)%MAX_DRX_SIZE;
+ currentSlotIndx = (currentSlotTime + gConfigInfo.gPhyDeltaDl + SCHED_DELTA)%MAX_DRX_SIZE;
if(currentSlotIndx >= ueCb->drxUeCb.onDurationExpiryIndex )
{
onDurExpSlotTime = currentSlotTime + ((ueCb->drxUeCb.onDurationExpiryDistance +1) * MAX_DRX_SIZE) +\
- (ueCb->drxUeCb.onDurationExpiryIndex - currentSlotIndx + PHY_DELTA_DL + SCHED_DELTA);
+ (ueCb->drxUeCb.onDurationExpiryIndex - currentSlotIndx + gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
}
else
{
onDurExpSlotTime = currentSlotTime + ((ueCb->drxUeCb.onDurationExpiryDistance) * MAX_DRX_SIZE) +\
- (ueCb->drxUeCb.onDurationExpiryIndex - currentSlotIndx + PHY_DELTA_DL + SCHED_DELTA);
+ (ueCb->drxUeCb.onDurationExpiryIndex - currentSlotIndx + gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
}
if(onDurTime <= onDurExpSlotTime)
{
uint16_t dlIndx = 0, ulIndx=0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
}
/* recalculate the new index of on duration start based on short cycle */
- schAddUeInOndurationList(cell, ueCb, PHY_DELTA_DL + SCHED_DELTA);
+ schAddUeInOndurationList(cell, ueCb, gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
/* if any node is present in short cycle exp list then remove the node from list */
if(ueCb->drxUeCb.shortCycleExpiryIndex != SCH_DRX_INVALID_INDEX && ueCb->drxUeCb.shortCycleDistance != SCH_DRX_INVALID_DISTANCE)
uint16_t dlIndx = 0, ulIndx=0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
uint16_t dlIndx = 0, ulIndx=0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
uint16_t dlIndx = 0, ulIndx = 0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
uint16_t dlIndx = 0, ulIndx = 0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
ueCb->drxUeCb.onDurationStartDistance = SCH_DRX_INVALID_DISTANCE;
/* Recalculate on-duration with long cycle */
- schAddUeInOndurationList(cell, ueCb, PHY_DELTA_DL + SCHED_DELTA);
+ schAddUeInOndurationList(cell, ueCb, gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
}
}
}
uint16_t dlIndx = 0, ulIndx= 0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
uint16_t dlIndx = 0, ulIndx = 0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
uint16_t dlIndx = 0, ulIndx = 0;
SlotTimingInfo dlSlotInfo, ulSlotInfo;
- ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
- ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, PHY_DELTA_UL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, dlSlotInfo, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(cell->slotInfo, ulSlotInfo, gConfigInfo.gPhyDeltaUl + SCHED_DELTA, cell->numSlots);
dlIndx = (dlSlotInfo.sfn*MAX_SLOTS+dlSlotInfo.slot)%MAX_DRX_SIZE;
ulIndx = (ulSlotInfo.sfn*MAX_SLOTS+ulSlotInfo.slot)%MAX_DRX_SIZE;
else
{
#ifdef NR_DRX
- schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], PHY_DELTA_DL + SCHED_DELTA);
+ schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
#endif
}
}
else
{
#ifdef NR_DRX
- schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], PHY_DELTA_UL + SCHED_DELTA);
+ schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], gConfigInfo.gPhyDeltaUl + SCHED_DELTA);
#endif
}
}
}
/* Calculating time frame to send DCI for RAR */
- ADD_DELTA_TO_TIME(currTime, dciTime, PHY_DELTA_DL + SCHED_DELTA, cell->numSlots);
+ ADD_DELTA_TO_TIME(currTime, dciTime, gConfigInfo.gPhyDeltaDl + SCHED_DELTA, cell->numSlots);
dciSlot = dciTime.slot;
#ifdef NR_TDD
/* Consider this slot for sending DCI, only if it is a DL slot */
else
{
#ifdef NR_DRX
- schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], PHY_DELTA_DL + SCHED_DELTA);
+ schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], gConfigInfo.gPhyDeltaDl + SCHED_DELTA);
#endif
}
}
else
{
#ifdef NR_DRX
- schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], PHY_DELTA_UL + SCHED_DELTA);
+ schHdlDrxInActvStrtTmr(cell, &cell->ueCb[ueId-1], gConfigInfo.gPhyDeltaUl + SCHED_DELTA);
#endif
}
}
* 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);
}
/*******************************************************************
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)
{
{
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;
#define SCH_INST_START 1
#define SCH_MAX_INST 1
-#define RADIO_FRAME_DURATION 10 /* Time duration of a radio frame in ms */
/* MAX values */
#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_HARQ_PROC 16 /* spec 38.331, nrofHARQ-ProcessesForPDSCH */
#define MAX_NUM_TB_PER_UE 2 /* spec 38.331, maxNrofCodeWordsScheduledByDCI */
-/* 5G ORAN phy delay */
-#ifdef NR_TDD
-#define PHY_DELTA_DL 2
-#define PHY_DELTA_UL 0
-#else
-#define PHY_DELTA_DL 1
-#define PHY_DELTA_UL 0
-#endif
-
/* SELECTORS */
#define ODU_SELECTOR_LC 0
#define ODU_SELECTOR_TC 1
#define MAX_NUM_RB TOTAL_PRB_20MHZ_MU0 /* value for numerology 0, 20 MHz */
#endif
-#define ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL 5 /* in milliseconds */
-#define ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL 60000 /* in milliseconds */
-
/*Spec 38.331 Sec 6.4: Maximum number of paging occasion per paging frame*/
#define MAX_PO_PER_PF 4
/*First SCS in kHz as per 3gpp spec 38.211 Table 4.2-1 */
#define BASE_SCS 15
-#define MAX_NUM_STATS_CFG 2 /* Max number of statistics configuration/Subscription supported */
#define MAX_NUM_STATS_GRP 5 /* Max number of statistics group per configuration request */
#define MAX_NUM_STATS 10 /* Max number of statistics per group */
}TDDCfg;
#endif
-OduCellStatus gCellStatus;
-uint64_t gSlotCount;
-uint64_t gDlDataRcvdCnt; /* Number of DL data received at EGTP */
+typedef struct gConfiguration
+{
+ uint8_t gPhyDeltaDl;
+ uint8_t gPhyDeltaUl;
+ uint8_t gUeThrptTimeIntervl;
+ uint8_t gSnssaiThrptTimeIntervl;
+ uint8_t gRadioFrameDuration;
+ OduCellStatus gCellStatus;
+ uint64_t gSlotCount;
+ uint64_t gDlDataRcvdCnt; /* Number of DL data received at EGTP */
+}GConfiguration;
+
+GConfiguration gConfigInfo;
void fillCoresetFeqDomAllocMap(uint16_t startPrb, uint16_t prbSize, uint8_t *freqDomain);
void oduCpyFixBufToMsg(uint8_t *fixBuf, Buffer *mBuf, uint16_t len);
typedef struct csiRsCfg
{
- uint8_t *csiFreqDomainAlloc;
+ uint8_t *csiFreqDomainAlloc;
uint8_t csiNrofPorts;
uint8_t csirsfirstOFDMSymbolInTimeDomain;
uint8_t csirsfirstOFDMSymbolInTimeDomain2;
CarrierCfg carrCfg; /* Carrier configuration */
CellCfg cellCfg; /* Cell Configuration*/
SsbCfg ssbCfg; /* SSB configuration */
- CsiRsCfg csiRsCfg; /*Reference: 38.331 CSI-MeasConfig*/
+ CsiRsCfg csiRsCfg; /*Reference: 38.331 CSI-RS-ResourceMapping */
PrachCfg prachCfg; /* PRACH Configuration */
#ifdef NR_TDD
TDDCfg tddCfg; /* TDD periodicity and slot configuration */
{
DU_LOG("\nINFO --> DU APP : 5G-NR Cell %d is UP", cellId->cellId);
cellCb->cellStatus = ACTIVATED;
- gCellStatus = CELL_UP;
+ gConfigInfo.gCellStatus = CELL_UP;
if(duCfgParam.tempSliceCfg.numOfRrmPolicy)
BuildAndSendSliceConfigReq();
}
memset(duCb.actvCellLst[cellIdx], 0, sizeof(DuCellCb));
- gCellStatus = CELL_DOWN;
+ gConfigInfo.gCellStatus = CELL_DOWN;
#ifdef O1_ENABLE
DU_LOG("\nINFO --> DU APP : Raise cell down alarm for cell id=%d", deleteRsp->cellId);
* ****************************************************************/
uint8_t parseCsiRsCfg(xmlDocPtr doc, xmlNsPtr ns, xmlNodePtr cur, CsiRsCfg *csiRsCfg)
{
+ uint8_t csiFreqDomainAlloc=0;
memset(csiRsCfg, 0, sizeof(CsiRsCfg));
cur = cur -> xmlChildrenNode;
while(cur != NULL)
{
if ((!xmlStrcmp(cur->name, (const xmlChar *)"CSIRS_FREQ")) && (cur->ns == ns))
{
- csiRsCfg->csiFreqDomainAlloc = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ csiFreqDomainAlloc = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ DU_ALLOC(csiRsCfg->csiFreqDomainAlloc, sizeof(uint8_t));
+ if(!csiRsCfg->csiFreqDomainAlloc)
+ {
+ DU_LOG("\nERROR --> DU APP : %s: Memory allocation failed at line %d", __func__, __LINE__);
+ return RFAILED;
+ }
+ memcpy(csiRsCfg->csiFreqDomainAlloc, &csiFreqDomainAlloc, sizeof(uint8_t));
}
if ((!xmlStrcmp(cur->name, (const xmlChar *)"CSIRS_PORTS")) && (cur->ns == ns))
return ROK;
}
+/*******************************************************************
+ *
+ * @brief Fill Global config Parameters
+ *
+ * @details
+ *
+ * Function : parseGlobalConfigParams
+ *
+ * Functionality: Fill Global config Parmeters
+ *
+ * @params[in] XML document pointer
+ * XML namespace
+ * Current node in XML
+ * Pointer to structure to be filled
+ * @return ROK - success
+ * RFAILED - failure
+ *
+ * ****************************************************************/
+uint8_t parseGlobalConfigParams(xmlDocPtr doc, xmlNsPtr ns, xmlNodePtr cur)
+{
+
+ memset(&gConfigInfo, 0, sizeof(GConfiguration));
+ cur = cur->xmlChildrenNode;
+ while (cur != NULL)
+ {
+
+ if ((!xmlStrcmp(cur->name, (const xmlChar *)"RADIO_FRAME_DURATION")) && (cur->ns == ns))
+ {
+ gConfigInfo.gRadioFrameDuration = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ }
+
+ if ((!xmlStrcmp(cur->name, (const xmlChar *)"ODU_UE_THROUGHPUT_PRINT_TIME_INTERVAL")) && (cur->ns == ns))
+ {
+ gConfigInfo.gUeThrptTimeIntervl = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ }
+
+ if ((!xmlStrcmp(cur->name, (const xmlChar *)"ODU_SNSSAI_THROUGHPUT_PRINT_TIME_INTERVAL")) && (cur->ns == ns))
+ {
+ gConfigInfo.gSnssaiThrptTimeIntervl = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ }
+
+ if ((!xmlStrcmp(cur->name, (const xmlChar *)"PHY_DELTA_DL")) && (cur->ns == ns))
+ {
+ gConfigInfo.gPhyDeltaDl = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ }
+
+ if ((!xmlStrcmp(cur->name, (const xmlChar *)"PHY_DELTA_UL")) && (cur->ns == ns))
+ {
+ gConfigInfo.gPhyDeltaUl = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
+ }
+ cur = cur -> next;
+ }
+ return ROK;
+}
+
/*******************************************************************
*
* @brief Fill DU Config Parmeters
duCfgParam.maxNumDrb = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
}
- if ((!xmlStrcmp(cur->name, (const xmlChar *)"MAX_NUM_UE_SUPPORTED")) && (cur->ns == ns))
- {
- duCfgParam.maxSupportedUes = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
- }
-
- if ((!xmlStrcmp(cur->name, (const xmlChar *)"MAX_NUM_UE")) && (cur->ns == ns))
- {
- duCfgParam.maxUe = atoi((char *)xmlNodeListGetString(doc, cur->xmlChildrenNode, 1));
- }
-
#ifdef O1_ENABLE
if( getStartupConfig(&g_cfg) != ROK )
{
duCfgParam.egtpParams.localIp.ipV4Pres = true;
duCfgParam.egtpParams.destIp.ipV4Pres = true;
duCfgParam.egtpParams.destIp.ipV4Addr = cuIp;
- duCfgParam.egtpParams.maxTunnelId = duCfgParam.maxNumDrb * duCfgParam.maxSupportedUes;
+ duCfgParam.egtpParams.maxTunnelId = duCfgParam.maxNumDrb * MAX_NUM_UE;
}
if ((!xmlStrcmp(cur->name, (const xmlChar *)"MIB_PARAMS")) && (cur->ns == ns))
cmInitTimers(&(duCb.e2apDb.e2TimersInfo.e2Timers.e2NodeConfigUpdate.timer), 1);
}
}
+
+ if((!xmlStrcmp(cur->name, (const xmlChar *)"GLOBAL_CFG")) && (cur->ns == ns))
+ {
+ if(parseGlobalConfigParams(doc, ns, cur) != ROK)
+ {
+ return RFAILED;
+ }
+ }
+
cur = cur -> next;
}
return ROK;
DU_LOG("Lower MAC CORE ID %d\n", duCfgParam.threadInfo.lwrMacCoreId);
DU_LOG("MAX NUM DRB %d\n", duCfgParam.maxNumDrb);
- DU_LOG("MAX SUPPORTED UE %d\n", duCfgParam.maxSupportedUes);
- DU_LOG("MAX UE %d\n",duCfgParam.maxUe);
sctp = &duCfgParam.sctpParams;
DU_LOG("\n ** SCTP PARAMETER ** \n");
uint32_t duId;
char *duName;
uint16_t maxNumDrb;
- uint16_t maxSupportedUes;
- uint32_t maxUe;
ThreadInfo threadInfo;
SctpParams sctpParams; /* SCTP Params */
F1EgtpParams egtpParams; /* EGTP Params */
memset (&egtpCb, 0, sizeof(EgtpGlobalCb));
protType = CM_INET_PROTO_UDP;
- gDlDataRcvdCnt = 0;
+ gConfigInfo.gDlDataRcvdCnt = 0;
return ROK;
}
ret = cmInetRecvMsg(&egtpCb.sockFd, &egtpCb.dstCb.dstAddr, &memInfo, &recvBuf, (int16_t *)&bufLen, CM_INET_NO_FLAG);
if(ret == ROK && recvBuf != NULLP)
{
- DU_LOG("\nDEBUG --> EGTP : Received DL Message[%ld]\n", gDlDataRcvdCnt + 1);
+ DU_LOG("\nDEBUG --> EGTP : Received DL Message[%ld]\n", gConfigInfo.gDlDataRcvdCnt + 1);
//ODU_PRINT_MSG(recvBuf, 0 ,0);
egtpHdlRecvData(recvBuf);
- gDlDataRcvdCnt++;
+ gConfigInfo.gDlDataRcvdCnt++;
}
}
genCfg = &(rlcMngmt.t.cfg.s.gen);
/*----------- Fill General Configuration Parameters ---------*/
- genCfg->maxUe = duCfgParam.maxUe;
+ genCfg->maxUe = MAX_NUM_UE;
genCfg->maxKwuSaps = 2;
genCfg->maxUdxSaps = 1;
genCfg->rlcMode = (inst == RLC_UL_INST) ?
cell->cellInfo.plmn[idx1].mnc[1] = duCfgParam.srvdCellLst[0].duCellInfo.cellInfo.srvdPlmn[0].plmn.mnc[1];
cell->cellInfo.plmn[idx1].mnc[2] = duCfgParam.srvdCellLst[0].duCellInfo.cellInfo.srvdPlmn[0].plmn.mnc[2];
}
- cell->cellInfo.maxUe = duCfgParam.maxUe;
+ cell->cellInfo.maxUe = MAX_NUM_UE;
cell->cellStatus = CELL_OUT_OF_SERVICE;
- gCellStatus = CELL_DOWN;
+ gConfigInfo.gCellStatus = CELL_DOWN;
duCb.cfgCellLst[duCb.numCfgCells] = cell;
duCb.numCfgCells++;
}