diff options
author | Marin Ramesa <mpr@hi.t-com.hr> | 2013-07-10 12:42:08 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2013-07-18 00:08:37 +0200 |
commit | 91f9da20ad9da24c13b2b87b14752c865454744b (patch) | |
tree | 74c409c7a9706822594728059eb9502df289cd59 /vm | |
parent | 37a5965ed210cb0672ceae8292393a678a144415 (diff) |
vm: organize vm print function prototypes
* vm/vm_print.h: New file.
Include <vm/vm_map.h>.
Include <machine/db_machdep.h>.
(vm_map_print): Add prototype.
(vm_map_copy_print): Likewise.
(vm_object_print): Likewise.
(vm_page_print): Likewise.
Include <vm/vm_object.h>.
Include <vm/vm_page.h>
* vm/vm_map.h (vm_map_print): Remove prototype.
* vm/vm_map.c [MACH_KDB]: Include <vm/vm_print.h>.
* vm/vm_object.h (vm_object_print): Remove prototype.
* vm/vm_object.c [MACH_KDB]: Include <vm/vm_print.h>.
* vm/vm_resident.c [MACH_KDB]: Include <vm/vm_print.h>.
Diffstat (limited to 'vm')
-rw-r--r-- | vm/vm_map.c | 1 | ||||
-rw-r--r-- | vm/vm_map.h | 3 | ||||
-rw-r--r-- | vm/vm_object.c | 1 | ||||
-rw-r--r-- | vm/vm_object.h | 2 | ||||
-rw-r--r-- | vm/vm_print.h | 22 | ||||
-rw-r--r-- | vm/vm_resident.c | 1 |
6 files changed, 25 insertions, 5 deletions
diff --git a/vm/vm_map.c b/vm/vm_map.c index 47db118..2be7147 100644 --- a/vm/vm_map.c +++ b/vm/vm_map.c @@ -55,6 +55,7 @@ #if MACH_KDB #include <ddb/db_output.h> +#include <vm/vm_print.h> #endif /* MACH_KDB */ diff --git a/vm/vm_map.h b/vm/vm_map.h index a15e681..5fdac4e 100644 --- a/vm/vm_map.h +++ b/vm/vm_map.h @@ -397,9 +397,6 @@ extern kern_return_t vm_map_protect(vm_map_t, vm_offset_t, vm_offset_t, extern kern_return_t vm_map_inherit(vm_map_t, vm_offset_t, vm_offset_t, vm_inherit_t); -/* Debugging: print a map */ -extern void vm_map_print(vm_map_t); - /* Look up an address */ extern kern_return_t vm_map_lookup(vm_map_t *, vm_offset_t, vm_prot_t, vm_map_version_t *, vm_object_t *, diff --git a/vm/vm_object.c b/vm/vm_object.c index d83c39f..18a909f 100644 --- a/vm/vm_object.c +++ b/vm/vm_object.c @@ -2969,6 +2969,7 @@ vm_object_page_map( #if MACH_KDB +#include <vm/vm_print.h> #define printf kdbprintf boolean_t vm_object_print_pages = FALSE; diff --git a/vm/vm_object.h b/vm/vm_object.h index 4e4c949..adeff65 100644 --- a/vm/vm_object.h +++ b/vm/vm_object.h @@ -233,8 +233,6 @@ extern void vm_object_page_map( vm_offset_t (*)(void *, vm_offset_t), void *); -extern void vm_object_print(vm_object_t); - extern vm_object_t vm_object_request_object(struct ipc_port *); extern boolean_t vm_object_coalesce( diff --git a/vm/vm_print.h b/vm/vm_print.h new file mode 100644 index 0000000..69a20ba --- /dev/null +++ b/vm/vm_print.h @@ -0,0 +1,22 @@ +#ifndef VM_PRINT_H +#define VM_PRINT_H + +#include <vm/vm_map.h> +#include <machine/db_machdep.h> + +/* Debugging: print a map */ +extern void vm_map_print(vm_map_t); + +/* Pretty-print a copy object for ddb. */ +extern void vm_map_copy_print(vm_map_copy_t); + +#include <vm/vm_object.h> + +extern void vm_object_print(vm_object_t); + +#include <vm/vm_page.h> + +extern void vm_page_print(vm_page_t); + +#endif /* VM_PRINT_H */ + diff --git a/vm/vm_resident.c b/vm/vm_resident.c index d2edf5a..7906b58 100644 --- a/vm/vm_resident.c +++ b/vm/vm_resident.c @@ -60,6 +60,7 @@ #if MACH_KDB #include <ddb/db_output.h> +#include <vm/vm_print.h> #endif /* MACH_KDB */ |