warning set 4 82/3482/3
authorBalaji Shankaran <balaji.shankaran@radisys.com>
Mon, 27 Apr 2020 12:47:03 +0000 (18:17 +0530)
committerBalaji Shankaran <balaji.shankaran@radisys.com>
Tue, 28 Apr 2020 10:19:16 +0000 (15:49 +0530)
Change-Id: Ie2e31721559aa9a79857be1cc5768d360e044a8c
Signed-off-by: Balaji Shankaran <balaji.shankaran@radisys.com>
27 files changed:
src/5gnrmac/mac.h
src/5gnrmac/rg_ex_ms.c
src/5gnrmac/rg_lmm.c
src/5gnrmac/rg_ptui.c
src/5gnrrlc/kw_utl_ul.c
src/5gnrsch/rg_sch_cmn.c
src/5gnrsch/rg_sch_lmm.c
src/5gnrsch/rg_sch_tom.c
src/5gnrsch/rg_sch_utl.c
src/5gnrsch/sch.h
src/5gnrsch/sch_rach.c
src/5gnrsch/sch_slot_ind.c
src/cm/cm_lte.c
src/cm/du_app_mac_inf.c
src/cm/du_app_mac_inf.h
src/cm/lrg.x
src/cm/lsctp.c
src/cm/rgu.c
src/cm/rgu.x
src/cm/tfu.c
src/codec_utils/common/odu_common_codec.c
src/codec_utils/common/odu_common_codec.h
src/du_app/du_e2ap_msg_hdl.c
src/du_app/du_e2ap_msg_hdl.h
src/du_app/du_msg_hdl.c
src/phy_stub/l1_bdy1.c
src/phy_stub/l1_bdy2.c

index 617212b..b5dd425 100644 (file)
@@ -51,7 +51,7 @@
 #define MAX_SLOT_SUPPORTED    10 /* numerology 0 15Khz */
 #define MAX_ZERO_CORR_CFG_IDX 16 /* max zero correlation config index */
 #define SI_RNTI 0xFFFF
-#define P-RNTI  0xFFFE
+#define P_RNTI 0xFFFE
 
 typedef struct macDlSlot
 {
index 8da7b84..6ee230e 100755 (executable)
@@ -75,7 +75,7 @@ registered with SSI during the LTE MAC Task initialization.
 #include "rg_prg.x"        /*PRG interface includes*/
 #include "du_app_mac_inf.h"
 #include "rg.x"            /* typedefs for MAC */
-void unpackDuMacCellCfg(DuMacCellCfgReq func,Pst *pst,Buffer *mBuf);
+int unpackDuMacCellCfg(DuMacCellCfgReq func,Pst *pst,Buffer *mBuf);
 
 /**
  * @brief Task Activation callback function Entity SM. 
index 059a754..70cc657 100755 (executable)
@@ -136,7 +136,7 @@ RgMngmt       *cfm,
 Pst           *cfmPst
 ));
 
-extern U16 packMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm);
+extern int packMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm);
 
 packMacCellCfgConfirm packMacCellCfmOpts[] =
 {
@@ -1991,13 +1991,13 @@ Inst    inst;
  *      -# ROK
  **/
 #ifdef ANSI
-PUBLIC S16 MacSchGenCfgReq
+PUBLIC int MacSchGenCfgReq
 (
 Pst      *pst,    /* post structure  */
 RgMngmt  *cfg     /* config structure  */
 )
 #else
-PUBLIC S16 MacSchGenCfgReq(pst, cfg)
+PUBLIC int MacSchGenCfgReq(pst, cfg)
 Pst      *pst;    /* post structure  */
 RgMngmt  *cfg;    /* config structure  */
 #endif    
@@ -2111,7 +2111,7 @@ int MacHdlCellCfgReq
 )
 {
    Pst cfmPst;
-   int ret = ROK;
+   uint16_t ret = ROK;
    RgCellCb      *cellCb;
        MacCellCb     *macCellCb;
    Inst inst = pst->dstInst;
index e291e87..7e81e6f 100755 (executable)
@@ -240,8 +240,6 @@ PRIVATE CONSTANT RgrCfgCfm RgUiRgrCfgCfmMt[RG_MAX_RGR_USR] =
 #endif
 #ifdef NX
    NxLiRgrCfgCfm,
-#else
-   PtUiRgrCfgCfm,
 #endif
 };
 
index d3ce168..9baac73 100755 (executable)
@@ -249,7 +249,6 @@ Buffer     *sdu;
 #endif
 {
 #ifndef KW_PDCP
-   KwKwuSapCb      *kwKwSap;     /* KWU SAP Information */
    KwuDatIndInfo   *datIndInfo;   /* Data Indication Information */
    KwuDatIndInfo datIndInfoTmp;
 #endif
@@ -258,7 +257,6 @@ Buffer     *sdu;
 
 
 #ifndef KW_PDCP
-   kwKwSap = gCb->u.ulCb->kwuUlSap + KW_UI_PDCP;
    /* Creating static memory for KwuDatIndInfo. #else will be 
     * removed once the testing is done on all platforms */
    datIndInfo = &datIndInfoTmp;
index 9f23d06..7398c20 100755 (executable)
@@ -4871,7 +4871,7 @@ U8              *hqProcIdRef;
          rgSCHUhmNewTx(hqProc, (U8)(cell->rachCfg.maxMsg3Tx - 1), alloc);
          //RLOG_ARG4(L_DEBUG,DBG_CELLID,cell->cellId,
          printf(
-               "\nRNTI:%d MSG3 ALLOC proc(%p)procId(%d)schdIdx(%d)\n",
+               "\nRNTI:%d MSG3 ALLOC proc(%lu)procId(%d)schdIdx(%d)\n",
                alloc->rnti,
                ((PTR)alloc->hqProc),
                alloc->hqProc->procId,
index 37c2f66..2d90b4b 100755 (executable)
@@ -86,7 +86,7 @@ static int RLOG_FILE_ID=167;
 PUBLIC Void rgSCHCmnInit ARGS((Void));
 #endif 
 /* forward references */
-
+extern int schActvInit(Ent entity, Inst instId, Region region, Reason reason);
 #ifdef UNUSE_FUN
 PRIVATE U16 rgSCHLmmSapCfg ARGS((
    Inst           inst,
index ac3cb3c..7949aba 100755 (executable)
@@ -808,7 +808,7 @@ RgSchUeCb       **ue;
       *ue = rgSCHCmnGetPoUe(cell, rapId, timingInfo);
       printf("     ==== inding UE from PDCCH Order Mapping\n");
    }
-   RETVALUE(ROK);
+   return ROK;
 }
 /**
  * @brief Handler for processing Random Access request indication 
@@ -862,7 +862,7 @@ TfuRaReqIndInfo *raReqInd;
       RLOG_ARG3(L_ERROR,DBG_CELLID,cell->cellId, 
          "rgSCHTomRaReqInd(): No cell found with raReq cellId = (%d) errorType (%d)"
          " errorCause(%d)",raReqInd->cellId, err.errType, err.errCause);
-      RETVALUE(RFAILED);
+      return RFAILED;
    } 
    
    for (raRntiCnt = 0; raRntiCnt < raReqInd->nmbOfRaRnti; raRntiCnt++)
@@ -908,7 +908,7 @@ TfuRaReqIndInfo *raReqInd;
          }
       }
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomRaReqInd */
 
 
@@ -956,7 +956,7 @@ TfuUlCqiIndInfo *ulCqiInd;
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,
          "rgSCHTomUlCqiInd() Unable to get the ulCqiInd cell with id(%d)", 
          ulCqiInd->cellId);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    for (;node; node=node->next)
@@ -984,7 +984,7 @@ TfuUlCqiIndInfo *ulCqiInd;
       /* wideband cqi is directly reported now. and also isTxPort0 */
       rgSCHUtlUlCqiInd(cell, ue, ulCqiInfo);
    }
-   RETVALUE(ROK);
+       return ROK;
 }  /* rgSCHTomUlCqiInd */
 
 /**
@@ -1032,7 +1032,7 @@ TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,
          "rgSCHTomPucchDeltaPwrInd() Unable to get the pucchDeltaPwr cell with id(%d)", 
          pucchDeltaPwr->cellId);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    node =  pucchDeltaPwr->pucchDeltaPwrLst.first;
@@ -1053,7 +1053,7 @@ TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
       }
       rgSCHUtlPucchDeltaPwrInd(cell, ue, ueElem->pucchDeltaPwr);
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomPucchDeltaPwrInd */
 
 /**
@@ -1110,8 +1110,8 @@ TfuHqIndInfo    *harqAckInd;
          " the cell for cellId (%d)", harqAckInd->cellId);
       err.errType = RGSCHERR_TOM_HARQACKIND;
       err.errCause = RGSCHERR_TOM_INV_CELL_ID;
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 #ifdef RG_5GTF   
    node =  harqAckInd->hqIndLst.first;
    for (;node; node=node->next)
@@ -1245,7 +1245,7 @@ TfuHqIndInfo    *harqAckInd;
       }
    }
 #endif 
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomHarqAckInd */
 
 
@@ -1297,8 +1297,8 @@ TfuSrIndInfo    *srInd;
          ":%d ", srInd->cellId);
       err.errType = RGSCHERR_TOM_SRIND;
       err.errCause = RGSCHERR_TOM_INV_CELL_ID;
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
 
    node =  srInd->srLst.first;
@@ -1329,7 +1329,7 @@ TfuSrIndInfo    *srInd;
          continue;
       }
    }
-   RETVALUE(ret);
+   return ROK;
 }  /* end of rgSCHTomSrInd */
 
 /**
@@ -1375,8 +1375,8 @@ TfuDoaIndInfo   *doaInd;
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for doaInd cellId"
          ":%d", doaInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
 
    node =  doaInd->doaRpt.first;
@@ -1392,7 +1392,7 @@ TfuDoaIndInfo   *doaInd;
       }
       rgSCHUtlDoaInd(cell, ue, doaInfo);
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomDoaInd */
 /**
  * @brief Handler for processing downlink CQI indication recieved from 
@@ -1437,8 +1437,8 @@ TfuDlCqiIndInfo *dlCqiInd;
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for cellId"
          ":%d", dlCqiInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
 
    node =  dlCqiInd->dlCqiRptsLst.first;
@@ -1455,7 +1455,7 @@ TfuDlCqiIndInfo *dlCqiInd;
       rgSCHUtlDlCqiInd(cell, ue, dlCqiInfo, dlCqiInd->timingInfo);
       rgSCHUtlHdlUlTransInd(cell, ue, dlCqiInd->timingInfo);
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomDlCqiInd */
 
 /**
@@ -1528,7 +1528,7 @@ PRIVATE S16 rgSCHTomUtlMovePcqiNxtOccasion(cell, ue, cqiCb)
    rgSCHUtlSCellHndlCqiCollsn(cqiCb);
 #endif
 
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlMovePcqiNxtOccasion */
 
 /**
@@ -1651,7 +1651,7 @@ PRIVATE S16 rgSCHTomUtlMovePriNxtOccasion(cell, ue, riCb)
 #ifdef LTE_ADV
    rgSCHUtlSCellHndlRiCollsn(riCb);
 #endif
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlMovePriNxtOccasion */
 
 /**
@@ -1707,7 +1707,7 @@ PRIVATE S16 rgSCHTomUtlMoveSrNxtOccasion(cell, ue)
    cmLListAdd2Tail(&cell->pCqiSrsSrLst[ue->srCb.nSrTrIdx].srLst, 
          &ue->srCb.srLstEnt);
 
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlMoveSrNxtOccasion */
 
 /**
@@ -1793,8 +1793,7 @@ PRIVATE S16 rgSCHTomUtlMoveSrsNxtOccasion(cell, ue)
    }   
    ue->srsCb.nSrsTrIdx = srsIdx;
    ue->srsCb.srsDist = srsDist; 
-
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlMoveSrsNxtOccasion */
 
 
@@ -1856,8 +1855,8 @@ PUBLIC S16 rgSCHTomRawCqiInd(cell, rawCqiInd)
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for cellId"
             ":%d", rawCqiInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
 
    node =  rawCqiInd->rawCqiRpt.first;
@@ -2070,7 +2069,7 @@ PUBLIC S16 rgSCHTomRawCqiInd(cell, rawCqiInd)
          rlsHqBufs->numUes = 0;
       }
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomRawCqiInd */
 
 /**
@@ -2117,8 +2116,8 @@ PUBLIC S16 rgSCHTomSrsInd(cell, srsInd)
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for cellId"
          ":%d", srsInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
    node =  srsInd->srsRpt.first;
    for (;node; node=node->next)
@@ -2134,7 +2133,7 @@ PUBLIC S16 rgSCHTomSrsInd(cell, srsInd)
       rgSCHUtlSrsInd(cell, ue, srsInfo, srsInd->timingInfo);
       rgSCHUtlHdlUlTransInd(cell, ue, srsInd->timingInfo);
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomSrsInd */
 
 /*
@@ -2194,7 +2193,7 @@ PRIVATE S16 rgSCHTomUtlGenIndices(label, posM, valN, valK, sbInfo)
       xmin = idx+1;
       label = label-binCoe;
    }
-   RETVALUE(ROK);
+   return ROK;
 } /* end of rgSCHTomUtlGenIndices*/
 #endif
 #endif 
@@ -2263,8 +2262,8 @@ TfuCrcIndInfo *crcInd;
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for cellId"
          ":%d", crcInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 #ifdef RG_ULSCHED_AT_CRC
 #ifndef LTE_ADV
    {
@@ -2440,7 +2439,7 @@ TfuCrcIndInfo *crcInd;
       {
          RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate TfuCntrlReqInfo "
                "for cell");
-         RETVALUE(ret);
+         return ret;
       }
       rgSCHCmnUlSch(cell);
 #ifdef LTE_L2_MEAS
@@ -2454,10 +2453,10 @@ TfuCrcIndInfo *crcInd;
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"rgSCHTomCrcInd() Unable to process"
                   " downlink subframe for cellId %d", crcInd->cellId);
          err.errType = RGSCHERR_TOM_TTIIND;
-         RETVALUE(RFAILED);
-      }
+         return RFAILED;
+               }
 #endif /* RG_ULSCHED_AT_CRC */
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomCrcInd */
 
 /**
@@ -2505,8 +2504,8 @@ TfuTimingAdvIndInfo *timingAdvInd;
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to get the cell for cellId"
          "=(%d)", timingAdvInd->cellId);
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
 
    node =  timingAdvInd->timingAdvLst.first;
@@ -2522,7 +2521,7 @@ TfuTimingAdvIndInfo *timingAdvInd;
       }
       rgSCHDhmUpdTa (cell, ue, timingAdvInfo->timingAdv);
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomTimingAdvInd */
 
 /**
@@ -2885,7 +2884,7 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate TfuRecpReqInfo "
          "for cell");
       err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-      RETVALUE(ret);
+      return ret;
    }    
    recpReqInfo->cellId = cell->cellId;
    cmLListInit(&recpReqInfo->ueRecpReqLst);
@@ -2902,7 +2901,7 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to fill Data recption "
          "requests for cell");
       RGSCH_FREE_MEM(recpReqInfo);
-      RETVALUE(ret);
+      return ret;
    } 
    /* Filling HARQ Reception requests */
    ret = rgSCHTomUtlFillHqFdbkRecpReq (recpReqInfo, cell, validIdx,err);
@@ -2911,14 +2910,14 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to fill Harq Feedback "
          "reception requests for cell");
       RGSCH_FREE_MEM(recpReqInfo);
-      RETVALUE(ret);
+      return ret;
    }
    /* sending the RecpReq to Phy */
    if (rgSCHUtlTfuRecpReq(inst, cell->tfuSap->sapCfg.suId, recpReqInfo) != ROK)
    {
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to send Cntrl info for cell");
    }
-   RETVALUE(ROK);
+   return ROK;
 } /* end of rgSCHTomUtlProcUlSf */ 
 
 #ifdef LTE_TDD
@@ -2966,7 +2965,7 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"rgSCHTomUtlPrcUlTddSpclSf() Unable to "
                "Allocate TfuRecpReqInfo for cell");
       err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-      RETVALUE(ret);
+      return ret;
    }    
    recpReqInfo->cellId = cell->cellId;
    cmLListInit(&recpReqInfo->ueRecpReqLst);
@@ -2993,7 +2992,7 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"rgSCHTomUtlPrcUlTddSpclSf() Unable to fill"
             " SRS recption requests for cell");;
       RGSCH_FREE_MEM(recpReqInfo);
-      RETVALUE(ret);
+      return ret;
    }
    /* sending the RecpReq to Phy */
    if (rgSCHUtlTfuRecpReq(inst, cell->tfuSap->sapCfg.suId, recpReqInfo) != ROK)
@@ -3001,7 +3000,7 @@ RgSchErrInfo       *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"rgSCHTomUtlPrcUlTddSpclSf() Unable to send "
                                "Cntrl info for cell");
    }
-   RETVALUE(ROK);
+   return ROK;
 } /* end of rgSCHTomUtlPrcUlTddSpclSf */ 
 #endif
 #endif
@@ -3084,7 +3083,7 @@ RgSchErrInfo         *err;
             RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to send PHICH info "
                      "for cellId (%d)\n", cell->cellId));
             RGSCH_FREE_MEM(cntrlInfo);
-            RETVALUE(ret);
+            return ret;
          }
          if ((ret = rgSCHTomUtlFillUlPdcch (cell, cntrlInfo, ulSf, err)) != 
                         ROK)
@@ -3092,7 +3091,7 @@ RgSchErrInfo         *err;
             RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to send PDCCH info "
                      "for cellId (%d)\n", cell->cellId));
             RGSCH_FREE_MEM(cntrlInfo);
-            RETVALUE(ret);
+            return ret;
          }
       }
 #ifdef EMTC_ENABLE
@@ -3114,7 +3113,7 @@ RgSchErrInfo         *err;
             RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to send PDCCH info "
                      "for cellId (%d)\n", cell->cellId));
             RGSCH_FREE_MEM(cntrlInfo);
-            RETVALUE(ret);
+            return ret;
          }
          rgBwAlloInfo[dlSf->sfNum] += dlSf->bwAssigned;
          rgBwAlcnt[dlSf->sfNum] ++;
@@ -3139,8 +3138,8 @@ if(0 == cntrlInfo->dlMpdcchLst.count)
          RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to send Cntrl info "
             "for cell");
       }
+   return ROK;
 
-   RETVALUE(ROK);
 } 
 
 
@@ -3197,7 +3196,7 @@ RgSchErrInfo       *err;
                                 &(cntrlInfo->memCp))) != ROK)
       {
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
       harqAck->txPower = 0;
@@ -3220,7 +3219,7 @@ RgSchErrInfo       *err;
       harqAck->lnk.node = (PTR)harqAck;
       node = node->next;
    } /* end of while */
-   RETVALUE(ret);
+   return ret;
 } /* end of */ 
 
 
@@ -3369,7 +3368,7 @@ RgSchErrInfo    *err;
                                 &(cntrlInfo->memCp))) != ROK)
       {
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
 #ifdef LTEMAC_SPS
       tfuPdcch->crnti       = pdcch->crnti;
@@ -3413,7 +3412,7 @@ RgSchErrInfo    *err;
          gDlNumUePerTti[numUePerTti-1]++;
       }
    }
-   RETVALUE(ret);
+   return ret;
 } /* end of rgSCHTomUtlFillDlPdcch*/ 
 
 #ifdef RGSCH_SPS_STATS
@@ -3506,7 +3505,7 @@ RgSchErrInfo    *err;
                   &(cntrlInfo->memCp))) != ROK)
       {
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
       tfuPdcch->rnti       = pdcch->rnti;
 #ifdef LTE_ADV
@@ -3538,7 +3537,7 @@ RgSchErrInfo    *err;
      //   abort();
    }
 #endif
-   RETVALUE(ret);
+   return ret;
 } /* end of rgSCHTomUtlFillUlPdcch*/ 
 
 /** @brief This function does the processing for Timing adjustment.
@@ -3605,8 +3604,7 @@ RgSchCellCb    *cell;
          ue->dl.taCb.numRemSf--;
       }
    } /* end of taUeLst */
-
-   RETVALUE(ROK);
+   return ROK;
 } /* end of rgSCHTomUtlProcTA */ 
 
 /** @brief This function handles filling of Hq reception request to
@@ -3719,7 +3717,7 @@ RgSchErrInfo            *err;
                RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
                         "TfuUeRecpReqInfo for cell");
                err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-               RETVALUE(ret);
+               return ret;
             }
             pucchRecpInfo->type = TFU_RECP_REQ_PUCCH;
             if ((hqCb->hqE->ue != NULLP) /*&& 
@@ -3818,7 +3816,7 @@ RgSchErrInfo            *err;
          break;
       }
    }
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillHqFdbkInfo */
 
 #ifdef RG_5GTF 
@@ -3869,17 +3867,15 @@ PRIVATE S16 rgSCHTomUtlFillHqFdbkFor5gtf (recpReqInfo, cell, validIdx, hqCb, dlS
    Inst                 inst = cell->instIdx;
 #endif
    S16                  ret;
-   CmLList              *hqPNode;
    RgSchUeCb            *ue;
    TfuUePucchRecpReq    *pucchReqInfo = NULLP;
 
-   hqPNode = dlSfHqInfo->hqPLst.first;
    ue = (RgSchUeCb*)dlSfHqInfo->dlSfUeLnk.node;
    
    if (ue == NULLP)
    {
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
    ret = rgSCHUtlGetEventMem((Ptr *)&pucchRecpInfo,
          sizeof(TfuUeRecpReqInfo), &(recpReqInfo->memCp));
    if (ret != ROK)
@@ -3887,7 +3883,7 @@ PRIVATE S16 rgSCHTomUtlFillHqFdbkFor5gtf (recpReqInfo, cell, validIdx, hqCb, dlS
       RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to Allocate "
                "TfuUeRecpReqInfo for cellId=%d \n", cell->cellId));
       err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-      RETVALUE(ret);
+      return ret;
    }
    pucchRecpInfo->type = TFU_RECP_REQ_PUCCH;
    pucchRecpInfo->rnti = ue->ueId; /* Even for Rel pdcch also setting CRNTI
@@ -3912,7 +3908,7 @@ PRIVATE S16 rgSCHTomUtlFillHqFdbkFor5gtf (recpReqInfo, cell, validIdx, hqCb, dlS
    
    cmLListAdd2Tail(&recpReqInfo->ueRecpReqLst, &(pucchRecpInfo->lnk));
    pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillHqFdbkForFrmt1B */
 #endif
 
@@ -3999,8 +3995,8 @@ RgSchErrInfo            *err;
    
    if (ue == NULLP)
    {
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
    ret = rgSCHUtlGetEventMem((Ptr *)&pucchRecpInfo,
          sizeof(TfuUeRecpReqInfo), &(recpReqInfo->memCp));
    if (ret != ROK)
@@ -4008,7 +4004,7 @@ RgSchErrInfo            *err;
       RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to Allocate "
                "TfuUeRecpReqInfo for cellId=%d \n", cell->cellId));
       err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-      RETVALUE(ret);
+      return ret;
    }
    pucchRecpInfo->type = TFU_RECP_REQ_PUCCH;
    pucchRecpInfo->rnti = ue->ueId; /* Even for Rel pdcch also setting CRNTI
@@ -4245,7 +4241,7 @@ RgSchErrInfo            *err;
 #endif/*TFU_UPGRADE*/
    cmLListAdd2Tail(&recpReqInfo->ueRecpReqLst, &(pucchRecpInfo->lnk));
    pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillHqFdbkForFrmt1B */
 /** @brief This function handles filling of Hq reception request to
  *   Per Hq Proc.
@@ -4326,8 +4322,8 @@ RgSchErrInfo            *err;
    
    if (ue == NULLP)
    {
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
    ret = rgSCHUtlGetEventMem((Ptr *)&pucchRecpInfo,
          sizeof(TfuUeRecpReqInfo), &(recpReqInfo->memCp));
    if (ret != ROK)
@@ -4335,7 +4331,7 @@ RgSchErrInfo            *err;
       RGSCHDBGERRNEW(inst,(rgSchPBuf(inst),"Unable to Allocate "
                "TfuUeRecpReqInfo for cellId=%d \n", cell->cellId));
       err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-      RETVALUE(ret);
+      return ret;
    }
    pucchRecpInfo->type = TFU_RECP_REQ_PUCCH;
    pucchRecpInfo->rnti = ue->ueId; /* Even for Rel pdcch also setting CRNTI
@@ -4366,7 +4362,7 @@ RgSchErrInfo            *err;
 #endif/*TFU_UPGRADE*/
    cmLListAdd2Tail(&recpReqInfo->ueRecpReqLst, &(pucchRecpInfo->lnk));
    pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillHqFdbkForFrmt3 */
 
 #endif/*LTE_ADV*/
@@ -4481,7 +4477,7 @@ RgSchErrInfo            *err;
 
    /* Check with TDD Code */
    /* FOR ACK NACK REP */
-   RETVALUE(ROK);
+   return ROK;
 } /* end of rgSCHTomUtlFillHqFdbkRecpReq */ 
 #ifdef TFU_UPGRADE 
 /** @brief This function handles filling of SR reception request to
@@ -4548,7 +4544,7 @@ PRIVATE S16 rgSCHTomUtlFillSrRecpReq (recpReqInfo, cell, validIdx, err)
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
             "TfuUeRecpReqInfo for cell RNTI:%d",ue->ueId);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
      cmMemset((U8 *)&pucchRecpInfo->t.pucchRecpReq, 0, sizeof(TfuUePucchRecpReq));
@@ -4587,7 +4583,7 @@ PRIVATE S16 rgSCHTomUtlFillSrRecpReq (recpReqInfo, cell, validIdx, err)
       }
       pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
    }
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillSrRecpReq */
 #endif
 #endif
@@ -4635,8 +4631,8 @@ PRIVATE S16 rgSCHTomUtlWillUeRprtCqiRi ( ue, willueRprtCqiRi)
          {/*onDuration NOT running, do not expect cqi/pmi/ri*/
             *willueRprtCqiRi = FALSE;
          }
-         RETVALUE(ROK);
-      }
+         return ROK;
+               }
 #endif /*end of LTEMAC_R9*/
       /* ccpu00134258: Fix for CQI DRX issue*/
       if(ue->drxCb->onDurTmrLen > 2)
@@ -4647,8 +4643,7 @@ PRIVATE S16 rgSCHTomUtlWillUeRprtCqiRi ( ue, willueRprtCqiRi)
          }
       }
    }/*ue->isDrxEnabled*/
-   
-   RETVALUE(ROK);
+   return ROK; 
 } /*End of rgSCHTomUtlWillUeRprtCqiRi*/
 
 /** @brief This function handles filling of RI reception request to
@@ -4735,7 +4730,7 @@ PRIVATE S16 rgSCHTomUtlFillRiRecpReq (recpReqInfo, cell, validIdx, err)
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
                "TfuUeRecpReqInfo for cell RNTI:%d",ue->ueId);
             err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-            RETVALUE(ret);
+            return ret;
          }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
          cmMemset((U8 *)&pucchRecpInfo->t.pucchRecpReq, 0, sizeof(TfuUePucchRecpReq));
@@ -4770,7 +4765,7 @@ PRIVATE S16 rgSCHTomUtlFillRiRecpReq (recpReqInfo, cell, validIdx, err)
          riCb->riDist--; 
       }     
    }
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillRiRecpReq */
 #endif
 #ifdef RG_5GTF
@@ -4825,7 +4820,7 @@ PRIVATE S16 rgSCHTomUtlFillCqiRiRecpReq (recpReqInfo, cell, validIdx, err)
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
                "TfuUeRecpReqInfo for cell RNTI:%d ", ue->ueId);
             err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-            RETVALUE(ret);
+            return ret;
          }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
          cmMemset((U8 *)&pucchRecpInfo->t.pucchRecpReq, 0, sizeof(TfuUePucchRecpReq));
@@ -4842,8 +4837,7 @@ PRIVATE S16 rgSCHTomUtlFillCqiRiRecpReq (recpReqInfo, cell, validIdx, err)
          pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
       }
    }
-
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillCqiRiRecpReq */
 #endif
 #endif
@@ -4933,7 +4927,7 @@ PRIVATE S16 rgSCHTomUtlFillPcqiRecpReq (recpReqInfo, cell, validIdx, err)
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
             "TfuUeRecpReqInfo for cell RNTI:%d ", ue->ueId);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
       cmMemset((U8 *)&pucchRecpInfo->t.pucchRecpReq, 0, sizeof(TfuUePucchRecpReq));
@@ -4960,7 +4954,7 @@ PRIVATE S16 rgSCHTomUtlFillPcqiRecpReq (recpReqInfo, cell, validIdx, err)
       }
       pucchRecpInfo->lnk.node = (PTR)pucchRecpInfo;
    }
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillPcqiRecpReq */
 /** @brief This function handles filling of SRS reception request to
  * PHY.
@@ -5026,7 +5020,7 @@ PRIVATE S16 rgSCHTomUtlFillSrsRecpReq (recpReqInfo, cell, validIdx, err)
             RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
                "TfuUeRecpReqInfo for RNTI:%d ",ue->ueId);
             err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-            RETVALUE(ret);
+            return ret;
          }
 
 #ifdef TFU_ALLOC_EVENT_NO_INIT
@@ -5058,7 +5052,7 @@ PRIVATE S16 rgSCHTomUtlFillSrsRecpReq (recpReqInfo, cell, validIdx, err)
          ue->srsCb.srsDist--; 
       }
    }
-   RETVALUE(ROK);
+   return ROK;
 }/* end of rgSCHTomUtlFillSrsRecpReq */
 #endif 
 #ifndef TFU_UPGRADE
@@ -5124,7 +5118,7 @@ RgSchErrInfo         *err;
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
             "TfuUeRecpReqInfo for RNTI:%d ", alloc->ue->ueId);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
       if (!alloc->forMsg3)
       {
@@ -5169,7 +5163,7 @@ RgSchErrInfo         *err;
       
       alloc = rgSCHUtlNextRcptnReq (cell, alloc);
    } /* end of while */
-   RETVALUE(ROK); 
+   return ROK;
 } /* end of rgSCHTomUtlFillDatRecpReq */
 
 #else
@@ -5212,7 +5206,6 @@ PRIVATE S16 rgSCHTomUtlFillDatRecpReq (recpReqInfo, cell, validIdx, err)
    RgSchUlAlloc      *alloc;
    TfuUeRecpReqInfo  *datRecpInfo;
 
-   Bool              hqPres;   /*Set when HARQ Rec Req is present*/
    Bool              isAperiodic = FALSE; /*Set when Aperiodic CQI is expected */
    U8                numUePerTti = 0;
 
@@ -5238,15 +5231,13 @@ PRIVATE S16 rgSCHTomUtlFillDatRecpReq (recpReqInfo, cell, validIdx, err)
          RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Allocate "
             "TfuUeRecpReqInfo for RNTI:%d ", alloc->rnti);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
 #ifdef TFU_ALLOC_EVENT_NO_INIT
       datRecpInfo->t.puschRecpReq.initialNSrs.pres = FALSE;
       datRecpInfo->t.puschRecpReq.initialNumRbs.pres = FALSE;
 #endif
       datRecpInfo->type = TFU_RECP_REQ_PUSCH;
-      /* ccpu00131944 - Intializing hqPres in each iteration*/
-      hqPres = FALSE;
       /* Check if this if for MSG3 - no scope for feedback along with it. */
       if ((FALSE == alloc->forMsg3))
       {
@@ -5306,7 +5297,7 @@ PRIVATE S16 rgSCHTomUtlFillDatRecpReq (recpReqInfo, cell, validIdx, err)
       cell->ulNumUeSchedPerTti[numUePerTti-1]++;
       gUlNumUePerTti[numUePerTti - 1]++;
    }
-   RETVALUE(ROK); 
+   return ROK;
 } /* end of rgSCHTomUtlFillDatRecpReq */
 #endif
 /* rg009.201. Added changes of TFU_UPGRADE */
@@ -5342,8 +5333,8 @@ PUBLIC S16 rgSCHTomUtlFillRiBitWidthInfo(ueCb)
    if (ueCb->mimoInfo.txMode != RGR_UE_TM_3 &&
              ueCb->mimoInfo.txMode != RGR_UE_TM_4)
    {
-      RETVALUE(RFAILED);
-   }
+      return RFAILED;
+       }
 
    ueCb->rawCqiBitW[ueCb->cqiRiWritIdx].type = TFU_RECP_REQ_PUCCH;
    ueCb->rawCqiBitW[ueCb->cqiRiWritIdx].u.pucch.pucchRawCqiInfo.mode= 
@@ -5375,7 +5366,7 @@ PUBLIC S16 rgSCHTomUtlFillRiBitWidthInfo(ueCb)
    }
    
    RG_SCH_INCR_CQIRI_INDEX(ueCb->cqiRiWritIdx);
-   RETVALUE(ROK);
+   return ROK;
 }
 
 /***********************************************************
@@ -5525,7 +5516,7 @@ PUBLIC U8 rgSCHTomUtlFetchPcqiBitSz(ueCb, numTxAnt, ri)
    }
    
    RG_SCH_INCR_CQIRI_INDEX(ueCb->cqiRiWritIdx);
-   RETVALUE(pcqiSz);
+   return pcqiSz;
 }
 
 
@@ -5577,7 +5568,7 @@ PUBLIC S16 rgSCHTomUtlPcqiSbCalcBpIdx(crntTimInfo, ueCb, cqiCb)
       cqiCb->prioLvl = RG_SCH_CQI_PRIO_LVL_0;
 #endif
    }
-   RETVALUE(ROK);
+   return ROK;
 }
 
 
@@ -5676,7 +5667,7 @@ PUBLIC S16 rgSCHTomUtlMoveNxtOccasion(cell, ue, validIdx)
    {
       rgSCHTomUtlMoveSrNxtOccasion(cell, ue); 
    }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlMoveNxtOccasion */
 
 
@@ -5971,7 +5962,7 @@ PUBLIC S16 rgSCHTomUtlFillDatAperRecpReq(cell, cqiReq, alloc, datRecpInfo, timeI
    datRecpInfo->rnti = alloc->rnti;
    rgSCHUtlAllocRcptInfo (cell, alloc, timeInfo,
             &datRecpInfo->t.puschRecpReq.ulSchInfo);
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillDatAperRecpReq */
 
 
@@ -6067,7 +6058,7 @@ hqPres, validIdx)
    datRecpInfo->rnti = alloc->rnti;
    rgSCHUtlAllocRcptInfo (cell, alloc, timeInfo,
          &datRecpInfo->t.puschRecpReq.ulSchInfo);
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillDatPriRecpReq */
 
 
@@ -6137,7 +6128,7 @@ PUBLIC S16 rgSCHTomUtlFillDatPCqiRecpReq(cell, alloc, datRecpInfo,
    {
       RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"Unable to Fill "
          "CqiPmi size RNTI:%d",alloc->rnti);
-      RETVALUE(RFAILED);
+      return RFAILED;
    }
 
    /* Fill only the first RI index since Periodic can come 
@@ -6184,7 +6175,7 @@ PUBLIC S16 rgSCHTomUtlFillDatPCqiRecpReq(cell, alloc, datRecpInfo,
    datRecpInfo->rnti = alloc->rnti;
    rgSCHUtlAllocRcptInfo (cell, alloc, timeInfo,
             &datRecpInfo->t.puschRecpReq.ulSchInfo);
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillDatPCqiRecpReq */
 
 /**
@@ -6246,7 +6237,7 @@ PUBLIC S16 rgSCHTomUtlFillDatSrsRecpReq(cell, alloc, datRecpInfo, timeInfo,
    datRecpInfo->rnti = alloc->rnti;
    rgSCHUtlAllocRcptInfo (cell, alloc, timeInfo, 
             &datRecpInfo->t.puschRecpReq.ulSchInfo);
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillDatSrsRecpReq */
 
 /**
@@ -6302,7 +6293,7 @@ PUBLIC S16 rgSCHTomFillOnlySrsRecpReq(cell, alloc, datRecpInfo)
     * Refer Section 5.2.2.6 of TS 36.212 V8.5.0*/
    datRecpInfo->t.puschRecpReq.ulSchInfo.nSrs = 1;
 
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomFillOnlySrsRecpReq */
 
 /**
@@ -6541,7 +6532,7 @@ Bool              isDatPresOnSecCell;
             {
                RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"RNTI:%d "
                   "Unable to Fill CqiPmi size", ue->ueId);
-               RETVALUE(RFAILED);
+               return RFAILED;
             }
             if(pucchRecpInfo->t.pucchRecpReq.uciInfo == TFU_PUCCH_HARQ_SR)
             {
@@ -6625,7 +6616,7 @@ Bool              isDatPresOnSecCell;
       }
    }            
    UNUSED(dropCqi);
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillCqiSrSrsWithHq */
 
 /**
@@ -6752,8 +6743,8 @@ U16               validIdx;
             {
                RLOG_ARG1(L_ERROR,DBG_CELLID,cell->cellId,"RNTI:%d"
                   " Unable to Fill CqiPmi size", ue->ueId);
-               RETVALUE(RFAILED);
-            }
+               return RFAILED;
+                               }
 
             pucchRecpInfo->t.pucchRecpReq.uciInfo = TFU_PUCCH_SR_CQI;
          }
@@ -6814,7 +6805,7 @@ U16               validIdx;
 
          }
       }
-   RETVALUE(ROK);
+   return ROK;
 }  /* rgSCHTomUtlFillCqiSrsWithSr */
 
 #endif 
@@ -6950,7 +6941,7 @@ noFdbks, memCp, elemIdx, nxtDlsf)
             RLOG_ARG1(L_ERROR,DBG_CELLID,cellCb->cellId,"Unable to"
                "Allocate TfuUeRecpReqInfo for RNTI:%d ", ueCb->ueId);
             err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-            RETVALUE(ret);
+            return ret;
          }
          pucchRecpInfo->rnti    =  ueCb->ueId;
 #ifndef TFU_UPGRADE
@@ -7000,8 +6991,7 @@ noFdbks, memCp, elemIdx, nxtDlsf)
       /* Go to the next node */
       node = node->next;
    }
-
-   RETVALUE(ROK);
+   return ROK;
 }
 
 /** @brief This function handles filling of HARQ feedback recption request
@@ -7135,8 +7125,8 @@ RgSchDlHqProcCb         *prvHqCb;
                if((anInfo == NULLP) || 
                      (anInfo->latestMIdx != dlSf->dlFdbkInfo.m))
                {
-                  RETVALUE(ROK);
-               }
+                                          return ROK; 
+                                       }
             }
             else
             {
@@ -7158,7 +7148,7 @@ RgSchDlHqProcCb         *prvHqCb;
          }
          else
          {
-            RETVALUE(ROK);
+                          return ROK;
          }
 
          /* Do not proceed if PUSCH
@@ -7197,7 +7187,7 @@ RgSchDlHqProcCb         *prvHqCb;
                   n1PucchTkn, &alloc, hqSz);
             if (ret != ROK)
             {
-               RETVALUE(ret);
+               return ret;
             }
             /* TODO:: In case of F1BCS and CSI in same subframe
              * UE shall drop the CSI if there was at least one 
@@ -7277,7 +7267,7 @@ RgSchDlHqProcCb         *prvHqCb;
          prvHqCb = hqCb;
       }
    }
-   RETVALUE(ROK);
+   return ROK;
 }
 
 #ifdef LTE_ADV
@@ -7796,7 +7786,7 @@ PRIVATE S16 rgSCHTomUtlFillSfHqFdbkForFrmt1BCS(hqCb,hqRecpReq,noFdbks,dlSf,pdcch
       default:
          break;
    }
-   RETVALUE(ROK);
+   return ROK;
 }
 #endif
 
@@ -7883,7 +7873,7 @@ U8                      hqSz;
          RLOG_ARG1(L_ERROR,DBG_CELLID,cellCb->cellId,"Unable to "
             "Allocate TfuUeRecpReqInfo for cell RNTI:%d",rnti);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
       alloc = TRUE;
 #ifdef TFU_ALLOC_EVENT_NO_INIT
@@ -7898,7 +7888,7 @@ U8                      hqSz;
          RLOG_ARG1(L_ERROR,DBG_CELLID,cellCb->cellId,"Unable to "
             "Allocate TfuUeRecpReqInfo for cell RNTI:%d",rnti);
          err->errCause = RGSCHERR_TOM_MEM_EXHAUST;
-         RETVALUE(ret);
+         return ret;
       }
       cmMemset((U8 *)pucchInfo->pucchRecpInfo->t.pucchRecpReq.hqInfo.hqRes,0xff,sizeof(U16)*TFU_MAX_HQ_RES);
 #ifdef TFU_ALLOC_EVENT_NO_INIT
@@ -7963,8 +7953,7 @@ U8                      hqSz;
                     because of kworks*/
                    RGSCHDBGERRNEW(cellCb->instIdx,(rgSchPBuf(cellCb->instIdx),
                             "ANInfo should not be NULL for cellId=%d \n", cellCb->cellId));
-                   RETVALUE(RFAILED);
-
+                   return RFAILED;
                 }
 #endif
              }
@@ -7973,7 +7962,7 @@ U8                      hqSz;
        {/* This needs to be revisited while
            adding support for PUCCH format 3 */
           RGSCHDBGERRNEW(cellCb->instIdx,(rgSchPBuf(cellCb->instIdx),"Invalid Pucch format configured.."));
-          RETVALUE(RFAILED);
+          return RFAILED;
        }
     }
     else
@@ -8125,7 +8114,7 @@ U8                      hqSz;
 
    *pucchInfoRef = pucchInfo;
    *allocRef     = alloc;
-   RETVALUE(ROK);
+   return ROK;
 }
 #endif
 
@@ -8190,7 +8179,7 @@ RgSchErrInfo         *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to send PHICH info for "
             "cell");
       RGSCH_FREE_MEM(cntrlInfo);
-      RETVALUE(ret);
+      return ret;
    }
 
    /* Fill UL Pdcch */
@@ -8199,7 +8188,7 @@ RgSchErrInfo         *err;
       RLOG_ARG0(L_ERROR,DBG_CELLID,cell->cellId,"Unable to send PDCCH info for "
             "cell");
       RGSCH_FREE_MEM(cntrlInfo);
-      RETVALUE(ret);
+      return ret;
    }
    
 #ifdef EMTC_ENABLE
@@ -8226,8 +8215,7 @@ RgSchErrInfo         *err;
    {
       RGSCH_FREE_MEM(cntrlInfo);
    }
-
-   RETVALUE(ROK);
+   return ROK;
 } /* end of */ 
 #endif /* #ifdef RG_ULSCHED_AT_CRC*/
 
index cbf4598..9199920 100755 (executable)
@@ -617,7 +617,7 @@ RgSchPdcch                 *pdcch;
 {
    U8                   *byte;
    U8                   offset;
-   U8                   mask;
+   uint16_t             mask;
 
    TRC2(rgSCHUtlPdcchPut);
 
@@ -7128,7 +7128,7 @@ U8            status;
 #endif
 {
    Pst cfmPst;
-   Inst inst;
+   Inst inst = 0;
 
    TRC2(schSendCfgCfm)
    cmMemset((U8 *)(&cfmPst), 0, sizeof(Pst));
@@ -7145,7 +7145,7 @@ U8            status;
 
    if(RgUiRgrCfgCfm(&cfmPst,transId, status) != ROK)
    {
-      RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"schSendCfgCfm: RgUiRgrCfgCfm Failed ");
+      RLOG_ARG0(L_ERROR,DBG_INSTID,inst,"schSendCfgCfm: RgUiRgrCfgCfm Failed");
       printf("\nschSendCfgCfm: RgUiRgrCfgCfm Failed ");
       RETVALUE(RFAILED);
    }
index f419209..f4b57b2 100644 (file)
@@ -66,7 +66,7 @@
    _rspPst.dstInst   = 0;\
        _rspPst.selector  = MAC_SELECTOR_TC;\
 }      
-
+extern int schProcessRachInd(RachIndInfo *rachInd, Inst schInst);
 /**
   * @brief
   * Structure holding LTE MAC's General Configuration information.
index abca278..6ff50ac 100644 (file)
@@ -80,7 +80,7 @@ void createSchRaCb(uint16_t tcrnti, Inst schInst)
        schCb[schInst].cells[schInst]->raCb[0].tcrnti = tcrnti;
 }
 
-uint8_t schProcessRachInd(RachIndInfo *rachInd, Inst schInst)
+int schProcessRachInd(RachIndInfo *rachInd, Inst schInst)
 {
    SchCellCb *cell = schCb[schInst].cells[schInst];
 
@@ -132,7 +132,7 @@ uint8_t schProcessRachInd(RachIndInfo *rachInd, Inst schInst)
    return ROK;
 }
 
-uint8_t schFillRar(RarAlloc *rarAlloc, uint16_t raRnti, uint16_t pci, uint8_t offsetPointA)
+int  schFillRar(RarAlloc *rarAlloc, uint16_t raRnti, uint16_t pci, uint8_t offsetPointA)
 {
    uint8_t coreset0Idx = 0;
    uint8_t searchSpace0Idx = 0;
index f0d539f..4ffbdcd 100644 (file)
@@ -69,7 +69,8 @@ SchMacDlAllocFunc schMacDlAllocOpts[] =
 };
 
 extern SchCb schCb[SCH_MAX_INST];
-
+extern int schFillRar(RarAlloc *rarAlloc, uint16_t raRnti, uint16_t pci, uint8_t
+offsetPointA);
 
 /*******************************************************************
  *
index d7d56fe..58257ee 100755 (executable)
@@ -221,7 +221,7 @@ Buffer *mBuf;
 
    //CMCHKUNPK(SUnpkU16, &param->hSfn, mBuf);
    CMCHKUNPK(SUnpkU16, &param->sfn, mBuf);
-   CMCHKUNPK(SUnpkU8, &param->slot, mBuf);
+   CMCHKUNPK(SUnpkU16,&param->slot, mBuf);
    RETVALUE(ROK);
 }
 
index 1a00339..57068bb 100644 (file)
@@ -53,7 +53,7 @@
  *         RFAILED - failure
  *
  ***************************************************************************/
-uint16_t packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg)
+int  packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg)
 {
    if(pst->selector == DU_SELECTOR_LC)
    {
@@ -66,15 +66,16 @@ uint16_t packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg)
 
       if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) 
       {
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
 
       /* pack the address of the structure */
       CMCHKPK(cmPkPtr,(PTR)macCellCfg, mBuf);
 
       DU_LOG("\nDU-APP : MAC CELL config sent");
-      RETVALUE(SPstTsk(pst,mBuf));
+      return SPstTsk(pst,mBuf);
    } 
+   return ROK;
 }
 
 /**************************************************************************
@@ -95,7 +96,7 @@ uint16_t packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg)
  *         RFAILED - failure
  *
  ***************************************************************************/
-void unpackDuMacCellCfg(
+int  unpackDuMacCellCfg(
    DuMacCellCfgReq func,
    Pst *pst,
    Buffer *mBuf)
@@ -135,21 +136,21 @@ void unpackDuMacCellCfg(
  *         RFAILED - failure
  *
  ***************************************************************************/
-uint16_t packMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm)
+int  packMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm)
 {
    if(pst->selector == DU_SELECTOR_LC)
    {
       Buffer *mBuf = NULLP;
       if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) 
       {
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
 
       /* pack the transaction ID in CNF structure */
                CMCHKPK(SPkU8, macCellCfgCfm->rsp, mBuf);
       CMCHKPK(SPkU16, macCellCfgCfm->transId, mBuf);
 
-      RETVALUE(SPstTsk(pst,mBuf));
+      return SPstTsk(pst,mBuf);
    }
    else if(pst->selector == DU_SELECTOR_LWLC)
    {
@@ -176,7 +177,7 @@ uint16_t packMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm)
  *         RFAILED - failure
  *
  ***************************************************************************/
-uint16_t unpackMacCellCfgCfm(
+int unpackMacCellCfgCfm(
    DuMacCellCfgCfm func, 
    Pst *pst,
    Buffer *mBuf)
@@ -189,11 +190,12 @@ uint16_t unpackMacCellCfgCfm(
       CMCHKUNPK(SUnpkU16, &(macCellCfgCfm.transId), mBuf);
       CMCHKUNPK(SUnpkU8, &(macCellCfgCfm.rsp), mBuf);
 
-      RETVALUE((*func)(&macCellCfgCfm));
+      return (*func)(pst, &macCellCfgCfm);
    }
    else
    {
       /* only loose coupling is suported */
+               return ROK;
    }
 }
 
@@ -228,7 +230,7 @@ uint16_t packMacCellStartReq(Pst *pst, MacCellStartInfo  *cellStartInfo)
       if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK)
       {
          DU_LOG("\nDU APP : Memory allocation failed for cell start req pack");
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
 
       /* pack the address of the structure */
@@ -307,7 +309,7 @@ uint16_t packMacCellStopReq(Pst *pst, MacCellStopInfo  *cellStopInfo)
       if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK)
       {
          DU_LOG("\nDU APP : Memory allocation failed for cell stop req pack");
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
  
       /* pack the address of the structure */
@@ -387,7 +389,7 @@ uint16_t packMacSlotInd(Pst *pst, SlotInfo *slotInfo )
       if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK)
       {
          DU_LOG("\nDU APP : Memory allocation failed for cell start req pack");
-         RETVALUE(RFAILED);
+         return RFAILED;
       }
  
       /* pack the address of the structure */
index 40f2ab4..6bd2e1d 100644 (file)
@@ -253,26 +253,27 @@ extern uint16_t unpackMacCellStopReq(DuMacCellStopReq func, Pst *pst, Buffer *mB
 extern uint16_t MacHdlCellStopReq(Pst *pst, MacCellStopInfo  *cellStopInfo);
 
 /* Function pointers for packing macCellCfg Request and Confirm */
-typedef uint16_t (*packMacCellCfgReq) ARGS((
+typedef int (*packMacCellCfgReq) ARGS((
    Pst           *pst,
    MacCellCfg    *macCellCfg ));
 
-typedef uint16_t (*packMacCellCfgConfirm) ARGS((
+typedef int (*packMacCellCfgConfirm) ARGS((
    Pst              *pst,
    MacCellCfgCfm    *macCellCfgCfm ));
 
-typedef uint16_t (*DuMacCellCfgReq) ARGS((
+typedef int (*DuMacCellCfgReq) ARGS((
    Pst        *pst,        
    MacCellCfg *macCellCfg));
 
-typedef uint16_t (*DuMacCellCfgCfm) ARGS((
+typedef int (*DuMacCellCfgCfm) ARGS((
+   Pst        *pst,        
    MacCellCfgCfm *macCellCfgCfm ));
 
-extern uint16_t packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg);
+extern int  packMacCellCfg(Pst *pst, MacCellCfg *macCellCfg);
 extern int MacHdlCellCfgReq(Pst *pst, MacCellCfg *macCellCfg);
 extern void cmUnpackLwLcMacCellCfg(DuMacCellCfgReq func, Pst *pst, Buffer *mBuf);
-extern uint16_t unpackMacCellCfgCfm(DuMacCellCfgCfm func, Pst *pst, Buffer *mBuf);
-extern uint16_t duHandleMacCellCfgCfm(MacCellCfgCfm *macCellCfgCfm);
+extern int unpackMacCellCfgCfm(DuMacCellCfgCfm func, Pst *pst, Buffer *mBuf);
+extern int duHandleMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm);
 
 #endif
 
index 23323b7..bfa8834 100755 (executable)
@@ -653,7 +653,7 @@ EXTERN S16 RgMiLrgCfgReq ARGS((Pst *pst, RgMngmt *cfg));
   * @param cfm pointer to RgMngmt 
   * @return ROK/RFAILED
   */
-EXTERN S16 MacSchGenCfgReq ARGS((Pst *pst, RgMngmt *cfg));
+EXTERN int MacSchGenCfgReq ARGS((Pst *pst, RgMngmt *cfg));
 
  /** @brief This primitive carries the Confirmation for a Configuration Request
   * sent from the layer manager to MAC.
index 68286bb..01d44e9 100644 (file)
@@ -52,7 +52,7 @@ S16 cmPkSctpNtfy(Pst *pst, CmInetSctpNotification *ntfy)
    if(ntfy->header.nType == CM_INET_SCTP_ASSOC_CHANGE)
    {
       SPkU16(ntfy->u.assocChange.state, mBuf);
-      SPkU16(ntfy->u.assocChange.assocId, mBuf);
+      SPkU32(ntfy->u.assocChange.assocId, mBuf);
    }
    SPkU16(ntfy->header.nType, mBuf);
 
@@ -90,7 +90,7 @@ S16 cmUnpkSctpNtfy(SctpNtfy func, Pst *pst, Buffer *mBuf)
    SUnpkU16(&(ntfy.header.nType), mBuf);
    if(ntfy.header.nType == CM_INET_SCTP_ASSOC_CHANGE)
    {
-      SUnpkU16(&(ntfy.u.assocChange.assocId), mBuf);
+      SUnpkU32(&(ntfy.u.assocChange.assocId), mBuf);
       SUnpkU16(&(ntfy.u.assocChange.state), mBuf);
    }
 
index f764545..075f897 100755 (executable)
@@ -696,13 +696,13 @@ RlcMacData  *ulData;
 #ifdef ANSI
 PUBLIC S16 unpackRcvdUlData
 (
-RguDDatInd func,
+RguDDatInd            func,
 Pst *pst,
 Buffer *mBuf
 )
 #else
 PUBLIC S16 unpackRcvdUlData(func, pst, mBuf)
-RguDDatInd func;
+RguDDatInd      func;
 Pst *pst;
 Buffer *mBuf;
 #endif
index 9c4c13b..88c80f4 100755 (executable)
@@ -484,7 +484,7 @@ typedef S16 (*RguCDatInd) ARGS((
 typedef S16 (*RguDDatInd) ARGS((
    Pst*                 pst,
    SuId                 suId,
-   RguDDatIndInfo  *    datInd));
+   RlcMacData     *    datInd));
 /** @brief Status Response from RLC to MAC to 
  * inform the BO report for common channels */
 typedef S16 (*RguCStaRsp) ARGS((
@@ -508,7 +508,7 @@ typedef S16 (*RguCStaInd) ARGS((
 typedef S16 (*RguDStaInd) ARGS((
    Pst*                 pst,
    SuId                 suId,
-   RguDStaIndInfo  *    staInd));
+   RlcMacSchedRep  *    staInd));
 
 typedef S16 (*RguFlowCntrlIndInfo) ARGS((
    Pst                  *pst,
@@ -861,7 +861,7 @@ EXTERN S16 packRcvdUlData ARGS((
 /** @brief Data Indication from MAC to RLC to 
  * forward the data received for dedicated channels*/
 EXTERN S16 unpackRcvdUlData ARGS((
-   RguDDatInd           func,
+   RguDDatInd          func,
    Pst*                 pst,
    Buffer               *mBuf
 ));
index ad304ab..6e2c750 100755 (executable)
@@ -3673,8 +3673,8 @@ Buffer *mBuf
 //   (*func)(pst, suId, slotInd);
    (*func)(pst, slotInd);
    SPutSBuf(pst->region, pst->pool, (Data *)slotInd, sizeof(SlotIndInfo));
-   RETVALUE(ROK);
 #endif
+   return ROK;
 }
 
 \f
index 5f52c25..98f0023 100644 (file)
@@ -1,5 +1,29 @@
 #include "odu_common_codec.h"
 
+/*******************************************************************
+ *
+ * @brief Writes the encoded chunks into a buffer
+ *
+ * @details
+ *
+ *    Function : PrepFinalEncBuf
+ *
+ *    Functionality:Fills the encoded buffer
+ *
+ * @params[in] void *buffer,initial encoded data
+ * @params[in] size_t size,size of buffer
+ * @params[in] void *encodedBuf,final buffer
+ * @return ROK     - success
+ *         RFAILED - failure
+ *
+ * ****************************************************************/
+int PrepFinalEncBuf(const void *buffer, size_t size, void *encodedBuf)
+{
+   memcpy(encodedBuf + encBufSize, buffer, size);
+   encBufSize += size;
+   return 0;
+} /* PrepFinalEncBuf */
+
 /*******************************************************************
  *
  * @brief Builds PLMN ID 
index a428f27..9fefea4 100644 (file)
@@ -39,37 +39,13 @@ typedef struct PlmnIdentity
    uint8_t mnc[3];
 }Plmn;
 
+int PrepFinalEncBuf(const void *buffer, size_t size, void *encodedBuf);
 S16 buildPlmnId(Plmn plmn, OCTET_STRING_t *octe);
 S16 fillBitString(BIT_STRING_t *id, U8 unusedBits, U8 byteSize, U8 val);
 
 char encBuf[ENC_BUF_MAX_LEN];
 int  encBufSize;
 
-
-/*******************************************************************
- *
- * @brief Writes the encoded chunks into a buffer
- *
- * @details
- *
- *    Function : PrepFinalEncBuf
- *
- *    Functionality:Fills the encoded buffer
- *
- * @params[in] void *buffer,initial encoded data
- * @params[in] size_t size,size of buffer
- * @params[in] void *encodedBuf,final buffer
- * @return ROK     - success
- *         RFAILED - failure
- *
- * ****************************************************************/
-static int PrepFinalEncBuf(const void *buffer, size_t size, void *encodedBuf)
-{
-   memcpy(encodedBuf + encBufSize, buffer, size);
-   encBufSize += size;
-   return 0;
-} /* PrepFinalEncBuf */
-
 #endif
 
 /**********************************************************************
index a89d1f0..9321ee6 100644 (file)
@@ -19,8 +19,6 @@
 #include "du_mgr_main.h"
 #include "GlobalE2node-gNB-ID.h"
 
-#define ENC_BUF_MAX_LEN 100
-
 /* Global variable */
 DuCfgParams duCfgParam;
 
@@ -277,7 +275,7 @@ S16 BuildRicAdmitList(RICaction_Admitted_List_t *admitListPtr)
       return RFAILED;
    }
    DU_ALLOC(admitListPtr->list.array[0], sizeof(RICaction_Admitted_ItemIEs_t));
-   fillRicAdmitList(admitListPtr->list.array[0]);
+   fillRicAdmitList((RICaction_Admitted_ItemIEs_t *)admitListPtr->list.array[0]);
 
    return ROK;
 }
@@ -519,7 +517,7 @@ S16 procRicSubsReq(E2AP_PDU_t *e2apMsg)
             aper_decode(0, &asn_DEF_RICeventTriggerDefinition, (void **)&ricReqDb.ricEventTrigger, &(ricSubsReq->protocolIEs.list.array[idx]->value.choice.RICsubscriptionDetails.ricEventTriggerDefinition), recvBufLen, 0, 0);
             xer_fprint(stdout, &asn_DEF_RICeventTriggerDefinition, &ricReqDb.ricEventTrigger);
 
-            actionItem = *ricSubsReq->protocolIEs.list.array[idx]->value.choice.RICsubscriptionDetails.ricAction_ToBeSetup_List.list.array;
+            actionItem =(RICaction_ToBeSetup_ItemIEs_t *) ricSubsReq->protocolIEs.list.array[idx]->value.choice.RICsubscriptionDetails.ricAction_ToBeSetup_List.list.array[0];
             
             for(ied = 0; ied < ricSubsReq->protocolIEs.list.array[idx]->value.choice.\
                                 RICsubscriptionDetails.ricAction_ToBeSetup_List.list.count; ied++)
index ef19839..d6b53f0 100644 (file)
@@ -24,6 +24,7 @@
 #include "E2AP-PDU.h"
 #include "PLMN-IdentityE2.h"
 #include "RICeventTriggerDefinition.h"
+#include "odu_common_codec.h"
 
 #include "envopt.h"        /* Environment options */
 #include "envdep.h"        /* Environment dependent */
@@ -41,6 +42,7 @@
 #include "ss_msg.x"
 
 #include "du_log.h"
+
 #define ENCODE_FAIL -1
 
 S16 sctpSend(Buffer *mBuf, U8 itfType);
index 068b728..bc6d94b 100644 (file)
@@ -1586,7 +1586,7 @@ S16 duBuildAndSendMacCellCfg()
  *         RFAILED - failure
  *
  ***************************************************************************/
-uint16_t duHandleMacCellCfgCfm(MacCellCfgCfm *macCellCfgCfm)
+int  duHandleMacCellCfgCfm(Pst *pst, MacCellCfgCfm *macCellCfgCfm)
 {
    S16 ret = ROK;
 
index e964900..fc087db 100644 (file)
@@ -192,9 +192,8 @@ S16 l1BldAndSndConfigRsp(void *msg)
       handlePhyMessages(fapiConfigRsp->header.message_type_id, sizeof(fapi_config_resp_t), (void *)fapiConfigRsp);
       return ROK;
    }
-#else
-   return ROK;
 #endif
+   return ROK;
 }
 /*******************************************************************
  *
index 8e79dba..1db65f4 100644 (file)
@@ -36,6 +36,7 @@ void *GenerateTicks(void *arg)
       l1BuildAndSendSlotIndication();
       counter--;
    }
+   return((void *)NULLP);
 }
 
 void duStartSlotIndicaion()