X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrmac%2Frg_lim.c;h=6c7582e470d49f5e32ed60d47c1a7df392766cfd;hb=069ae37558afd5aee2d1072bbf5b517cf665bdd8;hp=424180b4101abea06d1e33b9d9609689b4837c1c;hpb=8b3c1a54b33c87e09512690649ed24775f7a5508;p=o-du%2Fl2.git diff --git a/src/5gnrmac/rg_lim.c b/src/5gnrmac/rg_lim.c index 424180b41..6c7582e47 100755 --- a/src/5gnrmac/rg_lim.c +++ b/src/5gnrmac/rg_lim.c @@ -700,10 +700,11 @@ int sendSlotIndMacToSch(SlotIndInfo *slotInd) int sendSlotIndMacToDuApp(SlotIndInfo *slotInd) { Pst pst; + uint16_t ret; SlotInfo *slotInfo; - - /* Send Slot Indication to DU APP */ - MAC_ALLOC(slotInfo, sizeof(SlotInfo)); + + /* Allocate sharable memory */ + MAC_ALLOC_SHRABL_BUF(slotInfo, sizeof(SlotInfo)); if(!slotInfo) { DU_LOG("\nMAC : Slot Indication memory allocation failed"); @@ -729,8 +730,14 @@ int sendSlotIndMacToDuApp(SlotIndInfo *slotInd) pst.prior = 0; pst.intfVer = 0; - return MacDuAppSlotInd(&pst, slotInfo); - + ret = MacDuAppSlotInd(&pst, slotInfo); + if(ret != ROK) + { + DU_LOG("\nMAC: Failed to send slot indication to DU APP"); + MAC_FREE_SHRABL_BUF(MAC_MEM_REGION, MAC_POOL, slotInfo, sizeof(SlotInfo)); + } + + return ret; } /**