xref: /original-bsd/sys/sys/mman.h (revision f052b07a)
1 /*
2  * Copyright (c) 1982, 1986 Regents of the University of California.
3  * All rights reserved.  The Berkeley software License Agreement
4  * specifies the terms and conditions for redistribution.
5  *
6  *	@(#)mman.h	7.1 (Berkeley) 06/04/86
7  */
8 
9 /* protections are chosen from these bits, or-ed together */
10 #define	PROT_READ	0x1		/* pages can be read */
11 #define	PROT_WRITE	0x2		/* pages can be written */
12 #define	PROT_EXEC	0x4		/* pages can be executed */
13 
14 /* sharing types: choose either SHARED or PRIVATE */
15 #define	MAP_SHARED	1		/* share changes */
16 #define	MAP_PRIVATE	2		/* changes are private */
17 
18 /* advice to madvise */
19 #define	MADV_NORMAL	0		/* no further special treatment */
20 #define	MADV_RANDOM	1		/* expect random page references */
21 #define	MADV_SEQUENTIAL	2		/* expect sequential page references */
22 #define	MADV_WILLNEED	3		/* will need these pages */
23 #define	MADV_DONTNEED	4		/* dont need these pages */
24