#include "E2AP-PDU.h"
#include<ProtocolIE-Field.h>
#include "F1AP-PDU.h"
-#include "du_f1ap_msg_hdl.h"
#include "du_e2ap_msg_hdl.h"
#include "du_app_mac_inf.h"
#include "du_app_rlc_inf.h"
#include "du_mgr.h"
#include "odu_common_codec.h"
#include "du_cell_mgr.h"
+#include "du_f1ap_msg_hdl.h"
extern DuCfgParams duCfgParam;
-extern S16 duBuildAndSendMacCellCfg();
+uint8_t duBuildAndSendMacCellCfg(uint16_t cellId);
/*******************************************************************
*
* RFAILED - failure
*
* ****************************************************************/
-S16 procCellsToBeActivated(Cells_to_be_Activated_List_t cellsToActivate)
+uint8_t procCellsToBeActivated(Cells_to_be_Activated_List_t cellsToActivate)
{
- U16 idx = 0;
- S16 ret = ROK;
+ uint16_t idx = 0;
+ uint8_t ret = ROK;
for(idx=0; idx<cellsToActivate.list.count; idx++)
{
- U16 nci = 0;
- U16 pci = 0;
+ uint16_t nci = 0;
+ uint16_t pci = 0;
DuCellCb *cellCb = NULLP;
Cells_to_be_Activated_List_Item_t cell = cellsToActivate.list.array[idx]->\
duCb.actvCellLst[nci-1] = cellCb;
duCb.numActvCells++;
/* Build and send Mac Cell Cfg for the number of active cells */
- ret = duBuildAndSendMacCellCfg();
+ ret = duBuildAndSendMacCellCfg(cellCb->cellId);
if(ret != ROK)
{
DU_LOG("\nDU APP : macCellCfg build and send failed");
+ /* Move cellCb back to cfgCellList */
+ duCb.cfgCellLst[nci-1] = duCb.actvCellLst[nci-1];
+ duCb.actvCellLst[nci-1] = NULLP;
+ duCb.numActvCells--;
return RFAILED;
}
}
* Functionality: Processes F1 Setup Response sent by CU
*
* @params[in] F1AP_PDU_t ASN decoded F1AP message
-* @return ROK - success
+* @return ROK - success
* RFAILED - failure
*
* ****************************************************************/
F1SetupRsp f1SetRspDb;
GNB_CU_Name_t *cuName;
RRC_Version_t *rrc_Ver;
- U16 idx;
+ uint16_t idx;
DU_LOG("\nDU_APP : F1 Setup Response received");
printf("\nDU_APP : F1 Setup Response received");
/* TODO :Check the deallocation */
#if 0
- SPutSBuf(DU_APP_MEM_REGION, DU_POOL,(Data *)&(f1SetupRsp->protocolIEs.list.array),\
- (Size)elementCnt * sizeof(F1SetupResponseIEs_t *));
- SPutSBuf(DU_APP_MEM_REGION, DU_POOL,(Data *)&(f1apMsg->choice.successfulOutcome),\
- (Size)sizeof(SuccessfulOutcome_t));
- SPutSBuf(DU_APP_MEM_REGION, DU_POOL,(Data *)&f1apMsg,(Size)sizeof(F1AP_PDU_t));
+ DU_FREE(f1SetupRsp->protocolIEs.list.array,(Size)elementCnt * sizeof(F1SetupResponseIEs_t *));
+ DU_FREE(f1apMsg->choice.successfulOutcome,(Size)sizeof(SuccessfulOutcome_t));
+ DU_FREE(f1apMsg,(Size)sizeof(F1AP_PDU_t));
#endif
return ret;
}
-/*******************************************************************
- *
- * @brief Processes GNB DU config update ack
- *
- * @details
- *
- * Function : procGNBDUCfgUpdAck
- *
- * Functionality: Processes GNB DU config update ack
- *
- * @params[in] F1AP_PDU_t ASN decoded F1AP message
- * @return ROK - success
- * RFAILED - failure
- *
- * ****************************************************************/
-S16 procGNBDUCfgUpdAck(F1AP_PDU_t *f1apMsg)
-{
- DU_LOG("\nF1AP : GNB-DU config update acknowledgment received");
-/* TODO :Check the deallocation */
-#if 0
- SPutSBuf(DU_APP_MEM_REGION,DU_POOL,(Data*)&(gNBDuCfgAck->protocolIEs.list.array),\
- (Size)elementCnt * sizeof(GNBDUConfigurationUpdateAcknowledgeIEs_t
-));
- SPutSBuf(DU_APP_MEM_REGION,DU_POOL,(Data*)&(f1apMsg->choice.successfulOutcome),\
- (Size)sizeof(SuccessfulOutcome_t));
- SPutSBuf(DU_APP_MEM_REGION,DU_POOL,(Data*)&f1apMsg,(Size)sizeof(F1AP_PDU_t));
-#endif
- return ROK;
-}
-
-
/**********************************************************************
End of file
**********************************************************************/