replaced cmMemSet, cmMemcpy with memset and memcpy resp AND Removed TRC() traces...
[o-du/l2.git] / src / 5gnrsch / rg_sch.c
index d1f9fa7..b002d90 100755 (executable)
@@ -101,13 +101,13 @@ RgrWarningSiCfgReqInfo *warningSiCfgReqInfo
  *      -# ROK
  **/
 #ifdef ANSI
-PUBLIC S16 RgMiLrgSchCntrlReq
+S16 RgMiLrgSchCntrlReq
 (
 Pst      *pst,    /* post structure  */
 RgMngmt  *cntrl   /* control structure  */
 )
 #else
-PUBLIC S16 RgMiLrgSchCntrlReq(pst, cntrl)
+S16 RgMiLrgSchCntrlReq(pst, cntrl)
 Pst      *pst;    /* post structure  */
 RgMngmt  *cntrl;  /* control structure  */
 #endif    
@@ -117,8 +117,6 @@ RgMngmt  *cntrl;  /* control structure  */
    RgMngmt   cfm;
    
    Inst      inst = (pst->dstInst - SCH_INST_START); /* Scheduler instance Id */
-   TRC3(RgMiLrgSchCntrlReq)
-   
 
    /* Fill the post structure for sending the confirmation */
    SchFillCfmPst(pst, &cfmPst, cntrl);
@@ -129,9 +127,9 @@ RgMngmt  *cntrl;  /* control structure  */
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst, "Memory Unavailable for Confirmation");
       SPutSBuf(pst->region, pst->pool, (Data *)cntrl, sizeof(RgMngmt));
-      RETVALUE(ROK);
+      return ROK;
    } */
-   cmMemset((U8 *)&cfm, 0, sizeof(RgMngmt));
+   memset(&cfm, 0, sizeof(RgMngmt));
 
 #ifdef LMINT3
    cfm.hdr.transId =
@@ -151,7 +149,7 @@ RgMngmt  *cntrl;  /* control structure  */
       RgMiLrgSchCntrlCfm(&cfmPst, &cfm);
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst, "Gen Cfg not done.");
       /*      SPutSBuf(pst->region, pst->pool, (Data *)cntrl, sizeof(RgMngmt)); */
-      RETVALUE(ROK);
+      return ROK;
    }
 
    /* General Config done, process the Control request */   
@@ -173,7 +171,7 @@ RgMngmt  *cntrl;  /* control structure  */
          break;
    }
    /*   SPutSBuf(pst->region, pst->pool, (Data *)cntrl, sizeof(RgMngmt)); */
-   RETVALUE(ret);
+   return (ret);
 }/*-- RgMiLrgSchCntrlReq --*/
 
 #ifdef LTE_L2_MEAS
@@ -193,13 +191,13 @@ RgMngmt  *cntrl;  /* control structure  */
  *      -# ROK
  **/
 #ifdef ANSI
-PUBLIC S16 RgMiLrgSchL2MeasReq
+S16 RgMiLrgSchL2MeasReq
 (
 Pst               *pst,     /* post structure  */
 LrgSchMeasReqInfo *measInfo /* Meas Req Info */
 )
 #else
-PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
+S16 RgMiLrgSchL2MeasReq(pst, measInfo)
    Pst               *pst;     /* post structure  */
    LrgSchMeasReqInfo *measInfo; /* Meas Req Info */
 #endif    
@@ -221,8 +219,6 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
    err.errType  = 0;
    err.errCause = 0;
 
-   TRC3(RgMiLrgSchL2MeasReq)
-
 
    /* Find the cellCb using cellId in measInfo. Iterate through all cells
     * in rgrsapCb in RgschCb */
@@ -245,7 +241,7 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
       RLOG_ARG2(L_ERROR,DBG_INSTID,inst, 
                "Meas req Failed.Invalid Cell Id errType(%d) errCause(%d)",
                err.errType, err.errCause);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    /* Validate for Meas Types */
    if ( (ret = rgSCHUtlValidateMeasReq(cell, measInfo, &err)) != ROK)
@@ -256,7 +252,7 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
       RLOG_ARG2(L_ERROR,DBG_CELLID,cell->cellId,
                "Meas req Failed.Invalid Measurement Type"
                "errCasue(%d) errType(%d)", err.errType, err.errCause);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    /* Iterate through all meas requests in l2mList in cellCb */
 #if (ERRCLASS & ERRCLS_ADD_RES) 
@@ -274,7 +270,7 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
          RLOG_ARG2(L_ERROR,DBG_CELLID,cell->cellId,
                   "Meas req Failed.Dublicate TransId"
                   "errType(%d) errCause(%d)", err.errType, err.errCause);
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
    }
 #endif
@@ -288,9 +284,9 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
       RLOG_ARG2(L_ERROR,DBG_CELLID,cell->cellId, 
                "Meas req Failed.errType(%d) errCause(%d)",
                err.errType, err.errCause);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
-   RETVALUE(ret);
+   return (ret);
 } /* -- RRgMiLrgSchL2MeasReq-- */
 
 /**
@@ -309,13 +305,13 @@ PUBLIC S16 RgMiLrgSchL2MeasReq(pst, measInfo)
  *      -# ROK
  **/
 #ifdef ANSI
-PUBLIC S16 RgMiLrgSchL2MeasStopReq
+S16 RgMiLrgSchL2MeasStopReq
 (
 Pst               *pst,     /* post structure  */
 LrgSchMeasStopReqInfo *measInfo /* Meas Req Info */
 )
 #else
-PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
+S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
    Pst               *pst;     /* post structure  */
    LrgSchMeasStopReqInfo *measInfo; /* Meas Req Info */
 #endif
@@ -328,10 +324,6 @@ PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
    LrgSchMeasCfmInfo measCfm;
    U8                  idx;
 
-
-   TRC3(RgMiLrgSchL2MeasStopReq)
-
-
    for (idx = 0; idx < instCb->numSaps; idx++)
    {
       if ( instCb->rgrSap[idx].cell->cellId == measInfo->cellId)
@@ -345,9 +337,9 @@ PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,measInfo->cellId,
                "Stop req Failed.Invalid Cell Id ");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
-   cmMemset((U8 *)&measCfm, 0, sizeof(LrgSchMeasCfmInfo));
+   memset(&measCfm, 0, sizeof(LrgSchMeasCfmInfo));
    node = cell->l2mList.first;
    while(node != NULLP)
    {
@@ -363,7 +355,7 @@ PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
    {
       RgInfL2MeasStopReq measStopReq;
       Pst               pstMac;
-      cmMemset((U8 *)&measStopReq, 0, sizeof(RgInfL2MeasStopReq));
+      memset(&measStopReq, 0, sizeof(RgInfL2MeasStopReq));
       measStopReq.transId  = measInfo->hdr.transId;
       measStopReq.measType = measInfo->measType;
       /* measReq.timePrd  = measInfo->timePrd; */
@@ -376,7 +368,7 @@ PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
       RgMiLrgSchL2MeasStopCfm(&(rgSchCb[cell->instIdx].rgSchInit.lmPst),
             &measCfm);
    }
-   RETVALUE(ret);
+   return (ret);
 }/*RgMiLrgSchL2MeasStopReq*/
 /**
  * @brief Layer Manager L2 Measurement request handler. 
@@ -394,13 +386,13 @@ PUBLIC S16 RgMiLrgSchL2MeasStopReq(pst, measInfo)
  *      -# ROK
  **/
 #ifdef ANSI
-PUBLIC S16 RgMiLrgSchL2MeasSendReq
+S16 RgMiLrgSchL2MeasSendReq
 (
 Pst               *pst,     /* post structure  */
 LrgSchMeasSndReqInfo *measInfo /* Meas Req Info */
 )
 #else
-PUBLIC S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
+S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
    Pst               *pst;     /* post structure  */
    LrgSchMeasSndReqInfo *measInfo; /* Meas Req Info */
 #endif
@@ -410,10 +402,6 @@ PUBLIC S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
    RgSchCb             *instCb =  &rgSchCb[(pst->dstInst - SCH_INST_START)];
    U8                  idx;
 
-   TRC3(RgMiLrgSchL2MeasSendReq)
-
-
-
    cell = NULLP;
    for (idx = 0; idx < instCb->numSaps; idx++)
    {
@@ -428,14 +416,14 @@ PUBLIC S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,measInfo->cellId,
                "Send req Failed.Invalid Cell Id");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if(measInfo->measType & LRG_L2MEAS_AVG_PRB_PER_QCI_UL)
    {
       RgInfL2MeasSndReq measSndReq;
       Pst               pstMac;
-      cmMemset((U8 *)&measSndReq, 0, sizeof(RgInfL2MeasSndReq));
+      memset(&measSndReq, 0, sizeof(RgInfL2MeasSndReq));
       measSndReq.transId  = measInfo->hdr.transId;
       measSndReq.measType = measInfo->measType;
       measSndReq.timePrd  = measInfo->timePrd;
@@ -448,7 +436,7 @@ PUBLIC S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
       cell->sndL2Meas = TRUE;
    }
 
-   RETVALUE(ret);
+   return (ret);
 }/*RgMiLrgSchL2MeasSendReq*/
 #endif /* LTE_L2_MEAS */
 
@@ -476,14 +464,14 @@ PUBLIC S16 RgMiLrgSchL2MeasSendReq(pst, measInfo)
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrBndReq
+S16 RgUiRgrBndReq
 (
  Pst   *pst, 
  SuId  suId,
  SpId  spId
  )
 #else
-PUBLIC S16 RgUiRgrBndReq(pst, suId, spId)
+S16 RgUiRgrBndReq(pst, suId, spId)
    Pst   *pst; 
    SuId  suId;
    SpId  spId;
@@ -494,9 +482,6 @@ PUBLIC S16 RgUiRgrBndReq(pst, suId, spId)
    Inst      instId = pst->dstInst-SCH_INST_START;
    RgUstaDgn dgn;      /* Alarm diagnostics structure */
 
-   TRC3(RgUiRgrBndReq)
-
-
    tmpPst.prior       = pst->prior;
    tmpPst.route       = pst->route;
    tmpPst.selector    = pst->selector;
@@ -552,7 +537,7 @@ PUBLIC S16 RgUiRgrBndReq(pst, suId, spId)
 #endif
       ret = RgUiRgrBndCfm(&tmpPst, suId, CM_BND_NOK);
    }
-   RETVALUE(ret);
+   return (ret);
 }  /* RgUiRgrBndReq */
 
 /**
@@ -575,22 +560,20 @@ PUBLIC S16 RgUiRgrBndReq(pst, suId, spId)
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrUbndReq
+S16 RgUiRgrUbndReq
 (
  Pst    *pst,
  SpId   spId,
  Reason reason
  )
 #else
-PUBLIC S16 RgUiRgrUbndReq(pst, spId, reason)
+S16 RgUiRgrUbndReq(pst, spId, reason)
    Pst    *pst; 
    SpId   spId;
    Reason reason;
 #endif
 {
    Inst instId = pst->dstInst-SCH_INST_START;
-   TRC3(RgUiRgrUbndReq)
-
 
    /* SAP Id validation */
    if (spId < rgSchCb[instId].numSaps)
@@ -608,7 +591,7 @@ PUBLIC S16 RgUiRgrUbndReq(pst, spId, reason)
                   (ErrVal)rgSchCb[instId].rgrSap[spId].sapSta.sapState,
                   "Invalid SAP State: RgUiRgrUbndReq failed\n");
 #endif
-            RETVALUE(RFAILED);
+            return RFAILED;
       }
    }
    else
@@ -618,9 +601,9 @@ PUBLIC S16 RgUiRgrUbndReq(pst, spId, reason)
             (ErrVal)rgSchCb[instId].rgrSap[spId].sapSta.sapState,
             "Invalid SAP Id:RgUiRgrUbndReq failed\n");
 #endif
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* RgUiRgrUbndReq */
 
 #ifdef RGR_SI_SCH
@@ -646,7 +629,7 @@ PUBLIC S16 RgUiRgrUbndReq(pst, spId, reason)
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrSiCfgReq
+S16 RgUiRgrSiCfgReq
 (
 Pst           *pst, 
 SpId          spId,
@@ -654,7 +637,7 @@ RgrCfgTransId transId,
 RgrSiCfgReqInfo *cfgReqInfo
 )
 #else
-PUBLIC S16 RgUiRgrSiCfgReq(pst, spId, transId, cfgReqInfo)
+S16 RgUiRgrSiCfgReq(pst, spId, transId, cfgReqInfo)
 Pst           *pst; 
 SpId          spId;
 RgrCfgTransId transId;
@@ -666,9 +649,7 @@ RgrSiCfgReqInfo *cfgReqInfo;
    U8        prntTrans[RGR_CFG_TRANSID_SIZE+1];
    Inst      instId = pst->dstInst-SCH_INST_START;
 
-   TRC2(RgUiRgrSiCfgReq);
-
-   cmMemcpy((U8 *)prntTrans, (U8 *)transId.trans, RGR_CFG_TRANSID_SIZE);
+   memcpy(prntTrans, transId.trans, RGR_CFG_TRANSID_SIZE);
    prntTrans[RGR_CFG_TRANSID_SIZE] = '\0';
 
 
@@ -677,7 +658,7 @@ RgrSiCfgReqInfo *cfgReqInfo;
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,"Input Message Buffer "
                    "is NULL");
       rgSCHUtlRgrSiCfgCfm(instId, spId, transId, cfmStatus); 
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if (spId < rgSchCb[instId].numSaps)
@@ -692,7 +673,7 @@ RgrSiCfgReqInfo *cfgReqInfo;
          SPutSBuf(pst->region, pst->pool, (Data *)cfgReqInfo,
                                           (Size)sizeof(*cfgReqInfo));
          rgSCHUtlRgrSiCfgCfm(instId, spId, transId, cfmStatus); 
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
    }
    else
@@ -705,7 +686,7 @@ RgrSiCfgReqInfo *cfgReqInfo;
       SPutSBuf(pst->region, pst->pool, (Data *)cfgReqInfo,
                                    (Size)sizeof(*cfgReqInfo));
       rgSCHUtlRgrSiCfgCfm(instId, spId, transId, cfmStatus); 
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    /* Handle configuration */
@@ -731,10 +712,10 @@ else
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,"RgUiRgrSiCfgReq:"
                    "Configuration Request Handling Failed");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
-   RETVALUE(ROK);
+   return ROK;
 }  /* RgUiRgrSiCfgReq */
 
 \f
@@ -760,7 +741,7 @@ else
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrWarningSiCfgReq
+S16 RgUiRgrWarningSiCfgReq
 (
 Pst           *pst, 
 SpId          spId,
@@ -768,7 +749,7 @@ RgrCfgTransId transId,
 RgrWarningSiCfgReqInfo *warningSiCfgReqInfo
 )
 #else
-PUBLIC S16 RgUiRgrWarningSiCfgReq(pst, spId, transId, warningSiCfgReqInfo)
+S16 RgUiRgrWarningSiCfgReq(pst, spId, transId, warningSiCfgReqInfo)
 Pst           *pst; 
 SpId          spId;
 RgrCfgTransId transId;
@@ -780,9 +761,7 @@ RgrWarningSiCfgReqInfo *warningSiCfgReqInfo;
    U8       cfmStatus = RGR_CFG_CFM_NOK;
    U8       prntTrans[RGR_CFG_TRANSID_SIZE+1];
 
-   TRC2(RgUiRgrWarningSiCfgReq);
-
-   cmMemcpy((U8 *)prntTrans, (U8 *)transId.trans, RGR_CFG_TRANSID_SIZE);
+   memcpy(prntTrans, transId.trans, RGR_CFG_TRANSID_SIZE);
    prntTrans[RGR_CFG_TRANSID_SIZE] = '\0';
 
 
@@ -792,7 +771,7 @@ RgrWarningSiCfgReqInfo *warningSiCfgReqInfo;
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,"Input Message Buffer "
                "is NULL");
       rgSCHUtlRgrWarningSiCfgCfm(instId, spId, 0, transId, cfmStatus);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if (spId < rgSchCb[instId].numSaps)
@@ -810,7 +789,7 @@ RgrWarningSiCfgReqInfo *warningSiCfgReqInfo;
                sizeof(RgrWarningSiCfgReqInfo));
          rgSCHUtlRgrWarningSiCfgCfm(instId, spId, warningSiCfgReqInfo->siId, 
                transId, cfmStatus);
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
    }
    else
@@ -826,7 +805,7 @@ RgrWarningSiCfgReqInfo *warningSiCfgReqInfo;
             sizeof(RgrWarningSiCfgReqInfo));
       rgSCHUtlRgrWarningSiCfgCfm(instId, spId, warningSiCfgReqInfo->siId, 
             transId, cfmStatus);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    /* Handle configuration */
@@ -849,10 +828,10 @@ else
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,
                "Configuration Request Handling Failed");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
-   RETVALUE(ROK);
+   return ROK;
 }
 
 \f
@@ -877,7 +856,7 @@ else
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrWarningSiStopReq
+S16 RgUiRgrWarningSiStopReq
 (
 Pst           *pst,
 SpId          spId,
@@ -885,7 +864,7 @@ RgrCfgTransId transId,
 U8            siId
 )
 #else
-PUBLIC S16 RgUiRgrWarningSiStopReq(pst,spId, transId, siId)
+S16 RgUiRgrWarningSiStopReq(pst,spId, transId, siId)
 Pst           *pst;
 SpId          spId;
 RgrCfgTransId transId;
@@ -894,10 +873,6 @@ U8            siId;
 {         
    Inst         instId = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgUiRgrWarningSiStopReq)
-
-
-
    if (spId < rgSchCb[instId].numSaps)
    {
       if(LRG_BND != rgSchCb[instId].rgrSap[spId].sapSta.sapState)
@@ -907,7 +882,7 @@ U8            siId;
                (ErrVal)rgSchCb[instId].rgrSap[spId].sapSta.sapState,
                "Invalid SAP State: RgUiRgrWarningSiStopReq failed\n");
 #endif
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
    }
    else
@@ -917,13 +892,13 @@ U8            siId;
             (ErrVal)rgSchCb[instId].rgrSap[spId].sapCfg.spId,
             "Invalid SAP Id:RgUiRgrWarningSiStopReq failed\n");
 #endif
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    rgSCHGomHndlWarningSiStopReq(pst->region, pst->pool,
          &rgSchCb[instId], siId, transId, spId);
 
-   RETVALUE(ROK);
+   return ROK;
 }
 #endif /*RGR_SI_SCH */
 
@@ -951,7 +926,7 @@ U8            siId;
  *      -# RFAILED
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgrLoadInfReq
+S16 RgUiRgrLoadInfReq
 (
  Pst               *pst,
  SpId              spId,
@@ -959,7 +934,7 @@ PUBLIC S16 RgUiRgrLoadInfReq
  RgrLoadInfReqInfo *loadInfReq
  )
 #else
-PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
+S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
    Pst               *pst;
    SpId              spId;
    RgrCfgTransId     transId;
@@ -970,9 +945,7 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
    U8        prntTrans[RGR_CFG_TRANSID_SIZE+1];
    Inst      instId = pst->dstInst-SCH_INST_START;
 
-   TRC2(RgUiRgrLoadInfReq);
-
-   cmMemcpy((U8 *)prntTrans, (U8 *)transId.trans, RGR_CFG_TRANSID_SIZE);
+   memcpy(prntTrans, transId.trans, RGR_CFG_TRANSID_SIZE);
    prntTrans[RGR_CFG_TRANSID_SIZE] = '\0';
 
 
@@ -980,7 +953,7 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,"Input Message Buffer "
                "is NULL");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if (spId < rgSchCb[instId].numSaps)
@@ -994,7 +967,7 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
 #endif
          SPutSBuf(pst->region, pst->pool, (Data *)loadInfReq,
                (Size)sizeof(*loadInfReq));
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
    }
    else
@@ -1006,7 +979,7 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
 #endif
       SPutSBuf(pst->region, pst->pool, (Data *)loadInfReq,
             (Size)sizeof(*loadInfReq));
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    /* Handle configuration */
@@ -1017,10 +990,10 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId,
                "Configuration Request Handling Failed");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
-   RETVALUE(ROK);
+   return ROK;
 }  /* RgUiRgrLoadInfReq */
 /* LTE_ADV_FLAG_REMOVED_END */
 
@@ -1042,13 +1015,13 @@ PUBLIC S16 RgUiRgrLoadInfReq(pst, spId, transId, loadInfReq)
  *      -# ROK 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchDedBoUpdtReq
+S16 RgMacSchDedBoUpdtReq
 (
 Pst*           pst,
 RgInfDedBoRpt  *boRpt
 )
 #else
-PUBLIC S16 RgMacSchDedBoUpdtReq(pst, boRpt)
+S16 RgMacSchDedBoUpdtReq(pst, boRpt)
 Pst*           pst;
 RgInfDedBoRpt  *boRpt;
 #endif
@@ -1063,7 +1036,6 @@ RgInfDedBoRpt  *boRpt;
    Inst          inst = (pst->dstInst - SCH_INST_START);
    S16           cellSapId = boRpt->cellSapId;
 
-   TRC3(RgMacSchDedBoUpdtReq)
 /*
    RLOG_ARG2(L_DEBUG,DBG_CELLID,boRpt->cellId,"rgMacSchDedBoUpdtReq():"
             " boRpt->rnti = %u  boRpt->lcId = %u",boRpt->rnti, boRpt->lcId);
@@ -1078,7 +1050,7 @@ RgInfDedBoRpt  *boRpt;
       /* Handle Cell fetch failure */
       RGSCHLOGERROR(inst, ERRCLS_INT_PAR,ERG009,(ErrVal)boRpt->cellId,
                             "rgMacSchDedBoUpdtReq(): Invalid cell Id");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
 
@@ -1090,7 +1062,7 @@ RgInfDedBoRpt  *boRpt;
 #ifdef LTE_ADV
       if (cell != ue->cell)
       {
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
 #endif
       if ((dlLc = rgSCHDbmGetDlDedLcCb(ue, boRpt->lcId)) != NULLP)
@@ -1156,10 +1128,10 @@ RgInfDedBoRpt  *boRpt;
          dlLc->setMaxDlPrio = boRpt->setMaxDlPrio;
          /* Update the scheduler */
          rgSCHUtlDlDedBoUpd(cell, ue, dlLc);
-         RETVALUE(ROK);
+         return ROK;
       }
    }
-   RETVALUE(RFAILED);
+   return RFAILED;
 
 } /* end of rgMacSchDedBoUpdtReq */
 
@@ -1181,13 +1153,13 @@ RgInfDedBoRpt  *boRpt;
  *      -# ROK 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchCmnBoUpdtReq
+S16 RgMacSchCmnBoUpdtReq
 (
 Pst*           pst,
 RgInfCmnBoRpt  *boRpt
 )
 #else
-PUBLIC S16 RgMacSchCmnBoUpdtReq(pst, boRpt)
+S16 RgMacSchCmnBoUpdtReq(pst, boRpt)
 Pst*           pst;
 RgInfCmnBoRpt  *boRpt;
 #endif
@@ -1196,7 +1168,6 @@ RgInfCmnBoRpt  *boRpt;
    Inst          inst = (pst->dstInst - SCH_INST_START);
    S16           cellSapId = boRpt->cellSapId;
 
-   TRC3(RgMacSchCmnBoUpdtReq)
 
    /* No need to chk for cell being NULL as MAC would not have found instance if
     * it doesnt exist */
@@ -1205,7 +1176,7 @@ RgInfCmnBoRpt  *boRpt;
    {
       RLOG_ARG1(L_DEBUG,DBG_CELLID,cell->cellId,"RgMacSchCmnBoUpdtReq():"
                "Invalid boRpt cell Id:%d",boRpt->cellId);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    /* handle status response on CCCH */
@@ -1220,7 +1191,7 @@ RgInfCmnBoRpt  *boRpt;
       rgSCHUtlHndlBcchPcchBoUpdt(cell, boRpt); 
    }
    
-   RETVALUE(ROK);
+   return ROK;
 } /* end of RgMacSchCmnBoUpdtReq */
 /*Fix: start: Inform UE delete to scheduler*/
 /**
@@ -1239,13 +1210,13 @@ RgInfCmnBoRpt  *boRpt;
  *      -# ROK 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchUeDelInd
+S16 RgMacSchUeDelInd
 (
 Pst*             pst,
 RgInfUeDelInd    *ueDelInd
 )
 #else
-PUBLIC S16 RgMacSchUeDelInd(pst, ueDelInd)
+S16 RgMacSchUeDelInd(pst, ueDelInd)
 Pst*             pst;
 RgInfUeDelInd    *ueDelInd;
 #endif
@@ -1256,12 +1227,10 @@ RgInfUeDelInd    *ueDelInd;
    CmLList           *tmp;
    RgSchRntiLnk      *rntiLnk=NULL;
    
-   TRC3(RgMacSchUeDelInd)
-
    if (rgSchCb[inst].rgrSap == NULLP || rgSchCb[inst].rgrSap[cellSapId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,ueDelInd->cellId,"rgrSap or cell is not configured");
-      RETVALUE(ROK);
+      return ROK;
    }
    cell = rgSchCb[inst].rgrSap[cellSapId].cell;
 #ifndef NO_ERRCLS
@@ -1271,7 +1240,7 @@ RgInfUeDelInd    *ueDelInd;
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,
                        "rgMacSchUeDelInd(): Invalid ueDelInd cell Id:%d",
                         ueDelInd->cellId);
-      RETVALUE(ROK);
+      return ROK;
    }
 #endif
       
@@ -1305,7 +1274,7 @@ RgInfUeDelInd    *ueDelInd;
            "Guard Pool:%ld", ueDelInd->rnti, cell->rntiDb.rntiGuardPool.count);
    } 
    
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgMacSchUeDelInd */
 /*Fix: end: Inform UE delete to scheduler*/
 /**
@@ -1327,13 +1296,13 @@ RgInfUeDelInd    *ueDelInd;
  *      -# ROK 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchSfRecpInd
+S16 RgMacSchSfRecpInd
 (
 Pst*             pst,
 RgInfSfDatInd    *subfrmInfo
 )
 #else
-PUBLIC S16 RgMacSchSfRecpInd(pst, subfrmInfo)
+S16 RgMacSchSfRecpInd(pst, subfrmInfo)
 Pst*             pst;
 RgInfSfDatInd    *subfrmInfo;
 #endif
@@ -1365,7 +1334,6 @@ RgInfSfDatInd    *subfrmInfo;
    U16              diffBits = 0;
    U8               lcCount;
 #endif
-   TRC3(RgMacSchSfRecpInd)
 
    /* No need to chk for cell being NULL as MAC wouldn't have found instance if
     * it doesnt exist */
@@ -1409,7 +1377,7 @@ RgInfSfDatInd    *subfrmInfo;
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,
                       "Received MSG3 with CRNTI:%d and also CCCH ", 
                      datInd->ceInfo.ces.cRnti);
-            RETVALUE(RFAILED);
+            return RFAILED;
          }
          ue = rgSCHDbmGetUeCb (cell, datInd->ceInfo.ces.cRnti);
          if (ue == NULLP)
@@ -1422,7 +1390,7 @@ RgInfSfDatInd    *subfrmInfo;
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId, "Received MSG3 "
                      "with CRNTI:%d unable to find ueCb", 
                      datInd->ceInfo.ces.cRnti);
-            RETVALUE(RFAILED);
+            return RFAILED;
          }
 
          if ((ret = rgSCHUtlProcMsg3 (subfrmInfo, cell, ue, 
@@ -1432,7 +1400,7 @@ RgInfSfDatInd    *subfrmInfo;
             err.errType = RGSCHERR_TOM_DATIND;
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId, "Processing for MSG3 failed for CRNTI:%d", 
                      datInd->rnti);
-            RETVALUE(RFAILED);
+            return RFAILED;
          }
          
 #ifdef LTEMAC_SPS
@@ -1479,7 +1447,7 @@ RgInfSfDatInd    *subfrmInfo;
             err.errType = RGSCHERR_TOM_DATIND;
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Processing for MSG3 failed for CRNTI:%d", 
                      datInd->rnti);
-            RETVALUE(RFAILED);
+            return RFAILED;
          }
          /* fix */
           CM_LLIST_NEXT_NODE(lnkLst, tmp);
@@ -1499,7 +1467,7 @@ RgInfSfDatInd    *subfrmInfo;
                err.errType = RGSCHERR_TOM_DATIND;
                RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the UE CB for CRNTI:%d", 
                datInd->rnti);
-               RETVALUE(RFAILED);
+               return RFAILED;
             }
          }
       }
@@ -1563,7 +1531,7 @@ RgInfSfDatInd    *subfrmInfo;
          err.errType = RGSCHERR_TOM_DATIND;
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to handle Data"
                    " Indication for UEID:%d",ue->ueId);
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
 
       CM_LLIST_NEXT_NODE(lnkLst, tmp);
@@ -1578,7 +1546,7 @@ RgInfSfDatInd    *subfrmInfo;
 
    /* chk if Sch needs to dealloc datInd after unpk */
    RGSCH_FREE_MEM(subfrmInfo);
-   RETVALUE(ret);
+   return (ret);
 }  /* rgMacSchSfRecpInd */
 
 #ifdef LTEMAC_SPS
@@ -1603,13 +1571,13 @@ RgInfSfDatInd    *subfrmInfo;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchSpsRelInd
+S16 RgMacSchSpsRelInd
 (
 Pst                *pst, 
 RgInfSpsRelInfo    *relInfo
 )
 #else
-PUBLIC S16 RgMacSchSpsRelInd(pst, relInfo)
+S16 RgMacSchSpsRelInd(pst, relInfo)
 Pst                *pst;
 RgInfSpsRelInfo    *relInfo;
 #endif
@@ -1618,7 +1586,6 @@ RgInfSpsRelInfo    *relInfo;
    RgSchCellCb     *cell;
    Inst            inst = (pst->dstInst - SCH_INST_START);
 
-   TRC2(RgMacSchSpsRelInd);
 
    /* No need to chk for cell being NULL as MAC wouldn't have found instance if
     * it doesnt exist */
@@ -1628,16 +1595,16 @@ RgInfSpsRelInfo    *relInfo;
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId, 
            "No Ue exists with CRNTI:%d",relInfo->cRnti);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if ((rgSCHUtlSpsRelInd(cell, ue, relInfo->isExplRel)) != ROK)
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId, 
            "RelInd processing for CRNTI:%d failed",relInfo->cRnti);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
-   RETVALUE(ROK);
+   return ROK;
 } /* end of RgMacSchSpsRelInd */
 #endif /* LTEMAC_SPS */
 
@@ -1664,13 +1631,13 @@ RgInfSpsRelInfo    *relInfo;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchL2MeasCfm
+S16 RgMacSchL2MeasCfm
 (
 Pst                *pst, 
 RgInfL2MeasCfm     *measCfm
 )
 #else
-PUBLIC S16 RgMacSchL2MeasCfm(pst, measCfm)
+S16 RgMacSchL2MeasCfm(pst, measCfm)
 Pst                *pst;
 RgInfL2MeasCfm     *measCfm;
 #endif
@@ -1685,7 +1652,6 @@ RgInfL2MeasCfm     *measCfm;
    U8                qciVal;
    U8                idx1; /*LTE_L2_MEAS_PHASE2*/ 
    U8                qciVal1;
-   TRC2(RgMacSchL2MeasCfm);
 
    /* Find the cellCb using cellId in measInfo. Iterate through all cells
     * in rgrsapCb in RgschCb */
@@ -1703,7 +1669,7 @@ RgInfL2MeasCfm     *measCfm;
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,measCfm->cellId,
                   "Meas Cfm Failed.Invalid Cell Id");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    
 
@@ -1721,7 +1687,7 @@ RgInfL2MeasCfm     *measCfm;
    }
    if ( measCb == NULLP )
    {
-      RETVALUE( RFAILED );
+      return ( RFAILED );
    }
 
 
@@ -1738,13 +1704,13 @@ RgInfL2MeasCfm     *measCfm;
       /* ccpu00117052 - MOD - Passing double pointer
          for proper NULLP assignment*/
       rgSCHUtlFreeSBuf(cell->instIdx, (Data **)&measCb, sizeof(RgSchL2MeasCb));
-      cmMemset((U8 *)&schMeasCfm, 0, sizeof(LrgSchMeasCfmInfo));
+      memset(&schMeasCfm, 0, sizeof(LrgSchMeasCfmInfo));
       schMeasCfm.measType     = measCfm->measType;
       schMeasCfm.cfm          = measCfm->cfm;
       schMeasCfm.hdr.transId  = measCfm->transId;
       schMeasCfm.cellId       = measCfm->cellId;
       RgMiLrgSchL2MeasCfm(&(instCb->rgSchInit.lmPst), &schMeasCfm);
-      RETVALUE(ROK);
+      return ROK;
    }
    for(idx = 0; idx < measCfm->u.prbCfm.numQci; idx++)
    {
@@ -1767,7 +1733,7 @@ RgInfL2MeasCfm     *measCfm;
    measCb->avgPrbQciUl.numQci = measCfm->u.prbCfm.numQci;
    measCb->cfmRcvd = TRUE;
    cell->sndL2Meas = TRUE;
-   RETVALUE(ROK);
+   return ROK;
 } /* end of RgMacSchL2MeasCfm */
 
 /**
@@ -1791,13 +1757,13 @@ RgInfL2MeasCfm     *measCfm;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgMacSchL2MeasStopCfm
+S16 RgMacSchL2MeasStopCfm
 (
 Pst                *pst,
 RgInfL2MeasCfm     *measCfm
 )
 #else
-PUBLIC S16 RgMacSchL2MeasStopCfm(pst, measCfm)
+S16 RgMacSchL2MeasStopCfm(pst, measCfm)
 Pst                *pst;
 RgInfL2MeasCfm     *measCfm;
 #endif
@@ -1806,15 +1772,13 @@ RgInfL2MeasCfm     *measCfm;
    Inst              inst = (pst->dstInst - SCH_INST_START);
    RgSchCb           *instCb =  &rgSchCb[inst];
 
-   TRC2(RgMacSchL2MeasStopCfm);
-
-   cmMemset((U8 *)&schMeasCfm, 0, sizeof(LrgSchMeasCfmInfo));
+   memset(&schMeasCfm, 0, sizeof(LrgSchMeasCfmInfo));
    schMeasCfm.measType     = measCfm->measType;
    schMeasCfm.cfm          = measCfm->cfm;
    schMeasCfm.hdr.transId  = measCfm->transId;
    schMeasCfm.cellId       = measCfm->cellId;
    RgMiLrgSchL2MeasStopCfm(&(instCb->rgSchInit.lmPst), &schMeasCfm);
-   RETVALUE(ROK);
+   return ROK;
 }
 #endif
 
@@ -1838,14 +1802,14 @@ RgInfL2MeasCfm     *measCfm;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuSchBndCfm 
+S16 RgLiTfuSchBndCfm 
 (
 Pst     *pst,
 SuId    suId, 
 U8      status
 )
 #else
-PUBLIC S16 RgLiTfuSchBndCfm(pst, suId, status)
+S16 RgLiTfuSchBndCfm(pst, suId, status)
 Pst     *pst; 
 SuId    suId; 
 U8      status;
@@ -1855,13 +1819,10 @@ U8      status;
    RgSchLowSapCb  *tfuSap;
    Inst  instId = pst->dstInst - SCH_INST_START;
 
-   TRC3(RgLiTfuSchBndCfm);
-
-
    if(suId >= rgSchCb[instId].numSaps)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,instId, "Incorrect SuId");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    /* Lets validate suId first */
    tfuSap = &(rgSchCb[instId].tfuSap[suId]);
@@ -1870,10 +1831,10 @@ U8      status;
    {
       RLOG_ARG2(L_ERROR,DBG_INSTID,instId, "Incorrect SuId. Configured (%d)"
             "Recieved (%d)", tfuSap->sapCfg.suId, suId);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHLmmBndCfm (pst, suId, status);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuSchBndCfm */
 
 /**
@@ -1895,14 +1856,14 @@ U8      status;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuRaReqInd
+S16 RgLiTfuRaReqInd
 (
 Pst              *pst, 
 SuId             suId, 
 TfuRaReqIndInfo  *raReqInd
 )
 #else
-PUBLIC S16 RgLiTfuRaReqInd(pst, suId, raReqInd)
+S16 RgLiTfuRaReqInd(pst, suId, raReqInd)
 Pst              *pst; 
 SuId             suId; 
 TfuRaReqIndInfo  *raReqInd;
@@ -1911,26 +1872,24 @@ TfuRaReqIndInfo  *raReqInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuRaReqInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG1(L_ERROR,DBG_INSTID,inst,"SAP Validation failed SuId(%d)", suId);
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(raReqInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if(raReqInd == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"Invalid input pointer for raReqInd Failed");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,raReqInd->cellId,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    ret = rgSCHTomRaReqInd(rgSchCb[inst].tfuSap[suId].cell, raReqInd);
@@ -1938,7 +1897,7 @@ TfuRaReqIndInfo  *raReqInd;
    RGSCH_FREE_MEM(raReqInd);
    /*SPutSBuf (pst->region, pst->pool, (Data *)raReqInd,
          sizeof(TfuRaReqIndInfo)); */
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuRaReqInd */
 
 /**
@@ -1959,14 +1918,14 @@ TfuRaReqIndInfo  *raReqInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuUlCqiInd
+S16 RgLiTfuUlCqiInd
 (
 Pst              *pst, 
 SuId             suId, 
 TfuUlCqiIndInfo  *ulCqiInd
 )
 #else
-PUBLIC S16 RgLiTfuUlCqiInd(pst, suId, ulCqiInd)
+S16 RgLiTfuUlCqiInd(pst, suId, ulCqiInd)
 Pst              *pst; 
 SuId             suId; 
 TfuUlCqiIndInfo  *ulCqiInd;
@@ -1975,14 +1934,12 @@ TfuUlCqiIndInfo  *ulCqiInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuUlCqiInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(ulCqiInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
@@ -1990,12 +1947,12 @@ TfuUlCqiIndInfo  *ulCqiInd;
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(ulCqiInd);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHTomUlCqiInd (rgSchCb[inst].tfuSap[suId].cell, ulCqiInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(ulCqiInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuUlCqiInd */
 
 /**
@@ -2016,14 +1973,14 @@ TfuUlCqiIndInfo  *ulCqiInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuPucchDeltaPwrInd
+S16 RgLiTfuPucchDeltaPwrInd
 (
 Pst                     *pst,
 SuId                    suId,
 TfuPucchDeltaPwrIndInfo *pucchDeltaPwr
 )
 #else
-PUBLIC S16 RgLiTfuPucchDeltaPwrInd(pst, suId, pucchDeltaPwr)
+S16 RgLiTfuPucchDeltaPwrInd(pst, suId, pucchDeltaPwr)
 Pst                     *pst;
 SuId                    suId;
 TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
@@ -2032,25 +1989,23 @@ TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuPucchDeltaPwrInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(pucchDeltaPwr);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHTomPucchDeltaPwrInd (rgSchCb[inst].tfuSap[suId].cell, pucchDeltaPwr);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(pucchDeltaPwr);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuPucchDeltaPwrInd */
 
 
@@ -2074,14 +2029,14 @@ TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuHqInd
+S16 RgLiTfuHqInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuHqIndInfo       *harqAckInd
 )
 #else
-PUBLIC S16 RgLiTfuHqInd(pst, suId, harqAckInd)
+S16 RgLiTfuHqInd(pst, suId, harqAckInd)
 Pst                *pst; 
 SuId               suId; 
 TfuHqIndInfo       *harqAckInd;
@@ -2090,20 +2045,19 @@ TfuHqIndInfo       *harqAckInd;
    S16   ret;
    Inst  inst = (pst->dstInst - SCH_INST_START);
 
-   TRC3(RgLiTfuHqInd);
 
 #ifndef NO_ERRCLS
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       RGSCH_FREE_MEM(harqAckInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
 
@@ -2111,7 +2065,7 @@ TfuHqIndInfo       *harqAckInd;
    ret = rgSCHTomHarqAckInd (rgSchCb[inst].tfuSap[suId].cell, harqAckInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(harqAckInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuHqInd */
 
 
@@ -2134,14 +2088,14 @@ TfuHqIndInfo       *harqAckInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuSrInd
+S16 RgLiTfuSrInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuSrIndInfo       *srInd
 )
 #else 
-PUBLIC S16 RgLiTfuSrInd(pst, suId, srInd)
+S16 RgLiTfuSrInd(pst, suId, srInd)
 Pst                *pst; 
 SuId               suId; 
 TfuSrIndInfo       *srInd;
@@ -2150,27 +2104,25 @@ TfuSrIndInfo       *srInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuSrInd);
-
 #ifndef NO_ERRCLS
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"() SAP Validation failed");
       RGSCH_FREE_MEM(srInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"RgLiTfuSrInd()No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
    /* Now call the TOM (Tfu ownership module) primitive to process further */
    ret = rgSCHTomSrInd (rgSchCb[inst].tfuSap[suId].cell, srInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(srInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuSrInd */
 
 
@@ -2193,14 +2145,14 @@ TfuSrIndInfo       *srInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuDlCqiInd
+S16 RgLiTfuDlCqiInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuDlCqiIndInfo    *dlCqiInd
 )
 #else
-PUBLIC S16 RgLiTfuDlCqiInd(pst, suId, dlCqiInd)
+S16 RgLiTfuDlCqiInd(pst, suId, dlCqiInd)
 Pst                *pst; 
 SuId               suId; 
 TfuDlCqiIndInfo    *dlCqiInd;
@@ -2209,25 +2161,23 @@ TfuDlCqiIndInfo    *dlCqiInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuDlCqiInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst," SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(dlCqiInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHTomDlCqiInd (rgSchCb[inst].tfuSap[suId].cell, dlCqiInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(dlCqiInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuDlCqiInd */
 #ifdef TFU_UPGRADE
 
@@ -2250,14 +2200,14 @@ TfuDlCqiIndInfo    *dlCqiInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuRawCqiInd
+S16 RgLiTfuRawCqiInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuRawCqiIndInfo    *rawCqiInd
 )
 #else
-PUBLIC S16 RgLiTfuRawCqiInd(pst, suId, rawCqiInd)
+S16 RgLiTfuRawCqiInd(pst, suId, rawCqiInd)
 Pst                *pst; 
 SuId               suId; 
 TfuRawCqiIndInfo    *rawCqiInd;
@@ -2266,27 +2216,25 @@ TfuRawCqiIndInfo    *rawCqiInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuRawCqiInd);
-
 #ifdef NO_ERRCLS
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(rawCqiInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst," No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
    ret = rgSCHTomRawCqiInd (rgSchCb[inst].tfuSap[suId].cell, rawCqiInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(rawCqiInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuRawCqiInd */
 
 /**
@@ -2308,14 +2256,14 @@ TfuRawCqiIndInfo    *rawCqiInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuSrsInd
+S16 RgLiTfuSrsInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuSrsIndInfo    *srsInd
 )
 #else
-PUBLIC S16 RgLiTfuSrsInd(pst, suId, srsInd)
+S16 RgLiTfuSrsInd(pst, suId, srsInd)
 Pst                *pst; 
 SuId               suId; 
 TfuSrsIndInfo    *srsInd;
@@ -2324,25 +2272,23 @@ TfuSrsIndInfo    *srsInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuSrsInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst," SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(srsInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHTomSrsInd (rgSchCb[inst].tfuSap[suId].cell, srsInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(srsInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuSrsInd */
 
 #endif 
@@ -2366,14 +2312,14 @@ TfuSrsIndInfo    *srsInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuDoaInd 
+S16 RgLiTfuDoaInd 
 (
 Pst                *pst, 
 SuId               suId, 
 TfuDoaIndInfo      *doaInd
 )
 #else
-PUBLIC S16 RgLiTfuDoaInd(pst, suId, doaInd)
+S16 RgLiTfuDoaInd(pst, suId, doaInd)
 Pst                *pst; 
 SuId               suId; 
 TfuDoaIndInfo      *doaInd;
@@ -2382,25 +2328,23 @@ TfuDoaIndInfo      *doaInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC2(RgLiTfuDoaInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(doaInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    ret = rgSCHTomDoaInd (rgSchCb[inst].tfuSap[suId].cell, doaInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(doaInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuDlCqiInd */
 
 /**
@@ -2420,14 +2364,14 @@ TfuDoaIndInfo      *doaInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuCrcInd
+S16 RgLiTfuCrcInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuCrcIndInfo  *crcInd
 )
 #else
-PUBLIC S16 RgLiTfuCrcInd (pst, suId, crcInd)
+S16 RgLiTfuCrcInd (pst, suId, crcInd)
 Pst                *pst; 
 SuId               suId; 
 TfuCrcIndInfo  *crcInd;
@@ -2436,7 +2380,6 @@ TfuCrcIndInfo  *crcInd;
    S16              ret;
    Inst             inst      = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuCrcInd);
 #ifdef XEON_SPECIFIC_CHANGES
 struct timeval start6, end6;
 gettimeofday(&start6, NULL);
@@ -2446,13 +2389,13 @@ gettimeofday(&start6, NULL);
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       RGSCH_FREE_MEM(crcInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
 
@@ -2463,7 +2406,7 @@ gettimeofday(&start6, NULL);
 #ifdef XEON_SPECIFIC_CHANGES
 gettimeofday(&end6, NULL);
 #endif
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuCrcInd */
 
 /**
@@ -2484,14 +2427,14 @@ gettimeofday(&end6, NULL);
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuTimingAdvInd
+S16 RgLiTfuTimingAdvInd
 (
 Pst                  *pst, 
 SuId                 suId, 
 TfuTimingAdvIndInfo  *timingAdvInd
 )
 #else
-PUBLIC S16 RgLiTfuTimingAdvInd(pst, suId, timingAdvInd)
+S16 RgLiTfuTimingAdvInd(pst, suId, timingAdvInd)
 Pst                  *pst; 
 SuId                 suId; 
 TfuTimingAdvIndInfo  *timingAdvInd;
@@ -2500,26 +2443,24 @@ TfuTimingAdvIndInfo  *timingAdvInd;
    S16   ret;
    Inst  inst = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgLiTfuTimingAdvInd);
-
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
       /* Free up the memory for the request structure */
       RGSCH_FREE_MEM(timingAdvInd);
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
    /* Now call the TOM (Tfu ownership module) primitive to process further */
    ret = rgSCHTomTimingAdvInd(rgSchCb[inst].tfuSap[suId].cell, timingAdvInd);
    /* Free up the memory for the request structure */
    RGSCH_FREE_MEM(timingAdvInd);
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuTimingAdvInd */
 
 /************* RGM  Interface ****************/
@@ -2543,14 +2484,14 @@ TfuTimingAdvIndInfo  *timingAdvInd;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgmBndReq
+S16 RgUiRgmBndReq
 (
 Pst   *pst, 
 SuId  suId,
 SpId  spId
 )
 #else
-PUBLIC S16 RgUiRgmBndReq(pst, suId, spId)
+S16 RgUiRgmBndReq(pst, suId, spId)
 Pst   *pst; 
 SuId  suId;
 SpId  spId;
@@ -2560,9 +2501,6 @@ SpId  spId;
    Pst       tmpPst;   /* Temporary Post Structure */
    Inst      instId = pst->dstInst-SCH_INST_START;
 
-   TRC3(RgUiRgmBndReq)
-   
-   
    tmpPst.prior       = pst->prior;
    tmpPst.route       = pst->route;
    tmpPst.selector    = pst->selector;
@@ -2621,7 +2559,7 @@ SpId  spId;
 #endif
       ret = RgUiRgmBndCfm(&tmpPst, suId, CM_BND_NOK);
    }
-   RETVALUE(ret);
+   return (ret);
 }  /* RgUiRgmBndReq */
 
 /**
@@ -2644,22 +2582,20 @@ SpId  spId;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgmUbndReq
+S16 RgUiRgmUbndReq
 (
 Pst    *pst,
 SpId   spId,
 Reason reason
 )
 #else
-PUBLIC S16 RgUiRgmUbndReq(pst, spId, reason)
+S16 RgUiRgmUbndReq(pst, spId, reason)
 Pst    *pst; 
 SpId   spId;
 Reason reason;
 #endif
 {
    Inst instId = pst->dstInst-SCH_INST_START;
-   TRC3(RgUiRgmUbndReq)
-   
 
    /* SAP Id validation */
    if (spId < rgSchCb[instId].numSaps)
@@ -2677,7 +2613,7 @@ Reason reason;
                    (ErrVal)rgSchCb[instId].rgmSap[spId].sapSta.sapState,
                   "Invalid SAP State: RgUiRgmUbndReq failed\n");
 #endif
-            RETVALUE(RFAILED);
+            return RFAILED;
       }
    }
    else
@@ -2687,9 +2623,9 @@ Reason reason;
             (ErrVal)rgSchCb[instId].rgmSap[spId].sapSta.sapState,
             "Invalid SAP Id:RgUiRgmUbndReq failed\n");
 #endif
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* RgUiRgmUbndReq */
 
 
@@ -2713,14 +2649,14 @@ Reason reason;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgUiRgmCfgPrbRprt
+S16 RgUiRgmCfgPrbRprt
 (
 Pst   *pst, 
 SpId  spId,
 RgmPrbRprtCfg   *prbRprtCfg
 )
 #else
-PUBLIC S16 RgUiRgmCfgPrbRprt(pst, spId, prbRprtCfg)
+S16 RgUiRgmCfgPrbRprt(pst, spId, prbRprtCfg)
 Pst   *pst; 
 SpId  spId;
 RgmPrbRprtCfg   *prbRprtCfg;
@@ -2731,7 +2667,6 @@ RgmPrbRprtCfg   *prbRprtCfg;
    RgSchPrbUsage *prbUsage;
    Inst          inst = (pst->dstInst  - SCH_INST_START);
 
-   TRC2(RgUiRgmCfgPrbRprt);
    cell = rgSchCb[inst].rgmSap[spId].cell;
    prbUsage = &cell->prbUsage;
    prbUsage->prbRprtEnabld = prbRprtCfg->bConfigType;
@@ -2739,7 +2674,7 @@ RgmPrbRprtCfg   *prbRprtCfg;
    RG_SCH_ADD_TO_CRNT_TIME(cell->crntTime, prbUsage->startTime, 1);
 
    /* clear the qciPrbRpts for all GBR QCIs */
-   cmMemset((U8*)&prbUsage->qciPrbRpts[0], 0, 
+   memset(&prbUsage->qciPrbRpts[0], 0, 
              (RGM_MAX_QCI_REPORTS * sizeof(RgSchQciPrbUsage)));
 
    RLOG_ARG2(L_DEBUG,DBG_CELLID,cell->cellId,
@@ -2749,7 +2684,7 @@ RgmPrbRprtCfg   *prbRprtCfg;
    /* ccpu00134393 : mem leak fix */
       SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg));
   
-   RETVALUE(ROK);
+   return ROK;
 }
 /**
  * @brief ERROR INDICATION from PHY for the i failed unlicensed Scell transmission. 
@@ -2772,14 +2707,14 @@ RgmPrbRprtCfg   *prbRprtCfg;
  *      -# RFAILED 
  **/
 #ifdef ANSI
-PUBLIC S16 RgLiTfuErrInd
+S16 RgLiTfuErrInd
 (
 Pst                *pst, 
 SuId               suId, 
 TfuErrIndInfo       *errInd
 )
 #else
-PUBLIC S16 RgLiTfuErrInd(pst, suId, errInd)
+S16 RgLiTfuErrInd(pst, suId, errInd)
 Pst                *pst; 
 SuId               suId; 
 TfuErrIndInfo       *errInd;
@@ -2790,20 +2725,18 @@ TfuErrIndInfo       *errInd;
    Inst  inst = (pst->dstInst - SCH_INST_START);
 #endif
 
-   TRC3(RgLiTfuErrInd);
-
 #ifndef NO_ERRCLS
    if ((ret = rgSCHUtlValidateTfuSap (inst, suId)) != ROK)
    {
 
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"SAP Validation failed");
-      RETVALUE(ret);
+      return (ret);
    }
 
    if (rgSchCb[inst].tfuSap[suId].cell == NULLP)
    {
       RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"No cell exists");
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 #endif
 
@@ -2811,7 +2744,7 @@ TfuErrIndInfo       *errInd;
    /* Now call the TOM (Tfu ownership module) primitive to process further */
    ret = rgSCHLaaErrInd(rgSchCb[inst].tfuSap[suId].cell, errInd);
 #endif
-   RETVALUE(ret);
+   return (ret);
 }  /* RgLiTfuErrInd */