X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2Fdu_app%2Fdu_f1ap_msg_hdl.c;h=c355732073edf3a742a7ced2a1a073fa39d24057;hb=52ca0cf30806914e2f44054932cd2300f12aded8;hp=170bb65b838cd3dcb7a7f3fb2829fa97fcbcc941;hpb=4588074b60b6cd2d5a2c27fb1f0a8114e30b1810;p=o-du%2Fl2.git diff --git a/src/du_app/du_f1ap_msg_hdl.c b/src/du_app/du_f1ap_msg_hdl.c index 170bb65b8..c35573207 100644 --- a/src/du_app/du_f1ap_msg_hdl.c +++ b/src/du_app/du_f1ap_msg_hdl.c @@ -1214,7 +1214,7 @@ void freeFddNrFreqInfo(FDD_Info_t *fDD) * ****************************************************************/ void FreeServedCellList( GNB_DU_Served_Cells_List_t *duServedCell) { - uint8_t plmnCnt=MAX_PLMN; + uint8_t plmnCnt= 1; uint8_t extensionCnt=IE_EXTENSION_LIST_COUNT; uint8_t plmnIdx=0, sliceIdx=0; GNB_DU_Served_Cells_Item_t *srvCellItem; @@ -2606,7 +2606,7 @@ uint8_t BuildAndSendULRRCMessageTransfer(DuUeCb *ueCb, uint8_t lcId, \ while(true) { - DU_LOG("\n INFO --> F1AP : Building UL RRC Message Transfer Message\n"); + DU_LOG("\nINFO --> F1AP : Building UL RRC Message Transfer Message\n"); DU_ALLOC(f1apMsg, sizeof(F1AP_PDU_t)); if(f1apMsg == NULLP) @@ -2707,7 +2707,7 @@ uint8_t BuildAndSendULRRCMessageTransfer(DuUeCb *ueCb, uint8_t lcId, \ } else { - DU_LOG("\nDEBUG --> F1AP : Created APER encoded buffer for ULRRCMessageTransfer\n"); + DU_LOG("\nDEBUG --> F1AP : Created APER encoded buffer for ULRRCMessageTransfer\n"); #ifdef DEBUG_ASN_PRINT for(int i=0; i< encBufSize; i++) { @@ -4083,14 +4083,16 @@ elementCnt = pdschCfg->numTimeDomRsrcAlloc; for(idx = 0; idx < elementCnt; idx++) { timeDomAlloc = timeDomAllocList->choice.setup->list.array[idx]; - DU_ALLOC(timeDomAlloc->k0, sizeof(long)); - if(!timeDomAlloc->k0) - { - DU_LOG("\nERROR --> F1AP : Memory allocation failed in BuildPdschTimeDomAllocList"); - return RFAILED; - } if(pdschCfg->timeDomRsrcAllociList[idx].k0) + { + DU_ALLOC(timeDomAlloc->k0, sizeof(long)); + if(!timeDomAlloc->k0) + { + DU_LOG("\nERROR --> F1AP : Memory allocation failed in BuildPdschTimeDomAllocList"); + return RFAILED; + } *(timeDomAlloc->k0) = *(pdschCfg->timeDomRsrcAllociList[idx].k0); + } timeDomAlloc->mappingType = pdschCfg->timeDomRsrcAllociList[idx].mappingType; timeDomAlloc->startSymbolAndLength = pdschCfg->timeDomRsrcAllociList[idx].startSymbolAndLength; } @@ -6715,7 +6717,7 @@ uint8_t BuildSpCellConfigCommon(ServingCellConfigCommon_t *spCellConfigCommon) convertSsbPeriodicityValueToEnum(duCfgParam.sib1Params.srvCellCfgCommSib.ssbPrdServingCell); /* DMRS Type A position */ - spCellConfigCommon->dmrs_TypeA_Position = convertDmrsTypeAPosValueToEnum(duCfgParam.macCellCfg.dmrsTypeAPos); + spCellConfigCommon->dmrs_TypeA_Position = convertDmrsTypeAPosValueToEnum(duCfgParam.macCellCfg.ssbCfg.dmrsTypeAPos); /* SSB subcarrier spacing */ DU_ALLOC(spCellConfigCommon->ssbSubcarrierSpacing, sizeof(SubcarrierSpacing_t)); @@ -13079,7 +13081,7 @@ uint8_t extractSrbListToSetup(SRBs_ToBeSetup_List_t *srbCfg, DuUeCfg *ueCfgDb) * * @params[in] DRBs_ToBeSetup_Item_t , DRBs_ToBeSetupMod_Item_t, * DRBs_ToBeModified_Item_t , lcId, DuLcCfg pointer, - * RlcBearerCfg , UpTnlCfg, RlcUeCfg + * RlcBearerCfg , UpTnlCfg, DuRlcUeCfg * @return void * * ****************************************************************/ @@ -15634,35 +15636,35 @@ uint8_t procF1DlRrcMsgTrans(F1AP_PDU_t *f1apMsg) { if(f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.size > 0) { - dlMsg.rrcMsgSize = f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.size; - DU_ALLOC_SHRABL_BUF(dlMsg.rrcMsgPdu, dlMsg.rrcMsgSize); - if(dlMsg.rrcMsgPdu) - { - memcpy(dlMsg.rrcMsgPdu, f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.buf,\ - dlMsg.rrcMsgSize); - } - else - { - DU_LOG("\nERROR --> DU APP : Memory alloc Failed at RRC Container at procF1DlRrcMsgTrans()"); - return RFAILED; - } - } - else - { - DU_LOG("\nERROR --> DU_APP : RRC Container Size is invalid:%ld",\ - f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.size); - return RFAILED; - } - break; - } - case ProtocolIE_ID_id_RRCDeliveryStatusRequest: - { - dlMsg.deliveryStatRpt = true; - break; - } - default: - DU_LOG("\nERROR --> DU_APP : Invalid IE received in DL RRC Msg Transfer:%ld", - f1DlRrcMsg->protocolIEs.list.array[idx]->id); + dlMsg.rrcMsgSize = f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.size; + DU_ALLOC_SHRABL_BUF(dlMsg.rrcMsgPdu, dlMsg.rrcMsgSize); + if(dlMsg.rrcMsgPdu) + { + memcpy(dlMsg.rrcMsgPdu, f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.buf,\ + dlMsg.rrcMsgSize); + } + else + { + DU_LOG("\nERROR --> DU APP : Memory alloc Failed at RRC Container at procF1DlRrcMsgTrans()"); + return RFAILED; + } + } + else + { + DU_LOG("\nERROR --> DU_APP : RRC Container Size is invalid:%ld",\ + f1DlRrcMsg->protocolIEs.list.array[idx]->value.choice.RRCContainer.size); + return RFAILED; + } + break; + } + case ProtocolIE_ID_id_RRCDeliveryStatusRequest: + { + dlMsg.deliveryStatRpt = true; + break; + } + default: + DU_LOG("\nERROR --> DU_APP : Invalid IE received in DL RRC Msg Transfer:%ld", + f1DlRrcMsg->protocolIEs.list.array[idx]->id); } }