*******************************************************************************/
/* This file contains all EGTP related functionality */
-
-#include <stdio.h>
+#include "common_def.h"
+#include "lrg.h"
+#include "lkw.x"
+#include "lrg.x"
+#include "legtp.h"
+#include "du_app_mac_inf.h"
+#include "du_cfg.h"
#include "du_egtp.h"
#include "du_ue_mgr.h"
+#include "du_utils.h"
/* Global variable declaration */
EgtpGlobalCb egtpCb;
rspPst->dstEnt = pst->srcEnt;
rspPst->dstInst = pst->srcInst;
rspPst->dstProcId = pst->srcProcId;
- rspPst->selector = DU_SELECTOR_LC;
+ rspPst->selector = ODU_SELECTOR_LC;
rspPst->pool= DU_POOL;
return ROK;
DU_LOG("\nEGTP : Tunnel addition : LocalTeid[%d] Remote Teid[%d]", tnlEvt.lclTeid, tnlEvt.remTeid);
- ret = SGetSBuf(DU_APP_MEM_REGION, DU_POOL, (Data **)&teidCb, (Size)sizeof(EgtpTeIdCb));
- if(ret != ROK)
+ DU_ALLOC(teidCb, sizeof(EgtpTeIdCb));
+ if(teidCb == NULLP)
{
DU_LOG("\nEGTP : Memory allocation failed");
return LCM_REASON_MEM_NOAVAIL;
if(ret != ROK)
{
DU_LOG("\nEGTP : Failed to insert in hash list");
- SPutSBuf(DU_APP_MEM_REGION, DU_POOL, (Data *)teidCb, (Size)sizeof(EgtpTeIdCb));
+ DU_FREE(teidCb, sizeof(EgtpTeIdCb));
return LCM_REASON_HASHING_FAILED;
}
egtpCb.dstCb.numTunn++;
}
cmHashListDelete(&(egtpCb.dstCb.teIdLst), (PTR)teidCb);
- SPutSBuf(DU_APP_MEM_REGION, DU_POOL, (Data *)teidCb, (Size)sizeof(EgtpTeIdCb));
+ DU_FREE(teidCb, sizeof(EgtpTeIdCb));
egtpCb.dstCb.numTunn--;
return ROK;