|
|
1.1 root 1: /*
2: * Copyright (c) 1999 Apple Computer, Inc. All rights reserved.
3: *
4: * @APPLE_LICENSE_HEADER_START@
5: *
6: * Portions Copyright (c) 1999 Apple Computer, Inc. All Rights
7: * Reserved. This file contains Original Code and/or Modifications of
8: * Original Code as defined in and that are subject to the Apple Public
9: * Source License Version 1.1 (the "License"). You may not use this file
10: * except in compliance with the License. Please obtain a copy of the
11: * License at http://www.apple.com/publicsource and read it before using
12: * this file.
13: *
14: * The Original Code and all software distributed under the License are
15: * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
16: * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
17: * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
18: * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
19: * License for the specific language governing rights and limitations
20: * under the License.
21: *
22: * @APPLE_LICENSE_HEADER_END@
23: */
24:
25: /*
26: * Mach Operating System
27: * Copyright (c) 1991,1990,1989,1988 Carnegie Mellon University
28: * All Rights Reserved.
29: *
30: * Permission to use, copy, modify and distribute this software and its
31: * documentation is hereby granted, provided that both the copyright
32: * notice and this permission notice appear in all copies of the
33: * software, derivative works or modified versions, and any portions
34: * thereof, and that both notices appear in supporting documentation.
35: *
36: * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
37: * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
38: * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
39: *
40: * Carnegie Mellon requests users of this software to return to
41: *
42: * Software Distribution Coordinator or [email protected]
43: * School of Computer Science
44: * Carnegie Mellon University
45: * Pittsburgh PA 15213-3890
46: *
47: * any improvements or extensions that they make and grant Carnegie Mellon
48: * the rights to redistribute these changes.
49: */
50: /*
51: * File: memory_object.h
52: * Author: Michael Wayne Young
53: *
54: * External memory management interface definition.
55: */
56:
57: #ifndef _MACH_MEMORY_OBJECT_H_
58: #define _MACH_MEMORY_OBJECT_H_
59:
60: /*
61: * User-visible types used in the external memory
62: * management interface:
63: */
64:
65: #import <mach/port.h>
66:
67: typedef mach_port_t memory_object_t;
68: /* Represents a memory object ... */
69: /* Used by user programs to specify */
70: /* the object to map; used by the */
71: /* kernel to retrieve or store data */
72:
73: typedef mach_port_t memory_object_control_t;
74: /* Provided to a memory manager; ... */
75: /* used to control a memory object */
76:
77: typedef mach_port_t memory_object_name_t;
78: /* Used to describe the memory ... */
79: /* object in vm_regions() calls */
80:
81: typedef int memory_object_copy_strategy_t;
82: /* How memory manager handles copy: */
83: #define MEMORY_OBJECT_COPY_NONE 0
84: /* ... No special support */
85: #define MEMORY_OBJECT_COPY_CALL 1
86: /* ... Make call on memory manager */
87: #define MEMORY_OBJECT_COPY_DELAY 2
88: /* ... Memory manager doesn't ... */
89: /* change data externally. */
90: #define MEMORY_OBJECT_COPY_TEMPORARY 3
91: /* ... Memory manager doesn't ... */
92: /* change data externally, and */
93: /* doesn't need to see changes. */
94:
95: typedef int memory_object_return_t;
96: /* Which pages to return to manager
97: this time (lock_request) */
98: #define MEMORY_OBJECT_RETURN_NONE 0
99: /* ... don't return any. */
100: #define MEMORY_OBJECT_RETURN_DIRTY 1
101: /* ... only dirty pages. */
102: #define MEMORY_OBJECT_RETURN_ALL 2
103: /* ... dirty and precious pages. */
104:
105: #define MEMORY_OBJECT_NULL MACH_PORT_NULL
106:
107: #endif /* _MACH_MEMORY_OBJECT_H_ */
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.