annotate gsm-fw/gpf/osl/os_mem_fl.c @ 370:37e19cbbbc8d

OSL: os_mem_fl.c started
author Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
date Fri, 30 May 2014 08:18:21 +0000
parents
children 8df6f38d2f3a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
370
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
1 /*
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
2 * This C module is a reconstruction based on the disassembly of
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
3 * os_mem.obj in frame_na7_db_fl.lib from the Leonardo package.
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
4 */
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
5
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
6 /* set of included headers from COFF symtab: */
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
7 #include <stdio.h>
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
8 #include <string.h>
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
9 #include "gpfconf.h" /* FreeCalypso addition */
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
10 #include "../../nucleus/nucleus.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
11 #include "typedefs.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
12 #include "os.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
13 #include "gdi.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
14 #include "os_types.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
15 #include "os_glob.h"
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
16
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
17 extern T_OS_PART_GRP_TABLE_ENTRY PartGrpTable[];
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
18 extern T_OS_MEM_POOL_TABLE_ENTRY MemPoolTable[];
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
19 extern T_OS_POOL_BORDER PoolBorder[];
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
20
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
21 OS_HANDLE os_ext_pool_handle;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
22 OS_HANDLE os_int_pool_handle;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
23
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
24 static USHORT NumOfMemoryPools;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
25 static USHORT Idx;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
26 static T_OS_PART_POOL *part_pool;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
27 static int grp_hndl;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
28 static NU_SEMAPHORE MemSemCB;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
29 static NU_MEMORY_POOL mem_pool_head;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
30
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
31 GLOBAL LONG
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
32 os_SetPoolHandles(OS_HANDLE ext_pool_handle, OS_HANDLE int_pool_handle)
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
33 {
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
34 os_ext_pool_handle = ext_pool_handle;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
35 os_int_pool_handle = int_pool_handle;
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
36 return(OS_OK);
37e19cbbbc8d OSL: os_mem_fl.c started
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
37 }