.. | .. |
---|
10 | 10 | #define PROT_GROWSDOWN 0x01000000 /* mprotect flag: extend change to start of growsdown vma */ |
---|
11 | 11 | #define PROT_GROWSUP 0x02000000 /* mprotect flag: extend change to end of growsup vma */ |
---|
12 | 12 | |
---|
13 | | -#define MAP_SHARED 0x01 /* Share changes */ |
---|
14 | | -#define MAP_PRIVATE 0x02 /* Changes are private */ |
---|
15 | | -#define MAP_SHARED_VALIDATE 0x03 /* share + validate extension flags */ |
---|
| 13 | +/* 0x01 - 0x03 are defined in linux/mman.h */ |
---|
16 | 14 | #define MAP_TYPE 0x2b /* Mask for type of mapping, includes bits 0x08 and 0x20 */ |
---|
17 | 15 | #define MAP_FIXED 0x04 /* Interpret addr exactly */ |
---|
18 | 16 | #define MAP_ANONYMOUS 0x10 /* don't use a file */ |
---|
.. | .. |
---|
27 | 25 | #define MAP_STACK 0x40000 /* give out an address that is best suited for process/thread stacks */ |
---|
28 | 26 | #define MAP_HUGETLB 0x80000 /* create a huge page mapping */ |
---|
29 | 27 | #define MAP_FIXED_NOREPLACE 0x100000 /* MAP_FIXED which doesn't unmap underlying mapping */ |
---|
| 28 | +#define MAP_UNINITIALIZED 0 /* uninitialized anonymous mmap */ |
---|
30 | 29 | |
---|
31 | 30 | #define MS_SYNC 1 /* synchronous memory sync */ |
---|
32 | 31 | #define MS_ASYNC 2 /* sync memory asynchronously */ |
---|
.. | .. |
---|
50 | 49 | #define MADV_DONTFORK 10 /* don't inherit across fork */ |
---|
51 | 50 | #define MADV_DOFORK 11 /* do inherit across fork */ |
---|
52 | 51 | |
---|
53 | | -#define MADV_MERGEABLE 65 /* KSM may merge identical pages */ |
---|
54 | | -#define MADV_UNMERGEABLE 66 /* KSM may not merge identical pages */ |
---|
| 52 | +#define MADV_MERGEABLE 12 /* KSM may merge identical pages */ |
---|
| 53 | +#define MADV_UNMERGEABLE 13 /* KSM may not merge identical pages */ |
---|
55 | 54 | |
---|
56 | | -#define MADV_HUGEPAGE 67 /* Worth backing with hugepages */ |
---|
57 | | -#define MADV_NOHUGEPAGE 68 /* Not worth backing with hugepages */ |
---|
| 55 | +#define MADV_HUGEPAGE 14 /* Worth backing with hugepages */ |
---|
| 56 | +#define MADV_NOHUGEPAGE 15 /* Not worth backing with hugepages */ |
---|
58 | 57 | |
---|
59 | | -#define MADV_DONTDUMP 69 /* Explicity exclude from the core dump, |
---|
| 58 | +#define MADV_DONTDUMP 16 /* Explicity exclude from the core dump, |
---|
60 | 59 | overrides the coredump filter bits */ |
---|
61 | | -#define MADV_DODUMP 70 /* Clear the MADV_NODUMP flag */ |
---|
| 60 | +#define MADV_DODUMP 17 /* Clear the MADV_NODUMP flag */ |
---|
62 | 61 | |
---|
63 | | -#define MADV_WIPEONFORK 71 /* Zero memory on fork, child only */ |
---|
64 | | -#define MADV_KEEPONFORK 72 /* Undo MADV_WIPEONFORK */ |
---|
| 62 | +#define MADV_WIPEONFORK 18 /* Zero memory on fork, child only */ |
---|
| 63 | +#define MADV_KEEPONFORK 19 /* Undo MADV_WIPEONFORK */ |
---|
| 64 | + |
---|
| 65 | +#define MADV_COLD 20 /* deactivate these pages */ |
---|
| 66 | +#define MADV_PAGEOUT 21 /* reclaim these pages */ |
---|
65 | 67 | |
---|
66 | 68 | #define MADV_HWPOISON 100 /* poison a page for testing */ |
---|
67 | 69 | #define MADV_SOFT_OFFLINE 101 /* soft offline page for testing */ |
---|
68 | 70 | |
---|
69 | 71 | /* compatibility flags */ |
---|
70 | 72 | #define MAP_FILE 0 |
---|
71 | | -#define MAP_VARIABLE 0 |
---|
72 | 73 | |
---|
73 | 74 | #define PKEY_DISABLE_ACCESS 0x1 |
---|
74 | 75 | #define PKEY_DISABLE_WRITE 0x2 |
---|