X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2Fcu_stub%2Fcu_stub_egtp.c;fp=src%2Fcu_stub%2Fcu_stub_egtp.c;h=c53bc6d925212d6880db75a4a200292b64c6c402;hb=e0ab592152182a8a00aa8e7968209d2c4152e1e9;hp=0def93c04924492c5cd3756c61cc7f531d5e6735;hpb=d9f7fc765d1fc24949ec5536c2a4e3296b250e5a;p=o-du%2Fl2.git diff --git a/src/cu_stub/cu_stub_egtp.c b/src/cu_stub/cu_stub_egtp.c index 0def93c04..c53bc6d92 100644 --- a/src/cu_stub/cu_stub_egtp.c +++ b/src/cu_stub/cu_stub_egtp.c @@ -686,9 +686,9 @@ S16 cuEgtpDecodeHdr(Buffer *mBuf) * RFAILED - failure * * ****************************************************************/ -uint16_t cuEgtpDatReq(uint8_t teId) +uint16_t cuEgtpDatReq(uint32_t duId, uint8_t teId) { - uint8_t ret = ROK, cnt = 0, duId =0; + uint8_t ret = ROK, cnt = 0; EgtpMsg egtpMsg; egtpMsg.msgHdr.teId = teId; @@ -698,26 +698,23 @@ uint16_t cuEgtpDatReq(uint8_t teId) DU_LOG("\nERROR --> EGTP : DRB not created"); return RFAILED ; } - for(duId = 1; duId<=egtpCb.numDu; duId++) + /* Build Application message that is supposed to come from app to egtp */ + ret = BuildAppMsg(duId, &egtpMsg); + if(ret != ROK) { - /* Build Application message that is supposed to come from app to egtp */ - ret = BuildAppMsg(duId, &egtpMsg); - if(ret != ROK) - { - DU_LOG("\nERROR --> EGTP : Failed to build App Msg"); - return RFAILED; - } + DU_LOG("\nERROR --> EGTP : Failed to build App Msg"); + return RFAILED; + } - /* Encode EGTP header to build final EGTP message */ - ret = BuildEgtpMsg(duId, &egtpMsg); - if(ret != ROK) - { - DU_LOG("\nERROR --> EGTP : Failed to build EGTP Msg"); - return RFAILED; - } - cuEgtpSendMsg(duId, egtpMsg.msg); - ODU_PUT_MSG_BUF(egtpMsg.msg); + /* Encode EGTP header to build final EGTP message */ + ret = BuildEgtpMsg(duId, &egtpMsg); + if(ret != ROK) + { + DU_LOG("\nERROR --> EGTP : Failed to build EGTP Msg"); + return RFAILED; } + cuEgtpSendMsg(duId, egtpMsg.msg); + ODU_PUT_MSG_BUF(egtpMsg.msg); return ROK; }