summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm_glue.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/vm/vm_glue.c')
-rw-r--r--sys/vm/vm_glue.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/sys/vm/vm_glue.c b/sys/vm/vm_glue.c
index 81451c1..92e1005 100644
--- a/sys/vm/vm_glue.c
+++ b/sys/vm/vm_glue.c
@@ -121,6 +121,12 @@ static void vm_proc_swapout(struct proc *p);
/*
* MPSAFE
+ *
+ * WARNING! This code calls vm_map_check_protection() which only checks
+ * the associated vm_map_entry range. It does not determine whether the
+ * contents of the memory is actually readable or writable. In most cases
+ * just checking the vm_map_entry is sufficient within the kernel's address
+ * space.
*/
int
kernacc(addr, len, rw)
@@ -142,6 +148,12 @@ kernacc(addr, len, rw)
/*
* MPSAFE
+ *
+ * WARNING! This code calls vm_map_check_protection() which only checks
+ * the associated vm_map_entry range. It does not determine whether the
+ * contents of the memory is actually readable or writable. vmapbuf(),
+ * vm_fault_quick(), or copyin()/copout()/su*()/fu*() functions should be
+ * used in conjuction with this call.
*/
int
useracc(addr, len, rw)
OpenPOWER on IntegriCloud