3b8db22db338fccb9206ceffb8a8c8b4e2d13a42
[reactos.git] / reactos / include / ddk / mmtypes.h
1 #ifndef _INCLUDE_DDK_MMTYPES_H
2 #define _INCLUDE_DDK_MMTYPES_H
3 /* $Id: mmtypes.h,v 1.4 2000/04/02 13:32:38 ea Exp $ */
4
5
6 typedef struct _MADDRESS_SPACE
7 {
8 LIST_ENTRY MAreaListHead;
9 KMUTEX Lock;
10 ULONG LowestAddress;
11 } MADDRESS_SPACE, *PMADDRESS_SPACE;
12
13 #define MDL_MAPPED_TO_SYSTEM_VA (0x1)
14 #define MDL_PAGES_LOCKED (0x2)
15 #define MDL_SOURCE_IS_NONPAGED_POOL (0x4)
16 #define MDL_ALLOCATED_FIXED_SIZE (0x8)
17 #define MDL_PARTIAL (0x10)
18 #define MDL_PARTIAL_HAS_BEEN_MAPPED (0x20)
19 #define MDL_IO_PAGE_READ (0x40)
20 #define MDL_WRITE_OPERATION (0x80)
21 #define MDL_PARENT_MAPPED_SYSTEM_VA (0x100)
22 #define MDL_LOCK_HELD (0x200)
23 #define MDL_SCATTER_GATHER_VA (0x400)
24 #define MDL_IO_SPACE (0x800)
25 #define MDL_NETWORK_HEADER (0x1000)
26 #define MDL_MAPPING_CAN_FAIL (0x2000)
27 #define MDL_ALLOCATED_MUST_SUCCEED (0x4000)
28 #define MDL_64_BIT_VA (0x8000)
29
30
31 typedef struct _MDL
32 /*
33 * PURPOSE: Describes a user buffer passed to a system API
34 */
35 {
36 struct _MDL* Next;
37 CSHORT Size;
38 CSHORT MdlFlags;
39 struct _EPROCESS* Process;
40 PVOID MappedSystemVa;
41 PVOID StartVa;
42 ULONG ByteCount;
43 ULONG ByteOffset;
44 } MDL, *PMDL;
45
46 #define MmSmallSystem (0)
47 #define MmMediumSystem (1)
48 #define MmLargeSystem (2)
49 /* Used in MmFlushImageSection */
50 typedef
51 enum _MMFLUSH_TYPE
52 {
53 MmFlushForDelete,
54 MmFlushForWrite
55
56 } MMFLUSH_TYPE;
57
58 typedef
59 enum _MEMORY_CACHING_TYPE
60 {
61 MmNonCached = FALSE,
62 MmCached = TRUE,
63 MmFrameBufferCached,
64 MmHardwareCoherentCached,
65 MmMaximumCacheType
66
67 } MEMORY_CACHING_TYPE;
68
69 #endif