+/*******************************************************************
+ *
+ * @brief Build and Send Ue context setup request
+ *
+ * @details
+ *
+
+ * Function : duBuildAndSendUeContextSetupReq
+ *
+ * Functionality:
+ * Build and Send Ue context setup request
+ *
+ * @params[in] cellId, crnti, DuUeCfg pointer
+ * @return ROK - success
+ * RFAILED - failure
+ *
+ *****************************************************************/
+
+uint8_t duBuildAndSendUeContextSetupReq(uint16_t cellId, uint16_t crnti, DuUeCfg *duUeCfg)
+{
+ uint8_t ret = ROK;
+
+ DU_LOG("\nDEBUG --> DU_APP: Processing Ue Context Setup Request for cellId [%d]", cellId);
+ /* Filling RLC Ue Reconfig */
+ ret = duBuildAndSendUeReCfgReqToRlc(cellId, crnti, duUeCfg);
+ if(ret == RFAILED)
+ DU_LOG("\nERROR --> DU APP : Failed to build ctxt setup req for RLC at duBuildAndSendUeContextSetupReq()");
+
+ /* Filling MAC Ue Reconfig */
+ ret = duBuildAndSendUeReCfgReqToMac(cellId, crnti, duUeCfg);
+ if(ret == RFAILED)
+ DU_LOG("\nERROR --> DU APP : Failed at build ctxt setup req for MAC at duBuildAndSendUeContextSetupReq()");
+
+ return ret;
+}
+
+/*******************************************************************
+ *
+ * @brief Processes DL Rsp received from RLC DL
+ *
+ * @details
+ *
+
+ * Function : DuProcRlcDlRrcMsgRsp
+ *
+ * Functionality:
+ * Processes UE Rsp received from RLC DL
+ *
+ * @params[in] Post structure
+ * Pointer to RlcCfgCfm
+ * @return ROK - success
+ * RFAILED - failure
+ *
+ *****************************************************************/
+uint8_t DuProcRlcDlRrcMsgRsp(Pst *pst, RlcDlRrcMsgRsp *dlRrcMsg)
+{
+ uint8_t ret = ROK, ueIdx = 0;
+ DuUeCb *ueCb = NULLP;
+
+ if(dlRrcMsg->state == TRANSMISSION_COMPLETE)
+ {
+ GET_UE_IDX(dlRrcMsg->crnti, ueIdx);
+ ueCb = &duCb.actvCellLst[dlRrcMsg->cellId -1]->ueCb[ueIdx -1];
+ if(ueCb->f1UeDb)
+ {
+ ret = duBuildAndSendUeContextSetupReq(dlRrcMsg->cellId, dlRrcMsg->crnti, &ueCb->f1UeDb->duUeCfg);
+ if(ret == RFAILED)
+ DU_LOG("\nERROR --> DU APP : Failed to process UE Context Setup Request in DuProcRlcDlRrcMsgRsp()");
+ }
+ }
+ else
+ DU_LOG("\nERROR --> DU APP : Failed to transmit DL RRC Msg");
+
+ DU_FREE_SHRABL_BUF(DU_APP_MEM_REGION, DU_POOL, dlRrcMsg, sizeof(RlcDlRrcMsgRsp));
+ return ret;
+}