FreeCalypso > hg > freecalypso-sw
diff gsm-fw/gpf/osl/os_mem_fl.c @ 375:1319bd1d5ac3
os_mem_fl.c: os_GetPrimpoolCB() done
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Mon, 09 Jun 2014 04:10:07 +0000 |
parents | 3efb28578dad |
children | 754e72d134a0 |
line wrap: on
line diff
--- a/gsm-fw/gpf/osl/os_mem_fl.c Mon Jun 09 03:31:20 2014 +0000 +++ b/gsm-fw/gpf/osl/os_mem_fl.c Mon Jun 09 04:10:07 2014 +0000 @@ -175,3 +175,22 @@ break; NU_Deallocate_Memory(Buffer); } + +GLOBAL const ULONG * +os_GetPrimpoolCB(int grp, int id) +{ + T_OS_PART_POOL *pool; + int i; + + pool = PartGrpTable[grp].grp_head; + if (!pool) + return(0); + if (id < 0) + return(0); + for (i = 0; i < id; i++) { + pool = pool->next; + if (!pool) + return(0); + } + return (const ULONG *) &pool->pcb; +}