summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMaksym Planeta <mcsim.planeta@gmail.com>2012-10-08 16:31:41 +0200
committerMaksym Planeta <mcsim.planeta@gmail.com>2012-10-28 12:23:28 +0100
commit74250405e042ecf0f11adc42f00968b39d93fe3e (patch)
tree7e647aaaf77adbae5384e5350f52d6c969d9d1a6 /include
parente70ecc311676b9f30cbc5ca7c2029b7f522cbb25 (diff)
Add RPC that supplies user with general information regarding memory advice.
Current implementation of vm_get_advice_info returns only maximal possible size of cluster to be asked. This information is used by default pager, because it can't rely on allocating of memory during processing requests from kernel. That's why default pager allocates buffers, where it stores data to be returned to kernel, beforehand for each thread. So, information provided by vm_get_advice_info tells the default pager size of this buffer. * include/mach/mach.defs (vm_get_advice_info): New ipc definition. * vm/vm_user.c (vm_get_advice_info): New function.
Diffstat (limited to 'include')
-rw-r--r--include/mach/mach.defs4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/mach/mach.defs b/include/mach/mach.defs
index c5ffbc05..8e49d819 100644
--- a/include/mach/mach.defs
+++ b/include/mach/mach.defs
@@ -713,7 +713,9 @@ routine vm_machine_attribute(
attribute : vm_machine_attribute_t;
inout value : vm_machine_attribute_val_t);
-skip; /* old host_fpa_counters_reset */
+routine vm_get_advice_info(
+ target_task : vm_task_t;
+ out max_cluster : vm_size_t);
/*
* There is no more room in this interface for additional calls.