From 72133aa8cba83d09600c6ce2083d18f265d0e205 Mon Sep 17 00:00:00 2001 From: pooka Date: Mon, 15 Oct 2007 13:39:50 +0000 Subject: [PATCH] document ubc_uiomove() --- share/man/man9/uvm.9 | 34 +++++++++++++++++++++++++++++----- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/share/man/man9/uvm.9 b/share/man/man9/uvm.9 index b2645daa42c0..c88cf94a8644 100644 --- a/share/man/man9/uvm.9 +++ b/share/man/man9/uvm.9 @@ -1,4 +1,4 @@ -.\" $NetBSD: uvm.9,v 1.86 2007/10/10 11:05:15 pooka Exp $ +.\" $NetBSD: uvm.9,v 1.87 2007/10/15 13:39:50 pooka Exp $ .\" .\" Copyright (c) 1998 Matthew R. Green .\" All rights reserved. @@ -26,7 +26,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 10, 2007 +.Dd October 15, 2007 .Dt UVM 9 .Os .Sh NAME @@ -447,6 +447,11 @@ returns a standard UVM return value. .br .Fn ubc_release "void *va" "int flags" ; .Pp +int +.br +.Fn ubc_uiomove "struct uvm_object *uobj" "struct uio *uio" "vsize_t todo" \ +"int advice" "int flags" ; +.Pp .Fn uvm_vnp_setsize sets the size of vnode .Fa vp @@ -511,9 +516,28 @@ for reuse. The mapping may be cached to speed future accesses to the same region of the object. The flags can be any of -.Bd -literal -#define UBC_UNMAP 0x01 /* do not cache mapping */ -.Ed +.Pp +.Bl -tag -offset indent -width "UVM_ADV_SEQUENTIAL" -compact +.It UBC_UNMAP +Do not cache mapping. +.El +.Pp +.Fn ubc_uiomove +allocates an UBC memory window, performs I/O on it and unmaps the window. +The +.Fa advice +parameter takes the same values as the respective parameter in +.Fn ubc_alloc +and the +.Fa flags +parameter takes the same arguments as +.Fn ubc_alloc +and +.Fn ubc_unmap . +Additionally, the flag +.Dv UBC_PARTIALOK +can be provided to indicate that it is acceptable to return if an error +occurs mid-transfer. .Sh VIRTUAL MEMORY I/O .Ft int .br