X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2Fcm%2Frgm.c;h=2804c43aab3c88d39802e8a828775f44d33c7661;hb=904a5d446b480d71da1bf81f892bab86ab365ce6;hp=96d81f1202b0e37a9c96b088153e16e536c8e5be;hpb=694adde1a08c393a8443fd5bbd4f036f5cf85403;p=o-du%2Fl2.git diff --git a/src/cm/rgm.c b/src/cm/rgm.c index 96d81f120..2804c43aa 100755 --- a/src/cm/rgm.c +++ b/src/cm/rgm.c @@ -41,947 +41,6 @@ /* header/extern include files (.x) */ #include "rgm.x" /* RGM Interface includes */ -#ifdef RGM_LWLC - - -/** -* @brief Request from RRM to MAC to bind the interface saps -* -* @details -* -* Function : cmPkLwLcRgmBndReq -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] SpId spId -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkLwLcRgmBndReq -( -Pst* pst, -SuId suId, -SpId spId -) -#else -S16 cmPkLwLcRgmBndReq(pst, suId, spId) -Pst* pst; -SuId suId; -SpId spId; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - - if (SPkS16(spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SPkS16(suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMBNDREQ; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief Request from RRM to MAC to bind the interface saps -* -* @details -* -* Function : cmUnpkLwLcRgmBndReq -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] SpId spId -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkLwLcRgmBndReq -( -RgmBndReq func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkLwLcRgmBndReq(func, pst, mBuf) -RgmBndReq func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SuId suId; - SpId spId; - S16 ret; - - - if (SUnpkS16(&suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SUnpkS16(&spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - ret = ((*func)(pst, suId, spId)); - - SPutMsg(mBuf); - - return (ret); -} - -/** -* @brief Request from RRM to MAC to Unbind the interface saps -* -* @details -* -* Function : cmPkLwLcRgmUbndReq -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] Reason reason -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkLwLcRgmUbndReq -( -Pst* pst, -SpId spId, -Reason reason -) -#else -S16 cmPkLwLcRgmUbndReq(pst, spId, reason) -Pst* pst; -SpId spId; -Reason reason; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - if (SPkS16(reason, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - if (SPkS16(spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMUBNDREQ; - return (SPstTsk(pst,mBuf)); -} - -/** -* @brief Confirmation from MAC to RRM for the bind/Unbind - * request for the interface saps -* -* @details -* -* Function : cmPkLwLcRgmBndCfm -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] U8 status -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkLwLcRgmBndCfm -( -Pst* pst, -SuId suId, -U8 status -) -#else -S16 cmPkLwLcRgmBndCfm(pst, suId, status) -Pst* pst; -SuId suId; -U8 status; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - - if (SPkS16(suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (oduUnpackUInt8(status, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMBNDCFM; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief Confirmation from MAC to RRM for the bind/Unbind - * request for the interface saps -* -* @details -* -* Function : cmUnpkLwLcRgmBndCfm -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] U8 status -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkLwLcRgmBndCfm -( -RgmBndCfm func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkLwLcRgmBndCfm(func, pst, mBuf) -RgmBndCfm func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SuId suId; - U8 status; - - - if (oduPackUInt8(&status, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SUnpkS16(&suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - SPutMsg(mBuf); - return ((*func)(pst, suId, status)); -} - - -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmPkLwLcRgmCfgPrbRprt -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] RgmPrbRprtCfg * prbRprtCfg -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkLwLcRgmCfgPrbRprt -( -Pst* pst, -SpId spId, -RgmPrbRprtCfg * prbRprtCfg -) -#else -S16 cmPkLwLcRgmCfgPrbRprt(pst, spId, prbRprtCfg) -Pst* pst; -SpId spId; -RgmPrbRprtCfg * prbRprtCfg; -#endif -{ - Buffer *mBuf = NULLP; - U32 len = sizeof(RgmPrbRprtCfg); - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - return RFAILED; - } - - if(oduPackPointer((PTR)prbRprtCfg, mBuf) != ROK) - { - SPutMsg(mBuf); - SPutSBuf(pst->region, pst->pool, (Data*)prbRprtCfg, len); - return RFAILED; - } - - if (SPkS16(spId, mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMCFGPRBRPRT; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmUnpkLwLcRgmCfgPrbRprt -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] RgmPrbRprtCfg * prbRprtCfg -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkLwLcRgmCfgPrbRprt -( -RgmCfgPrbRprtFptr func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkLwLcRgmCfgPrbRprt(func, pst, mBuf) -RgmCfgPrbRprtFptr func; -Pst *pst; -Buffer *mBuf; -#endif -{ - S16 ret; - SpId spId; - RgmPrbRprtCfg *prbRprtCfg; - - - if (SUnpkS16(&spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (oduUnpackPointer((PTR *)&prbRprtCfg, mBuf) != ROK) - { - SPutMsg(mBuf); - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - return RFAILED; - } - - ret = ((*func)(pst, spId, prbRprtCfg)); - - SPutMsg(mBuf); - return (ret); -} - - -/** -* @brief PRB Usage Report Indication from MAC to RRM -* -* @details -* -* Function : cmPkLwLcRgmPrbRprtInd -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] RgmPrbRprtInd * prbRprtInd -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkLwLcRgmPrbRprtInd -( -Pst* pst, -SuId suId, -RgmPrbRprtInd * prbRprtInd -) -#else -S16 cmPkLwLcRgmPrbRprtInd(pst, suId, prbRprtInd) -Pst* pst; -SuId suId; -RgmPrbRprtInd * prbRprtInd; -#endif -{ - Buffer *mBuf = NULLP; - - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); - return RFAILED; - } - - if(oduPackPointer((PTR)prbRprtInd, mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); - SPutMsg(mBuf); - return RFAILED; - } - - if (SPkS16(suId, mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMCFGPRBRPRT; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief PRB Usage Report Indication from MAC to RRM -* -* @details -* -* Function : cmUnpkLwLcRgmPrbRprtInd -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] RgmPrbRprtInd * prbRprtInd -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkLwLcRgmPrbRprtInd -( -RgmPrbRprtIndFptr func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkLwLcRgmPrbRprtInd(func, pst, mBuf) -RgmPrbRprtIndFptr func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SuId suId; - RgmPrbRprtInd *prbRprtInd; - S16 ret; - - - if (SUnpkS16(&suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (oduUnpackPointer((PTR *)&prbRprtInd, mBuf) != ROK) - { - SPutMsg(mBuf); - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); - return RFAILED; - } - - - ret = ((*func)(pst, suId, prbRprtInd)); - - SPutMsg(mBuf); - - return (ret); -} -#endif - - -/** -* @brief Request from RRM to MAC to bind the interface saps -* -* @details -* -* Function : cmPkRgmBndReq -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] SpId spId -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkRgmBndReq -( -Pst* pst, -SuId suId, -SpId spId -) -#else -S16 cmPkRgmBndReq(pst, suId, spId) -Pst* pst; -SuId suId; -SpId spId; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - - if (SPkS16(spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SPkS16(suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMBNDREQ; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief Request from RRM to MAC to bind the interface saps -* -* @details -* -* Function : cmUnpkRgmBndReq -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] SpId spId -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkRgmBndReq -( -RgmBndReq func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkRgmBndReq(func, pst, mBuf) -RgmBndReq func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SuId suId; - SpId spId; - S16 ret; - - - if (SUnpkS16(&suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SUnpkS16(&spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - ret = ((*func)(pst, suId, spId)); - - SPutMsg(mBuf); - - return (ret); -} - -/** -* @brief Request from RRM to MAC to Unbind the interface saps -* -* @details -* -* Function : cmPkRgmUbndReq -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] Reason reason -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkRgmUbndReq -( -Pst* pst, -SpId spId, -Reason reason -) -#else -S16 cmPkRgmUbndReq(pst, spId, reason) -Pst* pst; -SpId spId; -Reason reason; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - if (SPkS16(reason, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - if (SPkS16(spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMUBNDREQ; - return (SPstTsk(pst,mBuf)); -} - -#if 1 - -/** -* @brief Request from RRM to MAC to Unbind the interface saps -* -* @details -* -* Function : cmUnpkRgmUbndReq -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] Reason reason -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkRgmUbndReq -( -RgmUbndReq func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkRgmUbndReq(func, pst, mBuf) -RgmUbndReq func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SpId spId; - Reason reason; - - - if (SUnpkS16(&spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - if (SUnpkS16(&reason, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - SPutMsg(mBuf); - return ((*func)(pst, spId, reason)); -} -#endif - -/** -* @brief Confirmation from MAC to RRM for the bind/Unbind - * request for the interface saps -* -* @details -* -* Function : cmPkRgmBndCfm -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] U8 status -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkRgmBndCfm -( -Pst* pst, -SuId suId, -U8 status -) -#else -S16 cmPkRgmBndCfm(pst, suId, status) -Pst* pst; -SuId suId; -U8 status; -#endif -{ - Buffer *mBuf = NULLP; - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - return RFAILED; - } - - if (SPkS16(suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (oduUnpackUInt8(status, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - pst->event = (Event) EVTRGMBNDCFM; - return (SPstTsk(pst,mBuf)); -} - - -/** -* @brief Confirmation from MAC to RRM for the bind/Unbind - * request for the interface saps -* -* @details -* -* Function : cmUnpkRgmBndCfm -* -* @param[in] Pst* pst -* @param[in] SuId suId -* @param[in] U8 status -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkRgmBndCfm -( -RgmBndCfm func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkRgmBndCfm(func, pst, mBuf) -RgmBndCfm func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SuId suId; - U8 status; - - - if (oduPackUInt8(&status, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SUnpkS16(&suId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - SPutMsg(mBuf); - return ((*func)(pst, suId, status)); -} - - - - -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmPkCfgPrbRprt -* -* @param[in] RgmPrbRprtCfg *prbRprtCfg -* @param[in] Buffer *mBuf -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkCfgPrbRprt -( -RgmPrbRprtCfg * prbRprtCfg, -Buffer *mBuf -) -#else -S16 cmPkCfgPrbRprt(prbRprtCfg, mBuf) -RgmPrbRprtCfg * prbRprtCfg; -Buffer *mBuf; -#endif -{ - CMCHKPK(oduUnpackUInt16, prbRprtCfg->usPrbAvgPeriodicty, mBuf); - CMCHKPK(oduUnpackUInt8, prbRprtCfg->bConfigType, mBuf); - CMCHKPK(oduUnpackUInt8, prbRprtCfg->bCellId, mBuf); - return ROK; -} -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmUnPkCfgPrbRprt -* -* @param[in] RgmPrbRprtCfg *prbRprtCfg -* @param[in] Buffer *mBuf -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnPkCfgPrbRprt -( -RgmPrbRprtCfg * prbRprtCfg, -Buffer *mBuf -) -#else -S16 cmUnPkCfgPrbRprt(prbRprtCfg, mBuf) -RgmPrbRprtCfg * prbRprtCfg; -Buffer *mBuf; -#endif -{ - CMCHKUNPK(oduPackUInt8, &prbRprtCfg->bCellId, mBuf); - CMCHKUNPK(oduPackUInt8, &prbRprtCfg->bConfigType, mBuf); - CMCHKUNPK(oduPackUInt16, &prbRprtCfg->usPrbAvgPeriodicty, mBuf); - return ROK; -} - - - - -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmPkRgmCfgPrbRprt -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] RgmPrbRprtCfg *prbRprtCfg -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmPkRgmCfgPrbRprt -( -Pst* pst, -SpId spId, -RgmPrbRprtCfg * prbRprtCfg -) -#else -S16 cmPkRgmCfgPrbRprt(pst, spId, prbRprtCfg) -Pst* pst; -SpId spId; -RgmPrbRprtCfg * prbRprtCfg; -#endif -{ - Buffer *mBuf = NULLP; - U32 len = sizeof(RgmPrbRprtCfg); - - if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - return RFAILED; - } - - if(cmPkCfgPrbRprt(prbRprtCfg, mBuf) != ROK) - { - SPutMsg(mBuf); - SPutSBuf(pst->region, pst->pool, (Data*)prbRprtCfg, len); - return RFAILED; - } - - if (SPkS16(spId, mBuf) != ROK) - { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - SPutMsg(mBuf); - return RFAILED; - } - - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtCfg, sizeof(RgmPrbRprtCfg)); - - pst->event = (Event) EVTRGMCFGPRBRPRT; - return (SPstTsk(pst,mBuf)); -} - - - -/** -* @brief Configure the PRB Report Preparation Start/Stop from RRM to MAC -* -* @details -* -* Function : cmUnpkRgmCfgPrbRprt -* -* @param[in] Pst* pst -* @param[in] SpId spId -* @param[in] RgmPrbRprtCfg * prbRprtCfg -* @return S16 -* -# ROK -**/ -#ifdef ANSI -S16 cmUnpkRgmCfgPrbRprt -( -RgmCfgPrbRprtFptr func, -Pst *pst, -Buffer *mBuf -) -#else -S16 cmUnpkRgmCfgPrbRprt(func, pst, mBuf) -RgmCfgPrbRprtFptr func; -Pst *pst; -Buffer *mBuf; -#endif -{ - SpId spId; - RgmPrbRprtCfg *prbRprtCfg; - - if ((SGetSBuf(pst->region, pst->pool, (Data **)&prbRprtCfg, sizeof(RgmPrbRprtCfg))) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (SUnpkS16(&spId, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - if (cmUnPkCfgPrbRprt(prbRprtCfg, mBuf) != ROK) - { - SPutMsg(mBuf); - return RFAILED; - } - - SPutMsg(mBuf); - return ((*func)(pst, spId, prbRprtCfg)); -} - /* RRM_SP1_START */ /** * @brief Packing of PRB Usage Report for qci for sending @@ -996,17 +55,11 @@ Buffer *mBuf; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmPkRgmPrbQciRpt ( - RgmPrbRptPerQci *qciPrbRprt, - Buffer *mBuf - ) -#else -S16 cmPkRgmPrbQciRpt(qciPrbRprt, mBuf) -RgmPrbRptPerQci *qciPrbRprt; -Buffer *mBuf = NULLP; -#endif +RgmPrbRptPerQci *qciPrbRprt, +Buffer *mBuf +) { CMCHKPK(oduUnpackUInt8, qciPrbRprt->bQci, mBuf); CMCHKPK(oduUnpackUInt8, qciPrbRprt->bAvgPrbUlUsage, mBuf); @@ -1027,17 +80,11 @@ Buffer *mBuf = NULLP; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmUnpkRgmPrbQciRpt ( - RgmPrbRptPerQci *qciPrbRprt, - Buffer *mBuf - ) -#else -S16 cmUnpkRgmPrbQciRpt(qciPrbRprt, mBuf) -RgmPrbRptPerQci *qciPrbRprt; -Buffer *mBuf = NULLP; -#endif +RgmPrbRptPerQci *qciPrbRprt, +Buffer *mBuf +) { CMCHKUNPK(oduPackUInt8, &qciPrbRprt->bAvgPrbDlUsage, mBuf); CMCHKUNPK(oduPackUInt8, &qciPrbRprt->bAvgPrbUlUsage, mBuf); @@ -1059,17 +106,11 @@ Buffer *mBuf = NULLP; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmPkPrbRprtInd ( - RgmPrbRprtInd * prbRprtInd, - Buffer *mBuf - ) -#else -S16 cmPkPrbRprtInd(prbRprtInd, mBuf) - RgmPrbRprtInd * prbRprtInd; - Buffer *mBuf = NULLP; -#endif +RgmPrbRprtInd * prbRprtInd, +Buffer *mBuf +) { S32 idx = 0; @@ -1097,19 +138,13 @@ S16 cmPkPrbRprtInd(prbRprtInd, mBuf) * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmUnpkPrbRprtInd ( - RgmPrbRprtInd * prbRprtInd, - Buffer *mBuf - ) -#else -S16 cmUnpkPrbRprtInd(prbRprtInd, mBuf) - RgmPrbRprtInd * prbRprtInd; - Buffer *mBuf; -#endif +RgmPrbRprtInd * prbRprtInd, +Buffer *mBuf +) { - U32 idx = 0; + uint32_t idx = 0; /* RRM_SP1_START */ @@ -1139,43 +174,36 @@ S16 cmUnpkPrbRprtInd(prbRprtInd, mBuf) * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmPkRgmPrbRprtInd ( Pst* pst, SuId suId, RgmPrbRprtInd * prbRprtInd ) -#else -S16 cmPkRgmPrbRprtInd(pst, suId, prbRprtInd) -Pst* pst; -SuId suId; -RgmPrbRprtInd * prbRprtInd; -#endif { Buffer *mBuf = NULLP; if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); return RFAILED; } if(cmPkPrbRprtInd(prbRprtInd, mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); SPutMsg(mBuf); return RFAILED; } if (SPkS16(suId, mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); SPutMsg(mBuf); return RFAILED; } - SPutSBuf(pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)prbRprtInd, sizeof(RgmPrbRprtInd)); pst->event = (Event) EVTRGMPRBRPRTIND; return (SPstTsk(pst,mBuf)); @@ -1193,19 +221,12 @@ RgmPrbRprtInd * prbRprtInd; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmUnpkRgmPrbRprtInd ( RgmPrbRprtIndFptr func, Pst *pst, Buffer *mBuf ) -#else -S16 cmUnpkRgmPrbRprtInd(func, pst, mBuf) -RgmPrbRprtIndFptr func; -Pst *pst; -Buffer *mBuf; -#endif { SuId suId; RgmPrbRprtInd prbRprtInd; @@ -1239,17 +260,11 @@ Buffer *mBuf; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmPkTransModeInd ( - RgmTransModeInd *transModeInd, - Buffer *mBuf - ) -#else -S16 cmPkTransModeInd(transModeInd, mBuf) - RgmTransModeInd *transModeInd; - Buffer *mBuf; -#endif +RgmTransModeInd *transModeInd, +Buffer *mBuf +) { CMCHKPK(oduUnpackUInt32, transModeInd->eMode, mBuf); CMCHKPK(oduUnpackUInt16, transModeInd->usCrnti, mBuf); @@ -1269,22 +284,16 @@ S16 cmPkTransModeInd(transModeInd, mBuf) * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmUnpkTransModeInd ( - RgmTransModeInd *transModeInd, - Buffer *mBuf - ) -#else -S16 cmUnpkTransModeInd(transModeInd, mBuf) - RgmTransModeInd *transModeInd; - Buffer *mBuf; -#endif +RgmTransModeInd *transModeInd, +Buffer *mBuf +) { - U32 tmpModeEnum; + uint32_t tmpModeEnum; CMCHKUNPK(oduPackUInt8, &transModeInd->bCellId, mBuf); CMCHKUNPK(oduPackUInt16, &transModeInd->usCrnti, mBuf); - CMCHKUNPK(oduPackUInt32, (U32 *)&tmpModeEnum, mBuf); + CMCHKUNPK(oduPackUInt32, (uint32_t *)&tmpModeEnum, mBuf); transModeInd->eMode = (RgmTxnMode)tmpModeEnum; return ROK; } @@ -1301,43 +310,37 @@ S16 cmUnpkTransModeInd(transModeInd, mBuf) * @return S16 * -# ROK **/ -#ifdef ANSI + S16 cmPkRgmTransModeInd ( Pst* pst, SuId suId, RgmTransModeInd *transModeInd ) -#else -S16 cmPkRgmTransModeInd(pst, suId, transModeInd) -Pst* pst; -SuId suId; -RgmTransModeInd *transModeInd; -#endif { Buffer *mBuf = NULLP; if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); return RFAILED; } if(cmPkTransModeInd(transModeInd, mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); SPutMsg(mBuf); return RFAILED; } if (SPkS16(suId, mBuf) != ROK) { - SPutSBuf(pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); SPutMsg(mBuf); return RFAILED; } - SPutSBuf(pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); + SPutSBufNewForDebug(__FILE__,__FUNCTION__,__LINE__,pst->region, pst->pool, (Data *)transModeInd, sizeof(RgmTransModeInd)); pst->event = (Event) EVTRGMTRANSMODEIND; return (SPstTsk(pst,mBuf)); @@ -1355,19 +358,12 @@ RgmTransModeInd *transModeInd; * @return S16 * -# ROK **/ -#ifdef ANSI S16 cmUnpkRgmTransModeInd ( RgmTransModeIndFptr func, Pst *pst, Buffer *mBuf ) -#else -S16 cmUnpkRgmTransModeInd(func, pst, mBuf) -RgmTransModeIndFptr func; -Pst *pst; -Buffer *mBuf; -#endif { SuId suId; RgmTransModeInd transModeInd;