summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm.h
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2009-08-28 14:06:55 +0000
committerjhb <jhb@FreeBSD.org>2009-08-28 14:06:55 +0000
commit7b069e86c6dbd397d4d622acf8c924f2ade8127d (patch)
tree90a42d70408be865b0d3f244445d7106ff89a054 /sys/vm/vm.h
parentb546d1fee4837a126b1e940e542b8d9ff2132bc6 (diff)
downloadFreeBSD-src-7b069e86c6dbd397d4d622acf8c924f2ade8127d.zip
FreeBSD-src-7b069e86c6dbd397d4d622acf8c924f2ade8127d.tar.gz
Extend the device pager to support different memory attributes on different
pages in an object. - Add a new variant of d_mmap() currently called d_mmap2() which accepts an additional in/out parameter that is the memory attribute to use for the requested page. - A driver either uses d_mmap() or d_mmap2() for all requests but not both. The current implementation uses a flag in the cdevsw (D_MMAP2) to indicate that the driver provides a d_mmap2() handler instead of d_mmap(). This is done to make the change ABI compatible with existing drivers and MFC'able to 7 and 8. Submitted by: alc MFC after: 1 month
Diffstat (limited to 'sys/vm/vm.h')
-rw-r--r--sys/vm/vm.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/vm/vm.h b/sys/vm/vm.h
index b547514..941300a 100644
--- a/sys/vm/vm.h
+++ b/sys/vm/vm.h
@@ -63,12 +63,6 @@
#include <machine/vm.h>
-/*
- * The exact set of memory attributes is machine dependent. However, every
- * machine is required to define VM_MEMATTR_DEFAULT.
- */
-typedef char vm_memattr_t; /* memory attribute codes */
-
typedef char vm_inherit_t; /* inheritance codes */
#define VM_INHERIT_SHARE ((vm_inherit_t) 0)
@@ -115,6 +109,12 @@ typedef struct vm_object *vm_object_t;
typedef int boolean_t;
/*
+ * The exact set of memory attributes is machine dependent. However, every
+ * machine is required to define VM_MEMATTR_DEFAULT.
+ */
+typedef char vm_memattr_t; /* memory attribute codes */
+
+/*
* This is defined in <sys/types.h> for the kernel so that vnode_if.h
* doesn't have to include <vm/vm.h>.
*/
OpenPOWER on IntegriCloud