1 /*
2 * Mach Operating System
3 * Copyright (c) 1991,1990,1989,1988 Carnegie Mellon University
4 * All Rights Reserved.
5 *
6 * Permission to use, copy, modify and distribute this software and its
7 * documentation is hereby granted, provided that both the copyright
8 * notice and this permission notice appear in all copies of the
9 * software, derivative works or modified versions, and any portions
10 * thereof, and that both notices appear in supporting documentation.
11 *
12 * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
13 * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
14 * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
15 *
16 * Carnegie Mellon requests users of this software to return to
17 *
18 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
19 * School of Computer Science
20 * Carnegie Mellon University
21 * Pittsburgh PA 15213-3890
22 *
23 * any improvements or extensions that they make and grant Carnegie Mellon
24 * the rights to redistribute these changes.
25 */
26 /*
27 * HISTORY
28 * $Log: memory_object.h,v $
29 * Revision 2.9 93/01/14 17:44:47 danner
30 * Cleanup.
31 * [92/06/10 pds]
32 *
33 * Revision 2.8 92/05/21 17:22:24 jfriedl
34 * Removed coment starter from within comments to shut up gcc warnings.
35 * [92/05/16 jfriedl]
36 *
37 * Revision 2.7 92/03/10 16:27:05 jsb
38 * Added MEMORY_OBJECT_COPY_TEMPORARY.
39 * [92/02/11 07:56:35 jsb]
40 *
41 * Revision 2.6 91/08/28 11:15:22 jsb
42 * Add defs for memory_object_return_t.
43 * [91/07/03 14:06:26 dlb]
44 *
45 * Revision 2.5 91/05/18 14:35:05 rpd
46 * Removed memory_manager_default.
47 * [91/03/22 rpd]
48 *
49 * Revision 2.4 91/05/14 16:55:55 mrt
50 * Correcting copyright
51 *
52 * Revision 2.3 91/02/05 17:34:01 mrt
53 * Changed to new Mach copyright
54 * [91/02/01 17:19:11 mrt]
55 *
56 * Revision 2.2 90/06/02 14:58:56 rpd
57 * Converted to new IPC.
58 * [90/03/26 22:35:26 rpd]
59 *
60 * Revision 2.1 89/08/03 16:02:52 rwd
61 * Created.
62 *
63 * Revision 2.5 89/02/25 18:38:23 gm0w
64 * Changes for cleanup.
65 *
66 * Revision 2.4 89/02/07 00:54:07 mwyoung
67 * Relocated from vm/memory_object.h
68 *
69 * Revision 2.3 89/01/30 22:08:42 rpd
70 * Updated includes to the new style. Fixed log.
71 * Made variable declarations use "extern".
72 * [89/01/25 15:25:20 rpd]
73 */
74 /*
75 * File: memory_object.h
76 * Author: Michael Wayne Young
77 *
78 * External memory management interface definition.
79 */
80
81 #ifndef _MACH_MEMORY_OBJECT_H_
82 #define _MACH_MEMORY_OBJECT_H_
83
84 /*
85 * User-visible types used in the external memory
86 * management interface:
87 */
88
89 #include <mach/port.h>
90
91 typedef mach_port_t memory_object_t;
92 /* Represents a memory object ... */
93 /* Used by user programs to specify */
94 /* the object to map; used by the */
95 /* kernel to retrieve or store data */
96
97 typedef mach_port_t memory_object_control_t;
98 /* Provided to a memory manager; ... */
99 /* used to control a memory object */
100
101 typedef mach_port_t memory_object_name_t;
102 /* Used to describe the memory ... */
103 /* object in vm_regions() calls */
104
105 typedef int memory_object_copy_strategy_t;
106 /* How memory manager handles copy: */
107 #define MEMORY_OBJECT_COPY_NONE 0
108 /* ... No special support */
109 #define MEMORY_OBJECT_COPY_CALL 1
110 /* ... Make call on memory manager */
111 #define MEMORY_OBJECT_COPY_DELAY 2
112 /* ... Memory manager doesn't ... */
113 /* change data externally. */
114 #define MEMORY_OBJECT_COPY_TEMPORARY 3
115 /* ... Memory manager doesn't ... */
116 /* change data externally, and */
117 /* doesn't need to see changes. */
118
119 typedef int memory_object_return_t;
120 /* Which pages to return to manager
121 this time (lock_request) */
122 #define MEMORY_OBJECT_RETURN_NONE 0
123 /* ... don't return any. */
124 #define MEMORY_OBJECT_RETURN_DIRTY 1
125 /* ... only dirty pages. */
126 #define MEMORY_OBJECT_RETURN_ALL 2
127 /* ... dirty and precious pages. */
128
129 #define MEMORY_OBJECT_NULL MACH_PORT_NULL
130
131 #endif /* _MACH_MEMORY_OBJECT_H_ */
Cache object: 20fccd71311a13a6924e8e65c29fcc68
|