X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=src%2Fcu_stub%2Fcu_stub_egtp.c;h=ff8f2d58637204abf40824b1db111038b6253e7d;hb=088bb8763eaf91c139ede025faf2fac7e57d25ed;hp=b8616c067a24a1fb3d80f5960a244cb08f180d44;hpb=4d45b914f9e94203603d3b9fdbcb1aad361301dd;p=o-du%2Fl2.git diff --git a/src/cu_stub/cu_stub_egtp.c b/src/cu_stub/cu_stub_egtp.c index b8616c067..ff8f2d586 100644 --- a/src/cu_stub/cu_stub_egtp.c +++ b/src/cu_stub/cu_stub_egtp.c @@ -73,9 +73,9 @@ S16 egtpActvInit() * RFAILED - failure * ***************************************************************************/ -S16 egtpInitReq() +uint8_t egtpInitReq() { - S16 ret = ROK; + uint8_t ret = ROK; EgtpTnlEvt tnlEvt; ret = cuEgtpCfgReq(); @@ -102,8 +102,7 @@ S16 egtpInitReq() return RFAILED; } - return (ret); - + return ret; } /* egtpInitReq */ /************************************************************************** @@ -175,7 +174,7 @@ S16 cuEgtpSrvOpenReq(Pst *pst) DU_LOG("\nEGTP : Received open server request"); sockType = CM_INET_DGRAM; - if(ret = (cmInetSocket(sockType, &(egtpCb.recvTptSrvr.sockFd), protType)) != ROK) + if((ret = (cmInetSocket(sockType, &(egtpCb.recvTptSrvr.sockFd), protType))) != ROK) { DU_LOG("\nEGTP : Failed to open UDP socket"); return RFAILED; @@ -513,7 +512,6 @@ S16 cuEgtpHdlRecvMsg(Buffer *mBuf) S16 cuEgtpDecodeHdr(Buffer *mBuf) { EgtpMsg egtpMsg; - S16 retVal = ROK; /* Holds the return value */ U8 tmpByte[5]; /* Holds one byte of data after Dec */ U8 version = 0; /* Holds the version type, decoded */ MsgLen msgLen = 0; /* Holds the msgLen from the Hdr */ @@ -645,7 +643,7 @@ S16 cuEgtpDatReq() cnt++; } - ODU_PUT_MSG(egtpMsg.msg); + ODU_PUT_MSG_BUF(egtpMsg.msg); return ROK; } @@ -658,12 +656,12 @@ S16 BuildAppMsg(EgtpMsg *egtpMsg) Buffer *mBuf; - if(ODU_GET_MSG(CU_APP_MEM_REG, CU_POOL, &mBuf) == ROK) + if(ODU_GET_MSG_BUF(CU_APP_MEM_REG, CU_POOL, &mBuf) == ROK) { if(ODU_ADD_POST_MSG_MULT((Data *)data, datSize, mBuf) != ROK) { DU_LOG("\nEGTP : ODU_ADD_POST_MSG_MULT failed"); - ODU_PUT_MSG(mBuf); + ODU_PUT_MSG_BUF(mBuf); return RFAILED; } } @@ -750,7 +748,7 @@ S16 BuildAppMsg(EgtpMsg *egtpMsg) egtpMsg->msgHdr.teId = 10; egtpMsg->msg = mBuf; - return ROK; + return ret; }