#include <mach/vm_types.h> also included by
<mach/mach.h>mach/vm_types.h
macroerr_vm_reclaim
#define err_vm_reclaim(e) (err_vm | err_sub(1) | e)
typedefpointer_t
typedef vm_offset_t pointer_t
typedefvm_address_t
typedef vm_offset_t vm_address_t
typedefaddr64_t
We use addr64_t for 64-bit addresses that are used on both
32 and 64-bit machines. On PPC, they are passed and returned as
two adjacent 32-bit GPRs. We use addr64_t in places where
common code must be useable both on 32 and 64-bit machines.
typedef uint64_t addr64_t
Basic effective address
typedefreg64_t
We use reg64_t for addresses that are 32 bits on a 32-bit
machine, and 64 bits on a 64-bit machine, but are always
passed and returned in a single GPR on PPC. This type
cannot be used in generic 32-bit c, since on a 64-bit
machine the upper half of the register will be ignored
by the c compiler in 32-bit mode. In c, we can only use the
type in prototypes of functions that are written in and called
from assembly language. This type is basically a comment.
typedef uint32_t reg64_t
typedefppnum_t
To minimize the use of 64-bit fields, we keep some physical
addresses (that are page aligned) as 32-bit page numbers.
This limits the physical address space to 16TB of RAM.
typedef uint32_t ppnum_t
Physical page number
macroPPNUM_MAX
#define PPNUM_MAX UINT32_MAX
macroVM_OFFSET_LIST_MAX
For use with mach_vm_update_pointers_with_remote_tags.
This definition must be kept in sync with the definition in mach_types.defs.
#define VM_OFFSET_LIST_MAX 1024
typedefvm_map_t
typedef mach_port_t vm_map_t
typedefvm_map_read_t
typedef mach_port_t vm_map_t, vm_map_read_t
typedefvm_map_inspect_t
typedef mach_port_t vm_map_t, vm_map_read_t, vm_map_inspect_t
typedefupl_t
typedef mach_port_t upl_t
typedefvm_named_entry_t
typedef mach_port_t vm_named_entry_t
typedefmach_vm_offset_list_t
typedef mach_vm_offset_t *mach_vm_offset_list_t
macroVM_MAP_NULL
#define VM_MAP_NULL ((vm_map_t) 0)
macroVM_MAP_INSPECT_NULL
#define VM_MAP_INSPECT_NULL ((vm_map_inspect_t) 0)
macroVM_MAP_READ_NULL
#define VM_MAP_READ_NULL ((vm_map_read_t) 0)
macroVM_NAMED_ENTRY_NULL
#define VM_NAMED_ENTRY_NULL ((vm_named_entry_t) 0)
typedefvm_object_offset_t
typedef uint64_t vm_object_offset_t
typedefvm_object_size_t
typedef uint64_t vm_object_size_t
structmach_vm_range
@typedef mach_vm_range_t
@brief Pair of a min/max address used to denote a memory region.
@discussion @c min_address must be smaller or equal to @c max_address.
| mach_vm_offset_t | min_address | |
| mach_vm_offset_t | max_address |
typedefmach_vm_range_t
typedef struct mach_vm_range * mach_vm_range_t;
enummach_vm_range_flavor_t
@enum mach_vm_range_flavor_t
@brief A flavor for the mach_vm_range_create() call.
@const MACH_VM_RANGE_FLAVOR_V1
The recipe is an array of @c mach_vm_range_recipe_v1_t.
| MACH_VM_RANGE_FLAVOR_INVALID | 0 | |
| MACH_VM_RANGE_FLAVOR_V1 | 1 |
typedefmach_vm_range_flavor_t
typedef enum mach_vm_range_flavor_t mach_vm_range_flavor_t;
enummach_vm_range_flags_t
@enum mach_vm_range_flags_t
@brief Flags used to alter the behavior of a Mach VM Range.
| MACH_VM_RANGE_NONE | 0 |
typedefmach_vm_range_flags_t
typedef enum mach_vm_range_flags_t mach_vm_range_flags_t;
enummach_vm_range_tag_t
@enum mach_vm_range_tag_t
@brief A tag to denote the semantics of a given Mach VM Range.
@const MACH_VM_RANGE_DEFAULT
The tag associated with the general VA space usable
before the shared cache.
Such a range can't be made by userspace.
@const MACH_VM_RANGE_DATA
The tag associated with the anonymous randomly slid
range of data heap optionally made when a process is created.
Such a range can't be made by userspace.
@const MACH_VM_RANGE_FIXED
The tag associated with ranges that are made available
for @c VM_FLAGS_FIXED allocations, but that the VM will never
autonomously serve from a @c VM_FLAGS_ANYWHERE kind of request.
This really create a delegated piece of VA that can be carved out
in the way userspace sees fit.
| MACH_VM_RANGE_DEFAULT | 0 | |
| MACH_VM_RANGE_DATA | 1 | |
| MACH_VM_RANGE_FIXED | 2 |
typedefmach_vm_range_tag_t
typedef enum mach_vm_range_tag_t mach_vm_range_tag_t;
structmach_vm_range_recipe_v1_t
| mach_vm_range_flags_t:48 | flags | |
| mach_vm_range_tag_t:8 | range_tag | |
| uint8_t:8 | vm_tag | |
| struct mach_vm_range | range |
typedefmach_vm_range_recipe_v1_t
typedef struct mach_vm_range_recipe_v1_t mach_vm_range_recipe_v1_t;
macroMACH_VM_RANGE_FLAVOR_DEFAULT
#define MACH_VM_RANGE_FLAVOR_DEFAULT MACH_VM_RANGE_FLAVOR_V1
typedefmach_vm_range_recipe_t
typedef mach_vm_range_recipe_v1_t mach_vm_range_recipe_t
typedefmach_vm_range_recipes_raw_t
typedef uint8_t *mach_vm_range_recipes_raw_t