U8, U16, U32 data type changes
[o-du/l2.git] / src / cm / cm_mem.c
index bd0655a..2ed6f2e 100755 (executable)
@@ -114,10 +114,10 @@ The following functions are provided in this file.
 
 #ifdef SS_LIGHT_MEM_LEAK_STS
    MemLeakCb gmemLkCb;
-   U32 queueIndxAllocCnt =0;
-   U32 queueIndxFreeCnt =0;
-   U32 allocQueueFullCnt =0;
-   U32 allocQueueEmptyCnt =0;
+   uint32_t queueIndxAllocCnt =0;
+   uint32_t queueIndxFreeCnt =0;
+   uint32_t allocQueueFullCnt =0;
+   uint32_t allocQueueEmptyCnt =0;
 #endif
 \f
 /* local defines */
@@ -135,13 +135,13 @@ The following functions are provided in this file.
 #endif
 
 #ifdef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption */
-U32 memFreeCount=0;
-U32 cmFreeCaller[4]={0};
-U32 cmAllocCaller[4]={0};
+uint32_t memFreeCount=0;
+uint32_t cmFreeCaller[4]={0};
+uint32_t cmAllocCaller[4]={0};
 Data *startPtr256=NULLP;
 Data *startPtr128=NULLP;
-U32 cmMemInfo128[100000][2]={0, 0};
-U32 cmMemInfo256[100000][2]={0, 0};
+uint32_t cmMemInfo128[100000][2]={0, 0};
+uint32_t cmMemInfo256[100000][2]={0, 0};
 Data *startPtr512=NULLP;
 Data *startPtr768=NULLP;
 Data *startPtr1664=NULLP;
@@ -154,26 +154,26 @@ Size regMemSize=0;
 #endif
 #ifdef SS_HISTOGRAM_SUPPORT
 #ifdef SSI_DEBUG_LEVEL1
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr, 
-            U32 memType, U32 line, U8 *fileName, U8 entId, Bool hstReg));
-PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size, U32 memType, U32 line, U8 *fileName, U8 entId, Bool hstReg));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr, 
+            uint32_t memType, uint32_t line, uint8_t *fileName, uint8_t entId, Bool hstReg));
+PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size, uint32_t memType, uint32_t line, uint8_t *fileName, uint8_t entId, Bool hstReg));
 /*cm_mem_c_001.main_20-added new functionto allocate memory from new region*/
 #else
 PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size,
-       U32 line, U8 *fileName, U8 entId, Bool hstReg));
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr, 
-            U32 line, U8 *fileName, U8 entId, Bool hstReg));
+       uint32_t line, uint8_t *fileName, uint8_t entId, Bool hstReg));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr, 
+            uint32_t line, uint8_t *fileName, uint8_t entId, Bool hstReg));
 #endif /* SSI_DEBUG_LEVEL1 */
 
-PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, U32 line, 
-            U8 *fileName, U8 entId, Bool hstReg));
+PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, uint32_t line, 
+            uint8_t *fileName, uint8_t entId, Bool hstReg));
 
 PRIVATE S16 cmHeapFree  ARGS((CmMmHeapCb *heapCb, Data *ptr, Size size,
-            U32 line, U8 *fileName, U8 entId, Bool hstReg));
+            uint32_t line, uint8_t *fileName, uint8_t entId, Bool hstReg));
 #else /* no histogram support */
 /* cm_mem_c_001.main_12 - prototype is changed to accept memType(static/dynamic) */
 #ifdef SSI_DEBUG_LEVEL1
-PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size, U32 memType));
+PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size, uint32_t memType));
 #else
 #ifndef USE_PURE
 PRIVATE S16 cmHeapAlloc ARGS((CmMmHeapCb *heapCb, Data **ptr, Size *size));
@@ -184,20 +184,20 @@ PRIVATE S16 cmHeapFree  ARGS((CmMmHeapCb *heapCb, Data *ptr, Size size));
 #endif/*USE_PURE*/
 /*  cm_mem_c_001.main_15 :Additions */
 #ifdef SS_LIGHT_MEM_LEAK_STS
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr, U32 memType, U32 lineNo,U8 *funcName ));
-PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, U32 lineNo, U8* funcName));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr, uint32_t memType, uint32_t lineNo,uint8_t *funcName ));
+PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, uint32_t lineNo, uint8_t* funcName));
 #else /*SS_LIGHT_MEM_LEAK_STS */
 #if (defined(SSI_DEBUG_LEVEL1) || defined(BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1))
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr, U32 memType));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr, uint32_t memType));
 #else
 #ifdef T2K_MEM_LEAK_DBG
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr, char*  file, U32    line));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr, char*  file, uint32_t    line));
 #else
-PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr));
+PRIVATE S16 cmAlloc ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr));
 #endif
 #endif /* SSI_DEBUG_LEVEL1 */
 #ifdef T2K_MEM_LEAK_DBG
-PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, char* file, U32 line));
+PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size, char* file, uint32_t line));
 #else
 PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size));
 #endif
@@ -205,7 +205,7 @@ PRIVATE S16 cmFree  ARGS((Void *regionCb, Data *ptr, Size size));
 #endif /*SS_LIGHT_MEM_LEAK_STS*/
 /*cm_mem_c_001.main_23 Removed support of SSI_DEBUG_LEVEL1 and SS_HISTOGRAM_SUPPORT for SS_FAP*/
 #ifdef SS_FAP
-PRIVATE S16 cmAllocWL ARGS((Void *regionCb, Size *size, U32 flags, Data **ptr));
+PRIVATE S16 cmAllocWL ARGS((Void *regionCb, Size *size, uint32_t flags, Data **ptr));
 PRIVATE S16 cmFreeWL  ARGS((Void *regionCb, Data *ptr, Size size));
 #endif
 
@@ -213,27 +213,27 @@ PRIVATE S16 cmCtl   ARGS((Void *regionCb, Event event, SMemCtl *memCtl));
 
 PRIVATE Void cmMmHeapInit ARGS((Data *memAddr, CmMmHeapCb *heapCb, Size size));
 PRIVATE Void cmMmBktInit ARGS((Data **memAddr, CmMmRegCb *regCb, 
-                              CmMmRegCfg *cfg, U16 bktIdx, U16 *lstMapIdx));
+                              CmMmRegCfg *cfg, uint16_t bktIdx, uint16_t *lstMapIdx));
 
 /* cm_mem_c_001.main_12 - addition of protoypes for sanity check and hash list functions */
 #ifdef SSI_DEBUG_LEVEL1
 PRIVATE S16 cmMmBktSanityChk ARGS((CmMmBkt *bkt));
 PRIVATE S16 cmMmHeapSanityChk ARGS((CmMmHeapCb *heapCb));
-PRIVATE S16 cmMmHashFunc ARGS((CmMmHashListCp *hashListCp, U32 key, U16 *idx ));
-PRIVATE S16 cmMmHashListInit ARGS((CmMmHashListCp *hashListCp, U16 nmbBins,
+PRIVATE S16 cmMmHashFunc ARGS((CmMmHashListCp *hashListCp, uint32_t key, uint16_t *idx ));
+PRIVATE S16 cmMmHashListInit ARGS((CmMmHashListCp *hashListCp, uint16_t nmbBins,
                                   Region region, Pool pool));
 PRIVATE S16 cmMmHashListDeinit ARGS((CmMmHashListCp *hashListCp, Region region, Pool pool));
-PRIVATE S16 cmMmHashListInsert ARGS((CmMmHashListCp *hashListCp, U32 key));
+PRIVATE S16 cmMmHashListInsert ARGS((CmMmHashListCp *hashListCp, uint32_t key));
 #endif /* SSI_DEBUG_LEVEL1 */
 /*   cm_mem_c_001.main_15 : Addtions */
 #ifdef SS_HISTOGRAM_SUPPORT
-PRIVATE S16 cmHstGrmAllocInsert ARGS((CmHstGrmHashListCp *hashListCp, U32 blkSz, U32 *reqSz, U32 line, U8 *fileName, U8 entId));
-PRIVATE S16 cmHstGrmFreeInsert ARGS((CmHstGrmHashListCp* hashListCp, U32 blkSz, U32 line, U8 *fileName, U8 entId));
+PRIVATE S16 cmHstGrmAllocInsert ARGS((CmHstGrmHashListCp *hashListCp, uint32_t blkSz, uint32_t *reqSz, uint32_t line, uint8_t *fileName, uint8_t entId));
+PRIVATE S16 cmHstGrmFreeInsert ARGS((CmHstGrmHashListCp* hashListCp, uint32_t blkSz, uint32_t line, uint8_t *fileName, uint8_t entId));
 PRIVATE S16 cmHstGrmHashListInit ARGS((CmHstGrmHashListCp *hashListCp));
 PRIVATE S16 cmHstGrmHashListDeInit ARGS((CmHstGrmHashListCp *hashListCp));
-PRIVATE S16 cmHstGrmGetHashIdxAndKey ARGS((U8 *fileName, U32 line, U32 *binIdx, U32 *key));
-PRIVATE S16 cmHstGrmFindEntry ARGS((CmHstGrmHashListCp *hashListCp, U32 key, U32 *binIdx, CmMemEntries **entry));
-PRIVATE S16 cmHstGrmFillEntry ARGS((CmMemEntries *entry, U32 key, U32 line, U8 *fileName, U8 entId));
+PRIVATE S16 cmHstGrmGetHashIdxAndKey ARGS((uint8_t *fileName, uint32_t line, uint32_t *binIdx, uint32_t *key));
+PRIVATE S16 cmHstGrmFindEntry ARGS((CmHstGrmHashListCp *hashListCp, uint32_t key, uint32_t *binIdx, CmMemEntries **entry));
+PRIVATE S16 cmHstGrmFillEntry ARGS((CmMemEntries *entry, uint32_t key, uint32_t line, uint8_t *fileName, uint8_t entId));
 #endif /* SS_HISTOGRAM_SUPPORT */
 
 /* cm_mem_c_001.main_22: Fixing warnings on GCC compiler */
@@ -267,32 +267,32 @@ MemLkInfo memLk;
 
 #ifdef T2K_MEM_LEAK_DBG
 typedef struct {
-U8  minBktSzBitMask;  /* minimum allocation size  in Log(x)base 2, where X is minimum bucket size in region */ 
-U16 minBktSzMins1; /* X-1   */
+uint8_t  minBktSzBitMask;  /* minimum allocation size  in Log(x)base 2, where X is minimum bucket size in region */ 
+uint16_t minBktSzMins1; /* X-1   */
 }RegMinBktSzInfo;
 static RegMinBktSzInfo regMinBktSzInfo[SS_MAX_REGS] = {{8,0xFF},{7,0x7F},{7,0x7F},{7,0x7F}}; 
 RegionMemLeakInfo regMemLeakInfo; 
 
-U32 getT2kMemLeakIndex(U64 address, Region region)
+uint32_t getT2kMemLeakIndex(uint64_t address, Region region)
 {
    return ((address - regMemLeakInfo.regStartAddr[region]) >> regMinBktSzInfo[region].minBktSzBitMask);
 }
 
-static U32 t2kMemAllocTick;
-static U32 smallTick;
+static uint32_t t2kMemAllocTick;
+static uint32_t smallTick;
 
-void InsertToT2kMemLeakInfo(U64 address, U32 size, U32 lineNo, char* fileName, Region region)
+void InsertToT2kMemLeakInfo(uint64_t address, uint32_t size, uint32_t lineNo, char* fileName, Region region)
 {
 
    T2kMeamLeakInfo *leakInfo;
   /* if(!startMemLeak)
    {
-      RETVOID;
+      return;
    }*/
 
-   U32 index1 = getT2kMemLeakIndex(address,region);
+   uint32_t index1 = getT2kMemLeakIndex(address,region);
 
-   if(((U64)(address - regMemLeakInfo.regStartAddr[region]) & regMinBktSzInfo[region].minBktSzMins1) !=0)
+   if(((uint64_t)(address - regMemLeakInfo.regStartAddr[region]) & regMinBktSzInfo[region].minBktSzMins1) !=0)
    {
      printf("address in InsertToT2kMemLeakInfo is %ld size = %d file is %s line is %d \n", address, size, fileName, lineNo);
    }
@@ -326,7 +326,7 @@ void InsertToT2kMemLeakInfo(U64 address, U32 size, U32 lineNo, char* fileName, R
 }
 
 
-void RemoveFromT2kMemLeakInfo(U64 address, char *file, U32 line,Region region)
+void RemoveFromT2kMemLeakInfo(uint64_t address, char *file, uint32_t line,Region region)
 {
    T2kMeamLeakInfo *leakInfo;
 
@@ -335,7 +335,7 @@ void RemoveFromT2kMemLeakInfo(U64 address, char *file, U32 line,Region region)
       return ROK;
    }*/
 
-   U32 index1 = getT2kMemLeakIndex(address, region);
+   uint32_t index1 = getT2kMemLeakIndex(address, region);
 
    if(index1 >= T2K_MEM_LEAK_INFO_TABLE_SIZE)
    {
@@ -417,7 +417,7 @@ void DumpT2kMemLeakInfoToFile()
 /* cm_mem_c_008.104 - Addition for memory calculator tool */
 #ifdef MEMCAL_DEBUG
 PRIVATE Txt prntBuf[200];        /* print buffer */
-PRIVATE U8 tryHeap=0;
+PRIVATE uint8_t tryHeap=0;
 #endif 
 
 /* cm_mem_c_001.main_12 - addition for ssi enhancements prints */
@@ -429,9 +429,9 @@ PRIVATE Txt dbgPrntBuf[200];        /* print buffer */
 #endif /* DEBUGP */
 #endif /*SSI_DEBUG_LEVEL1 || SS_HISTOGRAM_SUPPORT */
 
-U32 num_times = 0;
+uint32_t num_times = 0;
 #ifdef SSI_MEM_CORR_PREVENTION
-U32 cmDblFreeAttempts = 0;
+uint32_t cmDblFreeAttempts = 0;
 #endif
 /* private variable declarations */
 
@@ -476,8 +476,8 @@ CmMmRegCfg  *cfg;
 #endif
 {
    Data *memAddr;
-   U16   bktIdx;
-   U16   lstMapIdx;
+   uint16_t   bktIdx;
+   uint16_t   lstMapIdx;
 
 #if (ERRCLASS & ERRCLS_INT_PAR)
    Size  lstQnSize;
@@ -485,7 +485,7 @@ CmMmRegCfg  *cfg;
        Txt   errMsg[256] = {'\0'};
 #endif
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
-   U16            offset;
+   uint16_t            offset;
    CmMmBlkHdr     ptrHdr;
 #endif
 
@@ -758,10 +758,10 @@ CmMmRegCfg  *cfg;
 #endif /* SSI_DEBUG_LEVEL1 */
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
     /* Initialize the hast list to maintain the SSI memory information for Broadcom */
-    offset = (U16)((PTR)(&ptrHdr.ent) - (PTR) &ptrHdr);
+    offset = (uint16_t)((PTR)(&ptrHdr.ent) - (PTR) &ptrHdr);
     printf("###########offset is %d region %d\n", offset, region);
     if(cmHashListInit(&regCb->brdcmSsiLstCp, 1000, offset, FALSE, 
-       CM_HASH_KEYTYPE_U32MOD, region, 0) != ROK)
+       CM_HASH_KEYTYPE_UINT32_MOD, region, 0) != ROK)
     {
        return RFAILED;
     }
@@ -807,7 +807,7 @@ S16 cmMmRegDeInit(regCb)
 CmMmRegCb   *regCb;
 #endif
 {
-   U16  bktIdx; 
+   uint16_t  bktIdx; 
 
 
 #if (ERRCLASS & ERRCLS_INT_PAR)
@@ -932,24 +932,24 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     memType,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr, memType, line, fileName, entId, hstReg)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     memType;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #else
@@ -958,22 +958,22 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr, line, fileName, entId, hstReg)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #endif /* SSI_DEBUG_LEVEL1 */
@@ -984,21 +984,21 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType,
-U32     lineNo,
-U8     *funcName
+uint32_t     memType,
+uint32_t     lineNo,
+uint8_t     *funcName
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr ,memType, lineNo, funcName)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
-U32     lineNo;
-U8     *funcName;
+uint32_t     memType;
+uint32_t     lineNo;
+uint8_t     *funcName;
 #endif
 #else /*SS_LIGHT_MEM_LEAK_STS */
 #ifdef SSI_DEBUG_LEVEL1
@@ -1007,17 +1007,17 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType
+uint32_t     memType
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr, memType)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
+uint32_t     memType;
 #endif
 #else
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
@@ -1026,17 +1026,17 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType
+uint32_t     memType
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr, memType)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
+uint32_t     memType;
 #endif
 #else
 #ifdef T2K_MEM_LEAK_DBG
@@ -1044,10 +1044,10 @@ PRIVATE S16  cmAlloc
 (
  Void   *regionCb,
  Size   *size,
U32     flags,
uint32_t     flags,
  Data   **ptr ,
  char*  file,
U32    line
uint32_t    line
  )
 #else
 #ifdef ANSI
@@ -1055,14 +1055,14 @@ PRIVATE S16  cmAlloc
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr 
 )
 #else
 PRIVATE S16  cmAlloc(regionCb, size, flags, ptr)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
 #endif
 #endif
@@ -1075,13 +1075,13 @@ Data  **ptr;
 {
 /* cm_mem_c_001.main_26 : Fixes for Compilation Warnings */
 #ifndef USE_PURE
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
 #endif
    CmMmRegCb *regCb;
 /* cm_mem_c_001.main_26 : Fixes for Compilation Warnings */
 #ifndef USE_PURE
-   U16        cnt;
+   uint16_t        cnt;
 #endif
 /*   cm_mem_c_001.main_15 : Additions */
 #if (defined(SS_MEM_LEAK_STS) || defined( BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1))
@@ -1099,7 +1099,7 @@ Data  **ptr;
        S8 hstGrmBuf[256];
 #endif /* SS_HISTOGRAM_SUPPORT */
 #ifdef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption */
-        U16 memIndex=0;
+        uint16_t memIndex=0;
 Data  *nextptr1;
 Data  *prevptr1;
 Data  **nextptr;
@@ -1314,7 +1314,7 @@ Data  **prevptr;
       memIndex = (*ptr - startPtr256) / 256;
    }
 #if 1
-         if (*((U32 *)(*ptr + 4)) != 0xDEADDEAD && *((U32 *)(*ptr + 80)) != 0xDEADDEAD && *((U32 *)(*ptr + 24)) != 0xDEADDEAD)
+         if (*((uint32_t *)(*ptr + 4)) != 0xDEADDEAD && *((uint32_t *)(*ptr + 80)) != 0xDEADDEAD && *((uint32_t *)(*ptr + 24)) != 0xDEADDEAD)
         {
           }
            if(bkt->size == 256)
@@ -1324,7 +1324,7 @@ Data  **prevptr;
 #endif
 #endif /* MS_MBUF_CORRUPTION */
 #ifdef SSI_MEM_CORR_PREVENTION
-            *(((U32 *)(*ptr)) + 2) = 0;
+            *(((uint32_t *)(*ptr)) + 2) = 0;
 #endif
 
 #ifdef T2K_MEM_LEAK_DBG 
@@ -1332,7 +1332,7 @@ Data  **prevptr;
             {
                /* Lock before the transaction-start */
                pthread_mutex_lock(&(regMemLeakInfo.memLock[regCb->region]));
-               InsertToT2kMemLeakInfo( (U64)*ptr,*size,line,file,regCb->region);
+               InsertToT2kMemLeakInfo( (uint64_t)*ptr,*size,line,file,regCb->region);
                /* UnLock after the transaction */
                pthread_mutex_unlock(&(regMemLeakInfo.memLock[regCb->region]));
             }
@@ -1341,7 +1341,7 @@ Data  **prevptr;
             bkt->next = *((CmMmEntry **)(bkt->next));
 #ifdef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption */
          *nextptr = bkt->next;
-         if (*((U32 *)(*nextptr + 4)) != 0xDEADDEAD && *((U32 *)(*nextptr + 80)) != 0xDEADDEAD && *((U32 *)(*nextptr + 24)) != 0xDEADDEAD)
+         if (*((uint32_t *)(*nextptr + 4)) != 0xDEADDEAD && *((uint32_t *)(*nextptr + 80)) != 0xDEADDEAD && *((uint32_t *)(*nextptr + 24)) != 0xDEADDEAD)
         {
             if(bkt->size == 128)
                *prevptr = startPtr128 + ((memIndex-1)*128);
@@ -1365,12 +1365,12 @@ Data  **prevptr;
          cmMemInfo256[memIndex][0] = cmAllocCaller[MxGetCpuID()];
       }
       cmAllocCaller[MxGetCpuID()] = NULLP;
-         *((U32 *)(*ptr + 4)) = 0x00000000;
-         *((U32 *)(*ptr + 124)) = 0;
-         *((U32 *)(*ptr + 24)) = 0x00000000;
-         *((U32 *)(*ptr + 44)) = 0x00000000;            
-         *((U32 *)(*ptr + 80)) = 0x00000000;
-         *((U32 *)(*ptr + 116)) = 0x00000000;
+         *((uint32_t *)(*ptr + 4)) = 0x00000000;
+         *((uint32_t *)(*ptr + 124)) = 0;
+         *((uint32_t *)(*ptr + 24)) = 0x00000000;
+         *((uint32_t *)(*ptr + 44)) = 0x00000000;            
+         *((uint32_t *)(*ptr + 80)) = 0x00000000;
+         *((uint32_t *)(*ptr + 116)) = 0x00000000;
 #endif
 #endif /* SSI_DEBUG_LEVEL1 */
 
@@ -1615,16 +1615,16 @@ PRIVATE S16  cmFree
 Void   *regionCb,
 Data   *ptr, 
 Size    size,
-U32     lineNo,
-U8      *funcName
+uint32_t     lineNo,
+uint8_t      *funcName
 )
 #else
 PRIVATE S16  cmFree(regionCb, ptr, size, lineNo, funcName)
 Void   *regionCb;
 Data   *ptr;
 Size    size;
-U32     lineNo;
-U8      *funcName;
+uint32_t     lineNo;
+uint8_t      *funcName;
 #endif
 #else /*SS_LIGHT_MEM_LEAK_STS */
 #ifdef SS_HISTOGRAM_SUPPORT
@@ -1634,9 +1634,9 @@ PRIVATE S16  cmFree
 Void   *regionCb,
 Data   *ptr,
 Size    size,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -1644,9 +1644,9 @@ PRIVATE S16  cmFree(regionCb, ptr, size, line, fileName, entId, hstReg)
 Void   *regionCb;
 Data   *ptr;
 Size    size;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 
@@ -1658,7 +1658,7 @@ PRIVATE S16  cmFree
  Data   *ptr,
  Size   size,
  char*  file,
U32    line
uint32_t    line
  )
 #else /* T2K_MEM_LEAK_DBG */
 #ifdef ANSI
@@ -1682,7 +1682,7 @@ Size    size;
 {
 /* cm_mem_c_001.main_26 : Fixes for Compilation Warnings */
 #ifndef USE_PURE
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
 #endif
    CmMmRegCb *regCb;
@@ -1698,7 +1698,7 @@ Size    size;
        S8 hstGrmBuf[256];
 #endif /* SS_HISTOGRAM_SUPPORT */
 #ifdef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption*/
-        U16 memIndex=0;
+        uint16_t memIndex=0;
 #endif
 
 
@@ -1746,7 +1746,7 @@ Size    size;
 #ifdef T2K_MEM_LEAK_DBG
       {
          pthread_mutex_lock(&(regMemLeakInfo.memLock[regCb->region]));
-         RemoveFromT2kMemLeakInfo((U64)ptr , file,line,regCb->region);
+         RemoveFromT2kMemLeakInfo((uint64_t)ptr , file,line,regCb->region);
          pthread_mutex_unlock(&(regMemLeakInfo.memLock[regCb->region]));
       }
 #endif
@@ -2007,7 +2007,7 @@ Size    size;
 
 #ifndef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption */
 #ifdef SSI_MEM_CORR_PREVENTION
-      if (*(((U32 *)(ptr)) + 2) == 0xdeaddead)
+      if (*(((uint32_t *)(ptr)) + 2) == 0xdeaddead)
       {
          /* Do not free an already freed block to avoid corruption */
          cmDblFreeAttempts++;
@@ -2018,7 +2018,7 @@ Size    size;
          *((CmMmEntry **)bkt->last) = ptr;
          bkt->last = (CmMmEntry *)ptr;
          *((CmMmEntry **)ptr) = NULLP;
-         *(((U32 *)(ptr)) + 2) = 0xdeaddead;
+         *(((uint32_t *)(ptr)) + 2) = 0xdeaddead;
       }
 #else
       *((CmMmEntry **)ptr) =  bkt->next; 
@@ -2085,36 +2085,36 @@ Size    size;
             *crashPtr = 9;
          }
       }
-      if (*((U32 *)(ptr + 4)) != 0xDEADDEAD)
+      if (*((uint32_t *)(ptr + 4)) != 0xDEADDEAD)
       {
-         *(U32 *)(ptr + 4) = 0xDEADDEAD;
+         *(uint32_t *)(ptr + 4) = 0xDEADDEAD;
       }
       else
       {
          Data *crashPtr=NULLP;
          *crashPtr = 9;
       }
-      if (*((U32 *)(ptr + 24)) != 0xDEADDEAD)
+      if (*((uint32_t *)(ptr + 24)) != 0xDEADDEAD)
       {
-         *(U32 *)(ptr + 24) = 0xDEADDEAD;
+         *(uint32_t *)(ptr + 24) = 0xDEADDEAD;
       }
       else
       {
          Data *crashPtr=NULLP;
          *crashPtr = 9;
       }
-      if (*((U32 *)(ptr + 44)) != 0xDEADDEAD)
+      if (*((uint32_t *)(ptr + 44)) != 0xDEADDEAD)
       {
-         *(U32 *)(ptr + 44) = 0xDEADDEAD;
+         *(uint32_t *)(ptr + 44) = 0xDEADDEAD;
       }
       else
       {
          Data *crashPtr=NULLP;
          *crashPtr = 9;
       }
-      if (*((U32 *)(ptr + 80)) != 0xDEADDEAD)
+      if (*((uint32_t *)(ptr + 80)) != 0xDEADDEAD)
       {
-         *(U32 *)(ptr + 80) = 0xDEADDEAD;
+         *(uint32_t *)(ptr + 80) = 0xDEADDEAD;
       }
       else
       {
@@ -2122,8 +2122,8 @@ Size    size;
          *crashPtr = 9;
          /* Cause a crash to identify the caller */
       }
-      *(U32 *)(ptr + 124) = memFreeCount++;
-      (*(U32 *)(ptr + 116)) = cmFreeCaller[MxGetCpuID()];
+      *(uint32_t *)(ptr + 124) = memFreeCount++;
+      (*(uint32_t *)(ptr + 116)) = cmFreeCaller[MxGetCpuID()];
       if(bkt->size == 128)
       {
          memIndex = (ptr - startPtr128) / 128;
@@ -2250,12 +2250,12 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     memType,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -2263,12 +2263,12 @@ S16  cmAllocNL(regionCb, size, flags, ptr, memType,
       line, fileName, entId, hstReg)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     memType;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #else
@@ -2277,11 +2277,11 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -2289,11 +2289,11 @@ S16  cmAllocNL(regionCb, size, flags, ptr, line,
       fileName, entId, hstReg)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #endif /* SSI_DEBUG_LEVEL1 */
@@ -2305,21 +2305,21 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType,
-U32     lineNo,
-U8     *funcName
+uint32_t     memType,
+uint32_t     lineNo,
+uint8_t     *funcName
 )
 #else
 S16  cmAllocNL(regionCb, size, flags, ptr ,memType, lineNo, funcName)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
-U32     lineNo;
-U8     *funcName;
+uint32_t     memType;
+uint32_t     lineNo;
+uint8_t     *funcName;
 #endif
 #else /*SS_LIGHT_MEM_LEAK_STS */
 #ifdef SSI_DEBUG_LEVEL1
@@ -2328,17 +2328,17 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType
+uint32_t     memType
 )
 #else
 S16  cmAllocNL(regionCb, size, flags, ptr, memType)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
+uint32_t     memType;
 #endif
 #else
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
@@ -2347,17 +2347,17 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr,
-U32     memType
+uint32_t     memType
 )
 #else
 S16  cmAllocNL(regionCb, size, flags, ptr, memType)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
-U32     memType;
+uint32_t     memType;
 #endif
 #else
 #ifdef ANSI
@@ -2365,14 +2365,14 @@ S16  cmAllocNL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr 
 )
 #else
 S16  cmAllocNL(regionCb, size, flags, ptr)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
 #endif
 #endif /* BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1 */
@@ -2384,13 +2384,13 @@ Data  **ptr;
 {
    /* cm_mem_c_001.main_26 : Fixes for Compilation Warnings */
 #ifndef USE_PURE
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
 #endif
    CmMmRegCb *regCb;
    /* cm_mem_c_001.main_26 : Fixes for Compilation Warnings */
 #ifndef USE_PURE
-   U16        cnt;
+   uint16_t        cnt;
 #endif
    /*   cm_mem_c_001.main_15 : Additions */
 #if (defined(SS_MEM_LEAK_STS) || defined( BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1))
@@ -2582,7 +2582,7 @@ Data  **ptr;
             bkt->nextBlk = (CmMmBlkHdr *)(bkt->nextBlk->nextBlk);
 #else
 #ifdef SSI_MEM_CORR_PREVENTION
-            *(((U32 *)(*ptr)) + 2) = 0;
+            *(((uint32_t *)(*ptr)) + 2) = 0;
 #endif
             bkt->next = *((CmMmEntry **)(bkt->next));
 #endif /* SSI_DEBUG_LEVEL1 */
@@ -2818,16 +2818,16 @@ S16  cmFreeNL
 Void   *regionCb,
 Data   *ptr, 
 Size    size,
-U32     lineNo,
-U8      *funcName
+uint32_t     lineNo,
+uint8_t      *funcName
 )
 #else
 S16  cmFreeNL(regionCb, ptr, size, lineNo, funcName)
 Void   *regionCb;
 Data   *ptr;
 Size    size;
-U32     lineNo;
-U8      *funcName;
+uint32_t     lineNo;
+uint8_t      *funcName;
 #endif
 #else /*SS_LIGHT_MEM_LEAK_STS */
 
@@ -2838,9 +2838,9 @@ S16  cmFreeNL
 Void   *regionCb,
 Data   *ptr,
 Size    size,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -2848,9 +2848,9 @@ S16  cmFreeNL(regionCb, ptr, size, line, fileName, entId, hstReg)
 Void   *regionCb;
 Data   *ptr;
 Size    size;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 
@@ -2875,7 +2875,7 @@ Size    size;
 
 {
 #ifndef USE_PURE
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
 #endif
    CmMmRegCb *regCb;
@@ -3131,7 +3131,7 @@ Size    size;
 
 #else
 #ifdef SSI_MEM_CORR_PREVENTION
-      if (*(((U32 *)(ptr)) + 2) == 0xdeaddead)
+      if (*(((uint32_t *)(ptr)) + 2) == 0xdeaddead)
       {
          /* Do not free an already freed block to avoid corruption */
          cmDblFreeAttempts++;
@@ -3142,7 +3142,7 @@ Size    size;
          *((CmMmEntry **)bkt->last) = ptr;
          bkt->last = (CmMmEntry *)ptr;
          *((CmMmEntry **)ptr) = NULLP;
-         *(((U32 *)(ptr)) + 2) = 0xdeaddead;
+         *(((uint32_t *)(ptr)) + 2) = 0xdeaddead;
       }
 #else
       *((CmMmEntry **)ptr) =  bkt->next; 
@@ -3224,18 +3224,18 @@ PRIVATE S16  cmAllocWL
 (
 Void   *regionCb,
 Size   *size,
-U32     flags,
+uint32_t     flags,
 Data  **ptr 
 )
 #else
 PRIVATE S16  cmAllocWL(regionCb, size, flags, ptr)
 Void   *regionCb;
 Size   *size;
-U32     flags;
+uint32_t     flags;
 Data  **ptr;
 #endif
 {
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
    CmMmRegCb *regCb;
    /*cm_mem_c_001.main_23 Removed support of SSI_DEBUG_LEVEL1 and SS_HISTOGRAM_SUPPORT for SS_FAP*/
@@ -3356,7 +3356,7 @@ Data   *ptr;
 Size    size;
 #endif
 {
-   U16        idx;
+   uint16_t        idx;
    CmMmBkt   *bkt;
    CmMmRegCb *regCb;
    /*cm_mem_c_001.main_23 Removed support of SSI_DEBUG_LEVEL1 and SS_HISTOGRAM_SUPPORT for SS_FAP*/
@@ -3538,9 +3538,9 @@ SMemCtl *memCtl;
          /* Check if the Bucket pool is configured */
          if (regCb->bktSize)
          {
-            U16        idx;
+            uint16_t        idx;
             CmMmBkt   *bkt;
-            U32        avlSize, totSize;
+            uint32_t        avlSize, totSize;
             /* 
              * The bucket pool is configured. The status value returned
              * does reflect on the memory availabilty in the bucket pool. 
@@ -3608,21 +3608,21 @@ PRIVATE Void cmMmBktInit
 Data      **memAddr,
 CmMmRegCb  *regCb,
 CmMmRegCfg *cfg,
-U16         bktIdx,
-U16        *lstMapIdx
+uint16_t         bktIdx,
+uint16_t        *lstMapIdx
 )
 #else
 PRIVATE Void cmMmBktInit (memAddr, regCb, cfg, bktIdx, lstMapIdx)
 Data      **memAddr;
 CmMmRegCb  *regCb;
 CmMmRegCfg *cfg;
-U16         bktIdx;
-U16        *lstMapIdx;
+uint16_t         bktIdx;
+uint16_t        *lstMapIdx;
 #endif
 {
-   U32   cnt;
-   U16   idx;
-   U32   numBlks;
+   uint32_t   cnt;
+   uint16_t   idx;
+   uint32_t   numBlks;
    Size  size;
 /* cm_mem_c_001.main_12 - addition for temporary variables */
 #if (defined(SSI_DEBUG_LEVEL1) || defined(BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1) || defined (SS_LIGHT_MEM_LEAK_STS))
@@ -3630,7 +3630,7 @@ U16        *lstMapIdx;
 #ifdef SS_LIGHT_MEM_LEAK_STS
    CmMmBlkHdr *lastBlk;
 #endif /*SS_LIGHT_MEM_LEAK_STS */
-   U32 sigCnt;
+   uint32_t sigCnt;
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
    Data         *tmpMemAddr;
    CmMmBlkTail  *blkTail;
@@ -3696,7 +3696,7 @@ U16        *lstMapIdx;
 
    *nextBlk = NULLP;
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
-    tmpMemAddr = (Data *)((*memAddr) - ((sizeof(CmMmBlkHdr)) + sizeof(U32) + size));
+    tmpMemAddr = (Data *)((*memAddr) - ((sizeof(CmMmBlkHdr)) + sizeof(uint32_t) + size));
     regCb->bktTbl[bktIdx].lastBlk = (CmMmBlkHdr *)tmpMemAddr;
 #endif
 
@@ -3756,15 +3756,15 @@ U16        *lstMapIdx;
    {
       *next     = *memAddr;
 #ifdef MS_MBUF_CORRUPTION /* Should be enabled when debugging mbuf corruption */
-         (*(U32 *)(*next + 4)) = 0xdeaddead;
-         (*(U32 *)(*next + 124)) = 0;
-         (*(U32 *)(*next + 116)) = 0xdeaddead;
-         (*(U32 *)(*next + 24)) = 0xdeaddead;
-         (*(U32 *)(*next + 44)) = 0xdeaddead;            
-         (*(U32 *)(*next + 80)) = 0xdeaddead;
+         (*(uint32_t *)(*next + 4)) = 0xdeaddead;
+         (*(uint32_t *)(*next + 124)) = 0;
+         (*(uint32_t *)(*next + 116)) = 0xdeaddead;
+         (*(uint32_t *)(*next + 24)) = 0xdeaddead;
+         (*(uint32_t *)(*next + 44)) = 0xdeaddead;            
+         (*(uint32_t *)(*next + 80)) = 0xdeaddead;
 #endif
 #ifdef SSI_MEM_CORR_PREVENTION
-         *(((U32 *)(*next)) + 2) = 0xdeaddead;
+         *(((uint32_t *)(*next)) + 2) = 0xdeaddead;
 #endif
       next      = (CmMmEntry **)(*memAddr);
       *memAddr  = (*memAddr) + size;
@@ -3814,7 +3814,7 @@ U16        *lstMapIdx;
    regCb->bktSize += ((size + sizeof(CmMmBlkHdr)) * numBlks);
 /* Addition for considering the header size and tail */
 #elif BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
-   regCb->bktSize += ((size + sizeof(CmMmBlkHdr) + sizeof(U32)) * numBlks);
+   regCb->bktSize += ((size + sizeof(CmMmBlkHdr) + sizeof(uint32_t)) * numBlks);
 #else
    regCb->bktSize += (size * numBlks); 
 #endif /* SSI_DEBUG_LEVEL1 */
@@ -3838,7 +3838,7 @@ U16        *lstMapIdx;
    cmHstGrmHashListInit(&(regCb->bktTbl[bktIdx].hstGrmHashListCp));
 #endif /* SS_HISTOGRAM_SUPPORT */
 
-   RETVOID;
+   return;
 } /* end of cmMmBktInit */
 
 \f
@@ -3873,7 +3873,7 @@ Size         size;
 {
 /* cm_mem_c_001.main_12 - addition for ssi enhancements */
 #ifdef SSI_DEBUG_LEVEL1
-   U16 idx;
+   uint16_t idx;
 #endif /* SSI_DEBUG_LEVEL1 */
 
    /* Initialize the heap control block */
@@ -3917,7 +3917,7 @@ Size         size;
    /* Initialise the memory histogram hash list */
    cmHstGrmHashListInit(&(heapCb->heapHstGrmHashListCp));
 #endif /* SS_HISTOGRAM_SUPPORT */
-   RETVOID;
+   return;
 
 } /* end of cmMmHeapInit */
 
@@ -3944,7 +3944,7 @@ Size         size;
 /* cm_mem_c_001.main_12 - addition for taking another parameter memType(static/dynamic) */
 /*  cm_mem_c_001.main_15 : Additions */
 #ifdef SS_4GMX_LCORE
-EXTERN U8 ysCellConfigDone;
+EXTERN uint8_t ysCellConfigDone;
 #endif
 #ifdef SS_HISTOGRAM_SUPPORT 
 #ifdef SSI_DEBUG_LEVEL1
@@ -3954,10 +3954,10 @@ PRIVATE S16  cmHeapAlloc
 CmMmHeapCb  *heapCb,
 Data       **ptr,
 Size        *size,
-U32        memType,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t        memType,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -3965,10 +3965,10 @@ PRIVATE S16  cmHeapAlloc (heapCb, ptr, size, memType, line, fileName, entId, hst
 CmMmHeapCb  *heapCb;
 Data       **ptr;
 Size        *size;
-U32        memType;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t        memType;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #else
@@ -3978,9 +3978,9 @@ PRIVATE S16  cmHeapAlloc
 CmMmHeapCb  *heapCb,
 Data       **ptr,
 Size        *size,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -3988,9 +3988,9 @@ PRIVATE S16  cmHeapAlloc (heapCb, ptr, size, line, fileName, entId, hstReg)
 CmMmHeapCb  *heapCb;
 Data       **ptr;
 Size        *size;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #endif /* SSI_DEBUG_LEVEL1 */
@@ -4002,14 +4002,14 @@ PRIVATE S16  cmHeapAlloc
 CmMmHeapCb  *heapCb,
 Data       **ptr,
 Size        *size,
-U32        memType
+uint32_t        memType
 )
 #else
 PRIVATE S16  cmHeapAlloc (heapCb, ptr, size, memType)
 CmMmHeapCb  *heapCb;
 Data       **ptr;
 Size        *size;
-U32        memType;
+uint32_t        memType;
 #endif
 #else
 #ifdef ANSI
@@ -4041,7 +4041,7 @@ Size        *size;
    CmHEntry *alocHeapBlk;
    Size requestedSize;
    Size hdr;
-   U16 idx;
+   uint16_t idx;
 #endif /* SSI_DEBUG_LEVEL1 */
 /*  cm_mem_c_001.main_15 : Additions */
 #ifdef SS_HISTOGRAM_SUPPORT 
@@ -4321,9 +4321,9 @@ PRIVATE S16  cmHeapFree
 CmMmHeapCb  *heapCb,
 Data        *ptr,
 Size         size,
-U32     line,
-U8     *fileName,
-U8      entId,
+uint32_t     line,
+uint8_t     *fileName,
+uint8_t      entId,
 Bool    hstReg
 )
 #else
@@ -4331,9 +4331,9 @@ PRIVATE S16  cmHeapFree (heapCb, ptr, size, line, fileName, entId, hstReg)
 CmMmHeapCb  *heapCb;
 Data        *ptr;
 Size         size;
-U32     line;
-U8     *fileName;
-U8      entId;
+uint32_t     line;
+uint8_t     *fileName;
+uint8_t      entId;
 Bool    hstReg;
 #endif
 #else
@@ -4725,12 +4725,12 @@ Size         size;
 #endif/*USE_PURE*/
 #ifdef SS_LIGHT_MEM_LEAK_STS
 #ifdef ANSI
-U32 cmGetFreeIndx
+uint32_t cmGetFreeIndx
 (
 Void
 )
 #else
-U32 cmGetFreeIndx(Void)
+uint32_t cmGetFreeIndx(Void)
 #endif
 {
 
@@ -4741,24 +4741,24 @@ U32 cmGetFreeIndx(Void)
     }
     else
     {
-       U32 allocQIndx = gmemLkCb.queue[gmemLkCb.head];
+       uint32_t allocQIndx = gmemLkCb.queue[gmemLkCb.head];
        gmemLkCb.head = (gmemLkCb.head +1) % CM_MAX_ALLOC_ENTERIES;
        return (allocQIndx);
     }
  
 }
 #ifdef ANSI
-U32 cmPutFreeIndx
+uint32_t cmPutFreeIndx
 (
-U32   allocQIndx
+uint32_t   allocQIndx
 )
 #else
-U32 cmPutFreeIndx(allocQIndx)
-U32   allocQIndx;
+uint32_t cmPutFreeIndx(allocQIndx)
+uint32_t   allocQIndx;
 #endif
 
 {
-    U32 tmpTail = (gmemLkCb.tail+1)% CM_MAX_ALLOC_ENTERIES;
+    uint32_t tmpTail = (gmemLkCb.tail+1)% CM_MAX_ALLOC_ENTERIES;
     if(tmpTail == gmemLkCb.head)
     {
        allocQueueFullCnt++;
@@ -4778,7 +4778,7 @@ U32   allocQIndx;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -4795,7 +4795,7 @@ Void
 Void cmInitMemLeak (Void)
 #endif
 {
-   U32   indx;  
+   uint32_t   indx;  
 
 
    gmemLkCb.isStarted = FALSE;
@@ -4808,7 +4808,7 @@ Void cmInitMemLeak (Void)
       cmPutFreeIndx(indx);
    }
 
-   RETVOID;
+   return;
 } /* cmInitMemLeak */
 /*
  *
@@ -4817,7 +4817,7 @@ Void cmInitMemLeak (Void)
  * Desc:  De-initializes the memory leak detection
  * 
  * 
- * Ret:   RETVOID
+ * Ret:   void
  * 
  * Notes: This function de-initializes the memory leak detection module.
  * 
@@ -4834,7 +4834,7 @@ Void
 Void cmDeinitMemLeak (Void)
 #endif
 {
-   U32   indx;  
+   uint32_t   indx;  
 
  
    for(indx = 0; indx < CM_MAX_ALLOC_ENTERIES; indx++)
@@ -4845,7 +4845,7 @@ Void cmDeinitMemLeak (Void)
    gmemLkCb.isStarted = FALSE;
    gmemLkCb.head      = 0;
    gmemLkCb.tail      = 0;
-   RETVOID;
+   return;
 }
 /*
 *
@@ -4854,7 +4854,7 @@ Void cmDeinitMemLeak (Void)
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -4863,17 +4863,17 @@ Void cmDeinitMemLeak (Void)
 *
 */
 #ifdef ANSI
-U32 cmStorAllocBlk
+uint32_t cmStorAllocBlk
 (
 Void    *addr
 )
 #else
-U32 cmStorAllocBlk (addr)
+uint32_t cmStorAllocBlk (addr)
 Void    *addr;
 #endif /* ANSI */
 
 {
-   U32 allocQIndx;
+   uint32_t allocQIndx;
 
   (Void) SLock(&gmemLkCb.memLock);
    allocQIndx = cmGetFreeIndx();
@@ -4896,7 +4896,7 @@ Void    *addr;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -4907,11 +4907,11 @@ Void    *addr;
 #ifdef ANSI
 Void cmRlsAllocBlk
 (
-U32    allocQIndx
+uint32_t    allocQIndx
 )
 #else
 Void cmRlsAllocBlk(allocQIndx)
-U32    allocQIndx;
+uint32_t    allocQIndx;
 #endif
 {
    
@@ -4926,7 +4926,7 @@ U32    allocQIndx;
          (Void) SUnlock(&(gmemLkCb.memLock));
       }
    }
-   RETVOID;
+   return;
 } /* cmRlsAllocBlk */
 
 /*
@@ -4960,7 +4960,7 @@ Void cmStartStopLeakLog(Void)
       printf("!!leak capturing stopped\n");
       cmPrintLeakLog();
    }
-   RETVOID;
+   return;
 }
 
 /*
@@ -4986,9 +4986,9 @@ Void cmPrintLeakLog(Void)
 #endif
 {
  
-   U32   indx;  
+   uint32_t   indx;  
    CmMmBlkHdr *aBkt;
-   static U32 leakCount =0; 
+   static uint32_t leakCount =0; 
 
 
    printf("---- START OF LEAK LOG ----");
@@ -5014,7 +5014,7 @@ Void cmPrintLeakLog(Void)
    SUnlock(&gmemLkCb.memLock);
    printf("---- Lock Released ----");
    leakCount =0; 
-   RETVOID;
+   return;
 }
 #endif
 
@@ -5027,7 +5027,7 @@ Void cmPrintLeakLog(Void)
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5052,25 +5052,25 @@ CmMmRegCb *regCb;
 Void cmRlsAllocBlk
 (
 #ifdef BIT_64
-U64    addr
+uint64_t    addr
 #else
-U32    addr
+uint32_t    addr
 #endif
 )
 #else
 Void cmRlsAllocBlk(addr)
 #ifdef BIT_64
-U64    addr;
+uint64_t    addr;
 #else
-U32    addr;
+uint32_t    addr;
 #endif
 #endif
 #endif
 {
     Ptr           trace[CM_MAX_STACK_TRACE];
     S8            **funcNm;
-    U8            idx;
-    U8            i;
+    uint8_t            idx;
+    uint8_t            i;
     S16           retVal;
     S32           traceSize;
 #ifndef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
@@ -5080,11 +5080,11 @@ U32    addr;
 
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
 #ifdef BIT_64
-    retVal = cmHashListFind(&regCb->brdcmSsiLstCp,(U8 *)&ptrHdr,
-                   (U16)sizeof(U64), 0, (PTR *)&ptrHdr);                              
+    retVal = cmHashListFind(&regCb->brdcmSsiLstCp,(uint8_t *)&ptrHdr,
+                   (uint16_t)sizeof(uint64_t), 0, (PTR *)&ptrHdr);                              
 #else
-    retVal = cmHashListFind(&regCb->brdcmSsiLstCp,(U8 *)&ptrHdr,
-                   (U16)sizeof(U32), 0, (PTR *)&ptrHdr);                              
+    retVal = cmHashListFind(&regCb->brdcmSsiLstCp,(uint8_t *)&ptrHdr,
+                   (uint16_t)sizeof(uint32_t), 0, (PTR *)&ptrHdr);                              
 #endif
     if(retVal == ROK)
     {
@@ -5093,18 +5093,18 @@ U32    addr;
 #else
     if( memLkCb.memLkMdlInit == FALSE)
     {
-      RETVOID;
+      return;
     }
     for(idx = 0; idx < CM_MEM_USR_MDL; idx++)
     {
        SLock(&memLkCb.memUsrMdl[idx][addr & 0x3].memLck);
 #ifdef BIT_64
        retVal = cmHashListFind(&memLkCb.memUsrMdl[idx][addr & 0x3].memHashCp,
-                               (U8 *)&addr, sizeof(U64), 0,
+                               (uint8_t *)&addr, sizeof(uint64_t), 0,
                                (PTR *)&memAllocInfo);      
 #else
        retVal = cmHashListFind(&memLkCb.memUsrMdl[idx][addr & 0x3].memHashCp,
-                               (U8 *)&addr, sizeof(U32), 0,
+                               (uint8_t *)&addr, sizeof(uint32_t), 0,
                                (PTR *)&memAllocInfo);                              
 #endif                 
        if(retVal == ROK)
@@ -5196,7 +5196,7 @@ U32    addr;
 #endif /* SS_MEM_LEAK_SOL */
 #endif/* BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1 */
    /*cm_mem_c_001.main_25 : */
-   RETVOID;
+   return;
 } /* cmRlsAllocBlk */
 
 
@@ -5207,7 +5207,7 @@ U32    addr;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5222,7 +5222,7 @@ Void cmStorAllocBlk
 CmMmBlkHdr    *ptrHdr, 
 Size          reqSz,
 Size          allocSz,
-U16           bktIdx,
+uint16_t           bktIdx,
 CmMmRegCb     *regCb
 )
 #else
@@ -5230,7 +5230,7 @@ Void cmStorAllocBlk (ptrHdr, reqSz, allocSz, bktIdx, regCb)
 CmMmBlkHdr    *ptrHdr;
 Size          reqSz;
 Size          allocSz;
-U16           bktIdx;
+uint16_t           bktIdx;
 CmMmRegCb     *regCb;
 #endif
 #else
@@ -5238,24 +5238,24 @@ CmMmRegCb     *regCb;
 Void cmStorAllocBlk
 (
 #ifdef BIT_64
-U64    addr,
+uint64_t    addr,
 #else
-U32    addr,
+uint32_t    addr,
 #endif
 Size   reqSz,
 Size   allocSz,
-U16    bktIdx
+uint16_t    bktIdx
 )
 #else
 Void cmStorAllocBlk (addr, reqSz, allocSz, bktIdx)
 #ifdef BIT_64
-U64    addr;
+uint64_t    addr;
 #else
-U32    addr;
+uint32_t    addr;
 #endif
 Size   reqSz;
 Size   allocSz;
-U16    bktIdx;
+uint16_t    bktIdx;
 #endif /* ANSI */
 #endif /* BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1 */
 {
@@ -5263,10 +5263,10 @@ U16    bktIdx;
   void           *trace[CM_MAX_STACK_TRACE];
 #endif  /* SS_MEM_LEAK_SOL */
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
-   U8            btrIdx;
+   uint8_t            btrIdx;
 #else
    MemAllocInfo  *allocInfo;
-   U8            moduleId;
+   uint8_t            moduleId;
    S8            **funcNm;
    S32           traceSize;
 #endif
@@ -5274,7 +5274,7 @@ U16    bktIdx;
 #ifndef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
    if( memLkCb.memLkMdlInit == FALSE)
    {
-     RETVOID;
+     return;
    }
 #endif
 #ifdef SS_MEM_LEAK_SOL
@@ -5283,12 +5283,12 @@ U16    bktIdx;
     * implementation. */
 /*cm_mem_c_001.main_27 SSI-4GMX specfic changes*/   
 #ifdef SS_4GMX_LCORE
-   funcNm = (S8 **)MxHeapAlloc(SsiHeap, (sizeof(U32) * CM_MAX_STACK_TRACE));
-   memset(funcNm, 0, (sizeof(U32) * CM_MAX_STACK_TRACE));
+   funcNm = (S8 **)MxHeapAlloc(SsiHeap, (sizeof(uint32_t) * CM_MAX_STACK_TRACE));
+   memset(funcNm, 0, (sizeof(uint32_t) * CM_MAX_STACK_TRACE));
 #else
-   funcNm = (S8 **)calloc(1, (sizeof(U32) * CM_MAX_STACK_TRACE));
+   funcNm = (S8 **)calloc(1, (sizeof(uint32_t) * CM_MAX_STACK_TRACE));
 #endif
-       /* SGetSBuf(DFLT_REGION, DFLT_POOL, &funcNm, sizeof(U32) * CM_MAX_STACK_TRACE); */
+       /* SGetSBuf(DFLT_REGION, DFLT_POOL, &funcNm, sizeof(uint32_t) * CM_MAX_STACK_TRACE); */
    traceSize = backtrace((Void **)funcNm, CM_MAX_STACK_TRACE);
 #else /* SS_MEM_LEAK_SOL */
 #ifndef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
@@ -5322,7 +5322,7 @@ U16    bktIdx;
    ptrHdr->allocSz    = allocSz;
    ptrHdr->bktIdx     = bktIdx;
    cmHashListInsert(&regCb->brdcmSsiLstCp, (PTR)ptrHdr,
-         (U8 *)&(ptrHdr), sizeof(PTR));
+         (uint8_t *)&(ptrHdr), sizeof(PTR));
 #else
    allocInfo->memAddr    = addr;
    allocInfo->reqSz      = reqSz;
@@ -5332,18 +5332,18 @@ U16    bktIdx;
    allocInfo->moduleId   = moduleId;
    allocInfo->bTrcSz     = traceSize;
    cmHashListInsert(&memLkCb.memUsrMdl[moduleId][addr & 0x3].memHashCp, 
-                    (PTR)allocInfo, (U8 *)&(allocInfo->memAddr),
+                    (PTR)allocInfo, (uint8_t *)&(allocInfo->memAddr),
                     sizeof(allocInfo->memAddr));
    memLkCb.memUsrMdl[moduleId][addr & 0x3].used = TRUE;
 
    (Void) SUnlock(&(memLkCb.memUsrMdl[moduleId][addr & 0x3].memLck));
 #endif
-   RETVOID;
+   return;
 } /* cmStorAllocBlk */
 
 /*
 *
-   RETVOID;
+   return;
 } /* cmStorAllocBlk */
 
 /*
@@ -5353,7 +5353,7 @@ U16    bktIdx;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5371,8 +5371,8 @@ Void SLogLkInfo (Void)
 #endif
 {
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL2
-   U8                 idx;
-   U8                 regionIdx;
+   uint8_t                 idx;
+   uint8_t                 regionIdx;
    Txt                prntBuf[255];
    S8                 **funcNm;
    CmMmBlkHdr         *newBlkHdr;
@@ -5432,14 +5432,14 @@ Void SLogLkInfo (Void)
 #else
    MemAllocInfo      *oldMemInfo;
    MemAllocInfo      *newMemInfo;
-   U8                 memMdl;  
-   U8                 hashIdx;  
-   U8                 idx;
+   uint8_t                 memMdl;  
+   uint8_t                 hashIdx;  
+   uint8_t                 idx;
    Txt                prntBuf[255];
    S8                 **funcNm;
    if( memLkCb.memLkMdlInit == FALSE)
    {
-     RETVOID;
+     return;
    }
    sprintf(prntBuf, "\n------- START OF LEAK LOG -------\n");
    fwrite(prntBuf, strlen(prntBuf), 1, memLkCb.fileLkLog);
@@ -5496,7 +5496,7 @@ Void SLogLkInfo (Void)
    sprintf(prntBuf, "\n------- END OF LEAK LOG -------\n");
    fwrite(prntBuf, strlen(prntBuf), 1, memLkCb.fileLkLog);
 #endif
-   RETVOID;
+   return;
 }
 
 #endif
@@ -5510,7 +5510,7 @@ Void SLogLkInfo (Void)
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5527,8 +5527,8 @@ Void
 Void cmInitMemLeakMdl (Void)
 #endif
 {
-   U8   memMdl;
-       U8   hashIdx;
+   uint8_t   memMdl;
+       uint8_t   hashIdx;
 
 
    memLkCb.memLkMdlInit = FALSE;
@@ -5538,7 +5538,7 @@ Void cmInitMemLeakMdl (Void)
                {
        SInitLock(&memLkCb.memUsrMdl[memMdl][hashIdx].memLck, 1);
        cmHashListInit(&memLkCb.memUsrMdl[memMdl][hashIdx].memHashCp,
-                      500, 0, FALSE, CM_HASH_KEYTYPE_U32MOD, 0, 0);
+                      500, 0, FALSE, CM_HASH_KEYTYPE_UINT32_MOD, 0, 0);
        memLkCb.memUsrMdl[memMdl][hashIdx].used = FALSE;
                }
    }
@@ -5548,7 +5548,7 @@ Void cmInitMemLeakMdl (Void)
    }
    memLkCb.memLkMdlInit = TRUE;
 
-   RETVOID;
+   return;
 } /* cmInitMemLeakMdl */
 /* cm_mem_c_002.main_21 Added for shutdown procedure */
 /*
@@ -5558,7 +5558,7 @@ Void cmInitMemLeakMdl (Void)
  * Desc:  De-initializes the memory leak detection module
  * 
  * 
- * Ret:   RETVOID
+ * Ret:   void
  * 
  * Notes: This function de-initializes the memory leak detection module.
  * 
@@ -5575,8 +5575,8 @@ Void
 Void cmDeinitMemLeakMdl (Void)
 #endif
 {
-  U8   memMdl;
-  U8   hashIdx;
+  uint8_t   memMdl;
+  uint8_t   hashIdx;
 
 
   memLkCb.memLkMdlInit = FALSE;
@@ -5589,7 +5589,7 @@ Void cmDeinitMemLeakMdl (Void)
                memLkCb.memUsrMdl[memMdl][hashIdx].used = FALSE;
         }
   }
-  RETVOID;
+  return;
 }
 /*
 *
@@ -5598,7 +5598,7 @@ Void cmDeinitMemLeakMdl (Void)
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5618,7 +5618,7 @@ S8 *msOptArg;
 {
    memLkCb.fileLkLog = NULLP;
    memLkCb.fileLkLog = fopen(arg, "w");
-   RETVOID;
+   return;
 }
 /*
 *
@@ -5627,7 +5627,7 @@ S8 *msOptArg;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5645,16 +5645,16 @@ Void SFlushLkInfo (Void)
 #endif
 {
    MemAllocInfo      *newMemInfo;
-   U8                 memMdl;
-   U8                 hashIdx;
+   uint8_t                 memMdl;
+   uint8_t                 hashIdx;
    S8                 **funcNm;
 #ifdef SS_MEM_LEAK_SOL
-   U8                 i;
+   uint8_t                 i;
 #endif /* SS_MEM_LEAK_SOL */
 
    if( memLkCb.memLkMdlInit == FALSE)
    {
-     RETVOID;
+     return;
    }
 
    for(memMdl = 0; memMdl < CM_MEM_USR_MDL; memMdl++)
@@ -5680,7 +5680,7 @@ Void SFlushLkInfo (Void)
 #else
                 free(funcNm[i]); 
 #endif
-                                   /* SPutSBuf(DFLT_REGION, DFLT_POOL, funcNm[i], sizeof(U32) * CM_MAX_STACK_TRACE); */
+                                   /* SPutSBuf(DFLT_REGION, DFLT_POOL, funcNm[i], sizeof(uint32_t) * CM_MAX_STACK_TRACE); */
              }
 #endif /* SS_MEM_LEAK_SOl */
 /*cm_mem_c_001.main_27 SSI-4GMX specfic changes*/   
@@ -5695,7 +5695,7 @@ Void SFlushLkInfo (Void)
          SUnlock(&memLkCb.memUsrMdl[memMdl][hashIdx].memLck);
                }
     }
-    RETVOID;
+    return;
 }
 /*
 *
@@ -5704,7 +5704,7 @@ Void SFlushLkInfo (Void)
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5713,20 +5713,20 @@ Void SFlushLkInfo (Void)
 *
 */
 #ifdef ANSI
-U8 cmMemGetModuleId
+uint8_t cmMemGetModuleId
 (
 S8     **funNm,
 S32    traceSize
 )
 #else
-U8 cmMemGetModuleId (funNm, traceSize)
+uint8_t cmMemGetModuleId (funNm, traceSize)
 S8     **funNm;
 S32    traceSize;
 #endif /* ANSI */
 {
-   U8    idx;
-   U8    memStrIdx;
-   U32   len;
+   uint8_t    idx;
+   uint8_t    memStrIdx;
+   uint32_t   len;
    S32   retVal;
    S16   memReqIdx;
    S16   mdlFunStrIdx;
@@ -5780,7 +5780,7 @@ S32    traceSize;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5791,25 +5791,25 @@ S32    traceSize;
 #ifdef ANSI
 S16 cmMemGetStrMtchIdx  
 (
-U8 strtIdx, 
-U8 endIdx,
+uint8_t strtIdx, 
+uint8_t endIdx,
 S8 *str, 
 S8 **strLst
 )
 #else
 S16 cmMemGetStrMtchIdx(strtIdx, endIdx, str, strLst)
-U8 strtIdx;
-U8 endIdx;
+uint8_t strtIdx;
+uint8_t endIdx;
 S8 *str;
 S8 **strLst;
 #endif
 {
 
    S8   cmpStr[255];
-   U32  len;
+   uint32_t  len;
    Bool found;
-   U32  tempLen;
-   U8   idx;
+   uint32_t  tempLen;
+   uint8_t   idx;
    S32  retVal;
 
    len = strlen((const S8 *)str);
@@ -5853,7 +5853,7 @@ S8 **strLst;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5909,7 +5909,7 @@ S32    size;
 *       Desc:  Initializes the memory leak detection module
 *
 *
-*       Ret:   RETVOID
+*       Ret:   void
 *
 *       Notes: This function initializes the memory leak detection module.
 *
@@ -5995,7 +5995,7 @@ CmMmBlkHdr *blkPtr;
 #endif
 #endif
 {
-   U32 sigCnt;
+   uint32_t sigCnt;
 #ifdef BRDCM_SSI_MEM_LEAK_DEBUG_LEVEL1
    CmMmBlkTail  *tailPtr;
 #endif
@@ -6052,7 +6052,7 @@ CmMmBkt  *bkt;
 #endif
 {
    CmMmBlkHdr *ptrBlk;
-   U32 blkCnt;
+   uint32_t blkCnt;
 
    bkt->trampleCount = 0;
 
@@ -6143,18 +6143,18 @@ CmMmHeapCb  *heapCb;
 PRIVATE S16 cmMmHashFunc
 (
 CmMmHashListCp *hashListCp,
-U32 key,
-U16 *idx
+uint32_t key,
+uint16_t *idx
 )
 #else
 PRIVATE S16 cmMmHashFunc (hashListCp, key, idx)
 CmMmHashListCp *hashListCp; /* hash list control point */
-U32 key; /* key string */
-U16 *idx; /* idx to return */
+uint32_t key; /* key string */
+uint16_t *idx; /* idx to return */
 #endif
 {
 
-   *idx = (U16)(key % hashListCp->numOfbins);
+   *idx = (uint16_t)(key % hashListCp->numOfbins);
 
    return ROK;
 
@@ -6185,19 +6185,19 @@ U16 *idx; /* idx to return */
 PRIVATE S16 cmMmHashListInit
 (
 CmMmHashListCp *hashListCp,  /* hash list to initialize */
-U16          nmbBins,      /* number of hash list bins */
+uint16_t          nmbBins,      /* number of hash list bins */
 Region       region,       /* memory region to allocate bins */
 Pool         pool          /* memory pool to allocate bins */
 )
 #else
 PRIVATE S16 cmMmHashListInit(hashListCp, nmbBins, region, pool)
 CmMmHashListCp *hashListCp;  /* hash list to initialize */
-U16          nmbBins;      /* number of hash list bins */
+uint16_t          nmbBins;      /* number of hash list bins */
 Region       region;       /* memory region to allocate bins */
 Pool         pool;         /* memory pool to allocate bins */
 #endif
 {
-   U16 i;
+   uint16_t i;
    CmMmHashListEnt *hl;
 
 
@@ -6296,17 +6296,17 @@ Pool         pool;         /* memory pool to allocate bins */
 PRIVATE S16 cmMmHashListInsert
 (
 CmMmHashListCp *hashListCp,  /* hash list to add to */
-U32           key         /* pointer to key */
+uint32_t           key         /* pointer to key */
 )
 #else
 PRIVATE S16 cmMmHashListInsert(hashListCp, key)
 CmMmHashListCp *hashListCp;  /* hash list to add to */
-U32           key;         /* pointer to key */
+uint32_t           key;         /* pointer to key */
 #endif
 {
    CmMmHashListEnt *hashListEnt;    /* pointer to hash list entry header */
-   U16 idx;                       /* index for insertion into hash list */
-   U16 i;
+   uint16_t idx;                       /* index for insertion into hash list */
+   uint16_t i;
 
 
    /* check if hashListCp is initialised yet */
@@ -6464,23 +6464,23 @@ CmHstGrmHashListCp *hashListCp;  /* hash list to initialize */
 PRIVATE S16 cmHstGrmFreeInsert
 (
 CmHstGrmHashListCp* hashListCp, /* hash list cp */
-U32        blkSz, /* size of the block freed */
-U32       line, /* Line number */
-U8        *fileName, /* file name */
-U8        entId    /* Tapa task which free the memory */
+uint32_t        blkSz, /* size of the block freed */
+uint32_t       line, /* Line number */
+uint8_t        *fileName, /* file name */
+uint8_t        entId    /* Tapa task which free the memory */
 )
 #else
 PRIVATE S16 cmHstGrmFreeInsert(hashListCp, blkSz, line, fileName, entId)
 CmHstGrmHashListCp* hashListCp; /* hash list cp */
-U32        blkSz; /* size of the block freed */
-U32       line; /* line number */
-U8        *fileName; /* file Name */
-U8        entId; /* Tapa task which frees the memory */
+uint32_t        blkSz; /* size of the block freed */
+uint32_t       line; /* line number */
+uint8_t        *fileName; /* file Name */
+uint8_t        entId; /* Tapa task which frees the memory */
 #endif
 {
-   U32                    binIdx = 0; /* Bin index to insert the entry into the hash list */
-   U32                    key = 0; /* Key to fine the bin index */
-   U32                    ret = 0; /* Return value */
+   uint32_t                    binIdx = 0; /* Bin index to insert the entry into the hash list */
+   uint32_t                    key = 0; /* Key to fine the bin index */
+   uint32_t                    ret = 0; /* Return value */
    CmMemEntries           *entry = NULLP; /* Entry which contains the information */
 
 
@@ -6546,25 +6546,25 @@ U8        entId; /* Tapa task which frees the memory */
 PRIVATE S16 cmHstGrmAllocInsert
 (
 CmHstGrmHashListCp     *hashListCp,
-U32       blkSz,
-U32       *reqSz,
-U32       line,
-U8        *fileName,
-U8        entId
+uint32_t       blkSz,
+uint32_t       *reqSz,
+uint32_t       line,
+uint8_t        *fileName,
+uint8_t        entId
 )
 #else
 PRIVATE  S16 cmHstGrmAllocInsert(hashListCp, blkSz, reqSz, line, fileName, entId)
 CmHstGrmHashListCp     *hashListCp;
-U32       blkSz;
-U32       *reqSz;
-U32       line;
-U8        *fileName;
-U8        entId;
+uint32_t       blkSz;
+uint32_t       *reqSz;
+uint32_t       line;
+uint8_t        *fileName;
+uint8_t        entId;
 #endif
 {
-   U32                    binIdx = 0;
-   U32                    key = 0;
-   U32                    ret = 0;
+   uint32_t                    binIdx = 0;
+   uint32_t                    key = 0;
+   uint32_t                    ret = 0;
    CmMemEntries           *entry = NULLP;
 
 
@@ -6632,21 +6632,21 @@ U8        entId;
 #ifdef ANSI
 PRIVATE S16 cmHstGrmGetHashIdxAndKey
 (
-U8                 *fileName,
-U32                line,
-U32                *binIdx,
-U32                *key
+uint8_t                 *fileName,
+uint32_t                line,
+uint32_t                *binIdx,
+uint32_t                *key
 )
 #else
 PRIVATE  S16 cmHstGrmGetHashIdxAndKey(fileName, line, binIdx, key)
-U8                 *fileName;
-U32                line;
-U32                *binIdx;
-U32                *key;
+uint8_t                 *fileName;
+uint32_t                line;
+uint32_t                *binIdx;
+uint32_t                *key;
 #endif
 {
 
-   U32  i = 0;
+   uint32_t  i = 0;
 
    /* Calculate the key using file name and line number */
    for(i = 0 ; fileName[i] != '\0'; i++)
@@ -6682,22 +6682,22 @@ U32                *key;
 PRIVATE S16 cmHstGrmFillEntry
 (
 CmMemEntries       *entry,
-U32                key,
-U32                line,
-U8                 *fileName,
-U8                 entId
+uint32_t                key,
+uint32_t                line,
+uint8_t                 *fileName,
+uint8_t                 entId
 )
 #else
 PRIVATE  S16 cmHstGrmFillEntry(entry, key, line, fileName, entId)
 CmMemEntries       *entry;
-U32                key;
-U32                line;
-U8                 *fileName;
-U8                 entId;
+uint32_t                key;
+uint32_t                line;
+uint8_t                 *fileName;
+uint8_t                 entId;
 #endif
 {
 
-   U32       idx = 0;
+   uint32_t       idx = 0;
    entry->key = key;
    entry->line = line;
    entry->entId = entId;
@@ -6730,21 +6730,21 @@ U8                 entId;
 PRIVATE S16 cmHstGrmFindEntry
 (
 CmHstGrmHashListCp  *hashListCp,
-U32                 key,
-U32                 *binIdx,
+uint32_t                 key,
+uint32_t                 *binIdx,
 CmMemEntries        **entry
 )
 #else
 PRIVATE  S16 cmHstGrmFindEntry(hashListCp, key, binIdx, entry)
 CmHstGrmHashListCp  *hashListCp;
-U32                 key;
-U32                 *binIdx;
+uint32_t                 key;
+uint32_t                 *binIdx;
 CmMemEntries        **entry;
 #endif
 {
 
-   U32                  numEnt = 0;
-   U32                  numBin = 0;
+   uint32_t                  numEnt = 0;
+   uint32_t                  numBin = 0;
    CmHstGrmHashListEnt  *tmpBin = NULLP;
 
    for(numBin = 0; numBin < CMM_HIST_MAX_MEM_BIN; numBin++)