]> 4ch.mooo.com Git - 16.git/blob - src/lib/xms.h
16_pm worked on~
[16.git] / src / lib / xms.h
1 #ifndef _XMS_H_\r
2 #define _XMS_H_\r
3 #include <stddef.h> /* Definition of NULL */\r
4 #include <limits.h> /* Definition of UINT_MAX */\r
5 #include <stdio.h>  /* fprintf and (FILE *) */\r
6 \r
7 /* Allow external configuration of maximum concurrent XMS allocations */\r
8 #ifndef MAX_XMS_ALLOCATIONS\r
9 #define MAX_XMS_ALLOCATIONS 4\r
10 #endif\r
11 \r
12 /* Address of the XMS driver */\r
13 static long XMSControl;\r
14 \r
15 /* Mapping of XMS handle <-> normal pointer */\r
16 typedef struct {\r
17         unsigned int XMSHandle;\r
18         void huge * XMSPointer;\r
19 } XMSHandleMap;\r
20 \r
21 static XMSHandleMap allocMapXMS[MAX_XMS_ALLOCATIONS];\r
22 \r
23 static int initxms(void);\r
24 void huge * xmsmalloc(long unsigned int size);\r
25 void xmsfree(void huge * XMSPointer);\r
26 void xmsreport(void/*FILE * stream*/);\r
27 \r
28 #endif/*_XMS_H_*/\r