Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src Split parts of uvm(9) into uvm_km(9) and uvm_map(9) man pages.



details:   https://anonhg.NetBSD.org/src/rev/2a0cd3753987
branches:  trunk
changeset: 765598:2a0cd3753987
user:      rmind <rmind%NetBSD.org@localhost>
date:      Wed Jun 01 02:22:18 2011 +0000

description:
Split parts of uvm(9) into uvm_km(9) and uvm_map(9) man pages.

OK mrg@

diffstat:

 distrib/sets/lists/comp/mi |    5 +-
 share/man/man9/Makefile    |   25 +-
 share/man/man9/uvm.9       |  427 +-------------------------------------------
 share/man/man9/uvm_km.9    |  184 +++++++++++++++++++
 share/man/man9/uvm_map.9   |  331 ++++++++++++++++++++++++++++++++++
 5 files changed, 545 insertions(+), 427 deletions(-)

diffs (truncated from 1081 to 300 lines):

diff -r 43724d696f49 -r 2a0cd3753987 distrib/sets/lists/comp/mi
--- a/distrib/sets/lists/comp/mi        Tue May 31 23:28:52 2011 +0000
+++ b/distrib/sets/lists/comp/mi        Wed Jun 01 02:22:18 2011 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: mi,v 1.1626 2011/05/30 02:10:25 christos Exp $
+#      $NetBSD: mi,v 1.1627 2011/06/01 02:22:19 rmind Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -10169,6 +10169,7 @@
 ./usr/share/man/cat9/uvm_init_limits.0         comp-sys-catman         .cat
 ./usr/share/man/cat9/uvm_io.0                  comp-sys-catman         .cat
 ./usr/share/man/cat9/uvm_kernacc.0             comp-sys-catman         .cat
+./usr/share/man/cat9/uvm_km.0                  comp-sys-catman         .cat
 ./usr/share/man/cat9/uvm_km_alloc.0            comp-sys-catman         .cat
 ./usr/share/man/cat9/uvm_km_alloc1.0           comp-obsolete           obsolete
 ./usr/share/man/cat9/uvm_km_free.0             comp-sys-catman         .cat
@@ -16106,6 +16107,7 @@
 ./usr/share/man/html9/uvm_init_limits.html     comp-sys-htmlman        html
 ./usr/share/man/html9/uvm_io.html              comp-sys-htmlman        html
 ./usr/share/man/html9/uvm_kernacc.html         comp-sys-htmlman        html
+./usr/share/man/html9/uvm_km.html              comp-sys-htmlman        html
 ./usr/share/man/html9/uvm_km_alloc.html                comp-sys-htmlman        html
 ./usr/share/man/html9/uvm_km_free.html         comp-sys-htmlman        html
 ./usr/share/man/html9/uvm_km_suballoc.html     comp-sys-htmlman        html
@@ -22259,6 +22261,7 @@
 ./usr/share/man/man9/uvm_init_limits.9         comp-sys-man            .man
 ./usr/share/man/man9/uvm_io.9                  comp-sys-man            .man
 ./usr/share/man/man9/uvm_kernacc.9             comp-sys-man            .man
+./usr/share/man/man9/uvm_km.9                  comp-sys-man            .man
 ./usr/share/man/man9/uvm_km_alloc.9            comp-sys-man            .man
 ./usr/share/man/man9/uvm_km_alloc1.9           comp-obsolete           obsolete
 ./usr/share/man/man9/uvm_km_free.9             comp-sys-man            .man
diff -r 43724d696f49 -r 2a0cd3753987 share/man/man9/Makefile
--- a/share/man/man9/Makefile   Tue May 31 23:28:52 2011 +0000
+++ b/share/man/man9/Makefile   Wed Jun 01 02:22:18 2011 +0000
@@ -1,4 +1,4 @@
-#       $NetBSD: Makefile,v 1.346 2011/04/06 05:40:19 jruoho Exp $
+#       $NetBSD: Makefile,v 1.347 2011/06/01 02:22:18 rmind Exp $
 
 #      Makefile for section 9 (kernel function and variable) manual pages.
 
@@ -54,7 +54,7 @@
        vattr.9 veriexec.9 vcons.9 vfs.9 vfs_hooks.9 vfsops.9 vfssubr.9 \
        video.9 vme.9 \
        vnfileops.9 vnode.9 vnodeops.9 vnsubr.9 \
-       ubc.9 usbdi.9 uvm.9 vmem.9 \
+       ubc.9 usbdi.9 uvm.9 uvm_km.9 uvm_map.9 vmem.9 \
        wdc.9 workqueue.9 \
        wscons.9 wsdisplay.9 wsfont.9 wskbd.9 wsmouse.9 \
        xcall.9
@@ -734,18 +734,12 @@
        tc.9 TC_PHYS_TO_UNCACHED.9
 MLINKS+=todr.9 todr_gettime.9 todr.9 todr_settime.9 \
        todr.9 clock_ymdhms_to_secs.9 todr.9 clock_secs_to_ymdhms.9
+
 MLINKS+=ubc.9 ubc_alloc.9 ubc.9 ubc_release.9 ubc.9 ubc_uiomove.9
 MLINKS+=uvm.9 uvm_init.9 uvm.9 uvm_init_limits.9 uvm.9 uvm_setpagesize.9 \
-       uvm.9 uvm_swap_init.9 uvm.9 uvm_map.9 uvm.9 uvm_unmap.9 \
-       uvm.9 uvm_map_pageable.9 \
-       uvm.9 uvm_map_checkprot.9 uvm.9 uvm_map_protect.9 \
-       uvm.9 uvm_deallocate.9 uvm.9 uvmspace_alloc.9 uvm.9 uvmspace_exec.9 \
-       uvm.9 uvmspace_fork.9 uvm.9 uvmspace_free.9 uvm.9 uvmspace_share.9 \
-       uvm.9 uvmspace_unshare.9 uvm.9 uvm_fault.9 \
+       uvm.9 uvm_swap_init.9 uvm.9 uvm_fault.9 \
        uvm.9 uvm_vnp_setsize.9 \
-       uvm.9 uvm_io.9 uvm.9 uvm_km_alloc.9 \
-       uvm.9 uvm_km_suballoc.9 uvm.9 uvm_km_free.9 \
-       uvm.9 uvm_pagealloc.9 \
+       uvm.9 uvm_io.9 uvm.9 uvm_pagealloc.9 \
        uvm.9 uvm_pagerealloc.9 uvm.9 uvm_pagefree.9 uvm.9 uvm_pglistalloc.9 \
        uvm.9 uvm_pglistfree.9 uvm.9 uvm_page_physload.9 uvm.9 uvm_pageout.9 \
        uvm.9 uvm_scheduler.9 uvm.9 uvm_swapin.9 uvm.9 uao_create.9 \
@@ -755,6 +749,15 @@
        uvm.9 uvm_fork.9 uvm.9 uvm_grow.9 \
        uvm.9 uvn_findpages.9 \
        uvm.9 uvm_loan.9 uvm.9 uvm_unloan.9
+MLINKS+=uvm_km.9 uvm_km_alloc.9 uvm_km.9 uvm_km_free.9 \
+       uvm_km.9 uvm_km_suballoc.9
+MLINKS+=uvm_map.9 uvm_unmap.9 uvm_map.9 uvm_map_pageable.9 \
+       uvm_map.9 uvm_map_checkprot.9 uvm_map.9 uvm_map_protect.9 \
+       uvm_map.9 uvm_deallocate.9 uvm_map.9 uvmspace_alloc.9 \
+       uvm_map.9 uvmspace_exec.9 uvm_map.9 uvmspace_fork.9 \
+       uvm_map.9 uvmspace_free.9 uvm_map.9 uvmspace_share.9 \
+       uvm_map.9 uvmspace_unshare.9
+
 MLINKS+=vme.9 vme_probe.9 \
        vme.9 vme_space_map.9 \
        vme.9 vme_space_unmap.9 \
diff -r 43724d696f49 -r 2a0cd3753987 share/man/man9/uvm.9
--- a/share/man/man9/uvm.9      Tue May 31 23:28:52 2011 +0000
+++ b/share/man/man9/uvm.9      Wed Jun 01 02:22:18 2011 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: uvm.9,v 1.105 2011/04/27 06:02:03 wiz Exp $
+.\"    $NetBSD: uvm.9,v 1.106 2011/06/01 02:22:18 rmind Exp $
 .\"
 .\" Copyright (c) 1998 Matthew R. Green
 .\" All rights reserved.
@@ -24,7 +24,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.Dd April 27, 2011
+.Dd June 1, 2011
 .Dt UVM 9
 .Os
 .Sh NAME
@@ -103,287 +103,8 @@
 .Fn uvm_swap_init
 initializes the swap sub-system.
 .Sh VIRTUAL ADDRESS SPACE MANAGEMENT
-.Bl -ohang
-.It Ft int
-.Fn uvm_map "struct vm_map *map" "vaddr_t *startp" "vsize_t size" "struct uvm_object *uobj" "voff_t uoffset" "vsize_t align" "uvm_flag_t flags" ;
-.It Ft void
-.Fn uvm_unmap "struct vm_map *map" "vaddr_t start" "vaddr_t end" ;
-.It Ft int
-.Fn uvm_map_pageable "struct vm_map *map" "vaddr_t start" "vaddr_t end" "bool new_pageable" "int lockflags" ;
-.It Ft bool
-.Fn uvm_map_checkprot "struct vm_map *map" "vaddr_t start" "vaddr_t end" "vm_prot_t protection" ;
-.It Ft int
-.Fn uvm_map_protect "struct vm_map *map" "vaddr_t start" "vaddr_t end" "vm_prot_t new_prot" "bool set_max" ;
-.It Ft int
-.Fn uvm_deallocate "struct vm_map *map" "vaddr_t start" "vsize_t size" ;
-.It Ft struct vmspace *
-.Fn uvmspace_alloc "vaddr_t min" "vaddr_t max" "int pageable" ;
-.It Ft void
-.Fn uvmspace_exec "struct lwp *l" "vaddr_t start" "vaddr_t end" ;
-.It Ft struct vmspace *
-.Fn uvmspace_fork "struct vmspace *vm" ;
-.It Ft void
-.Fn uvmspace_free "struct vmspace *vm1" ;
-.It Ft void
-.Fn uvmspace_share "struct proc *p1" "struct proc *p2" ;
-.It Ft void
-.Fn uvmspace_unshare "struct lwp *l" ;
-.It Ft bool
-.Fn uvm_uarea_alloc "vaddr_t *uaddrp" ;
-.It  Ft void
-.Fn uvm_uarea_free "vaddr_t uaddr" ;
-.El
-.Pp
-.Fn uvm_map
-establishes a valid mapping in map
-.Fa map ,
-which must be unlocked.
-The new mapping has size
-.Fa size ,
-which must be a multiple of
-.Dv PAGE_SIZE .
-The
-.Fa uobj
-and
-.Fa uoffset
-arguments can have four meanings.
-When
-.Fa uobj
-is
-.Dv NULL
-and
-.Fa uoffset
-is
-.Dv UVM_UNKNOWN_OFFSET ,
-.Fn uvm_map
-does not use the machine-dependent
-.Dv PMAP_PREFER
-function.
-If
-.Fa uoffset
-is any other value, it is used as the hint to
-.Dv PMAP_PREFER .
-When
-.Fa uobj
-is not
-.Dv NULL
-and
-.Fa uoffset
-is
-.Dv UVM_UNKNOWN_OFFSET ,
-.Fn uvm_map
-finds the offset based upon the virtual address, passed as
-.Fa startp .
-If
-.Fa uoffset
-is any other value, we are doing a normal mapping at this offset.
-The start address of the map will be returned in
-.Fa startp .
-.Pp
-.Fa align
-specifies alignment of mapping unless
-.Dv UVM_FLAG_FIXED
-is specified in
-.Fa flags .
-.Fa align
-must be a power of 2.
-.Pp
-.Fa flags
-passed to
-.Fn uvm_map
-are typically created using the
-.Fn UVM_MAPFLAG "vm_prot_t prot" "vm_prot_t maxprot" "vm_inherit_t inh" "int advice" "int flags"
-macro, which uses the following values.
-The
-.Fa prot
-and
-.Fa maxprot
-can take are:
-.Bd -literal
-#define UVM_PROT_MASK   0x07    /* protection mask */
-#define UVM_PROT_NONE   0x00    /* protection none */
-#define UVM_PROT_ALL    0x07    /* everything */
-#define UVM_PROT_READ   0x01    /* read */
-#define UVM_PROT_WRITE  0x02    /* write */
-#define UVM_PROT_EXEC   0x04    /* exec */
-#define UVM_PROT_R      0x01    /* read */
-#define UVM_PROT_W      0x02    /* write */
-#define UVM_PROT_RW     0x03    /* read-write */
-#define UVM_PROT_X      0x04    /* exec */
-#define UVM_PROT_RX     0x05    /* read-exec */
-#define UVM_PROT_WX     0x06    /* write-exec */
-#define UVM_PROT_RWX    0x07    /* read-write-exec */
-.Ed
-.Pp
-The values that
-.Fa inh
-can take are:
-.Bd -literal
-#define UVM_INH_MASK    0x30    /* inherit mask */
-#define UVM_INH_SHARE   0x00    /* "share" */
-#define UVM_INH_COPY    0x10    /* "copy" */
-#define UVM_INH_NONE    0x20    /* "none" */
-#define UVM_INH_DONATE  0x30    /* "donate" \*[Lt]\*[Lt] not used */
-.Ed
-.Pp
-The values that
-.Fa advice
-can take are:
-.Bd -literal
-#define UVM_ADV_NORMAL     0x0  /* 'normal' */
-#define UVM_ADV_RANDOM     0x1  /* 'random' */
-#define UVM_ADV_SEQUENTIAL 0x2  /* 'sequential' */
-#define UVM_ADV_MASK       0x7  /* mask */
-.Ed
-.Pp
-The values that
-.Fa flags
-can take are:
-.Bd -literal
-#define UVM_FLAG_FIXED   0x010000 /* find space */
-#define UVM_FLAG_OVERLAY 0x020000 /* establish overlay */
-#define UVM_FLAG_NOMERGE 0x040000 /* don't merge map entries */
-#define UVM_FLAG_COPYONW 0x080000 /* set copy_on_write flag */
-#define UVM_FLAG_AMAPPAD 0x100000 /* for bss: pad amap to reduce malloc() */
-#define UVM_FLAG_TRYLOCK 0x200000 /* fail if we can not lock map */
-.Ed
-.Pp
-The
-.Dv UVM_MAPFLAG
-macro arguments can be combined with an or operator.
-There are several special purpose macros for checking protection
-combinations, e.g., the
-.Dv UVM_PROT_WX
-macro.
-There are also some additional macros to extract bits from the flags.
-The
-.Dv UVM_PROTECTION ,
-.Dv UVM_INHERIT ,
-.Dv UVM_MAXPROTECTION
-and
-.Dv UVM_ADVICE
-macros return the protection, inheritance, maximum protection and advice,
-respectively.
-.Fn uvm_map
-returns a standard UVM return value.
-.Pp
-.Fn uvm_unmap
-removes a valid mapping,
-from
-.Fa start
-to
-.Fa end ,
-in map
-.Fa map ,
-which must be unlocked.
-.Pp
-.Fn uvm_map_pageable
-changes the pageability of the pages in the range from
-.Fa start
-to
-.Fa end
-in map
-.Fa map
-to
-.Fa new_pageable .
-.Fn uvm_map_pageable
-returns a standard UVM return value.
-.Pp
-.Fn uvm_map_checkprot
-checks the protection of the range from
-.Fa start



Home | Main Index | Thread Index | Old Index