NetBSD/sys/uvm
thorpej 4e398a6ded Add some more meat to madvise(2):
* Implement MADV_DONTNEED: deactivate pages in the specified range,
  semantics similar to Solaris's MADV_DONTNEED.
* Add MADV_FREE: free pages and swap resources associated with the
  specified range, causing the range to be reloaded from backing
  store (vnodes) or zero-fill (anonymous), semantics like FreeBSD's
  MADV_FREE and like Digital UNIX's MADV_DONTNEED (isn't it SO GREAT
  that madvise(2) isn't standardized!?)

As part of this, move the non-map-modifying advice handling out of
uvm_map_advise(), and into sys_madvise().

As another part, implement general amap cleaning in uvm_map_clean(), and
change uvm_map_clean() to only push dirty pages to disk if PGO_CLEANIT
is set in its flags (and update sys___msync13() accordingly).  XXX Add
a patchable global "amap_clean_works", defaulting to 1, which can disable
the amap cleaning code, just in case problems are unearthed; this gives
a developer/user a quick way to recover and send a bug report (e.g. boot
into DDB and change the value).

XXX Still need to implement a real uao_flush().

XXX Need to update the manual page.

With these changes, rebuilding libc will automatically cause the new
malloc(3) to use MADV_FREE to actually release pages and swap resources
when it decides that can be done.
1999-07-07 06:02:21 +00:00
..
Makefile
uvm_amap_i.h Don't bother returning the "slot" number from amap_add(): 1999-07-07 05:31:40 +00:00
uvm_amap.c fix allocation handling bugs in amap_alloc1(). if the first or second 1999-07-06 02:15:53 +00:00
uvm_amap.h Don't bother returning the "slot" number from amap_add(): 1999-07-07 05:31:40 +00:00
uvm_anon.c
uvm_anon.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_aobj.c Update a comment in uao_flush(). 1999-07-07 05:32:26 +00:00
uvm_aobj.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_ddb.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_device.c
uvm_device.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_extern.h Bring in additional uvmexp members from chs-ubc2, so that VM stats can 1999-07-02 23:20:58 +00:00
uvm_fault_i.h Keep interrupt-safe maps on an additional queue. In uvm_fault(), if we're 1999-06-04 23:38:41 +00:00
uvm_fault.c pmap_change_wiring() -> pmap_unwire(). 1999-06-17 19:23:20 +00:00
uvm_fault.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_glue.c Make uvm_vslock() return the error code from uvm_fault_wire(). All places 1999-06-17 15:47:22 +00:00
uvm_glue.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_init.c
uvm_io.c
uvm_km.c Keep interrupt-safe maps on an additional queue. In uvm_fault(), if we're 1999-06-04 23:38:41 +00:00
uvm_km.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_loan.c Just say no to interrupt-safe maps. 1999-06-03 00:05:45 +00:00
uvm_loan.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_map_i.h Fix a corner case locking error, which could lead to map corruption in 1999-07-01 20:07:05 +00:00
uvm_map.c Add some more meat to madvise(2): 1999-07-07 06:02:21 +00:00
uvm_map.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_meter.c
uvm_mmap.c Add some more meat to madvise(2): 1999-07-07 06:02:21 +00:00
uvm_object.h Define a new kernel object type, "intrsafe", which are used for objects 1999-05-25 20:30:08 +00:00
uvm_page_i.h - Change uvm_{lock,unlock}_fpageq() to return/take the previous interrupt 1999-05-24 19:10:57 +00:00
uvm_page.c Add a comment explaining why using pmap_kenter_pa() is safe here. 1999-05-25 01:34:13 +00:00
uvm_page.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_pager_i.h
uvm_pager.c Change the vm_map's "entries_pageable" member to a r/o flags member, which 1999-05-26 19:16:28 +00:00
uvm_pager.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_pdaemon.c - Change uvm_{lock,unlock}_fpageq() to return/take the previous interrupt 1999-05-24 19:10:57 +00:00
uvm_pdaemon.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_pglist.c - Change uvm_{lock,unlock}_fpageq() to return/take the previous interrupt 1999-05-24 19:10:57 +00:00
uvm_stat.c
uvm_stat.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_swap.c
uvm_swap.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm_unix.c
uvm_user.c
uvm_vnode.c
uvm_vnode.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00
uvm.h Protect prototypes, certain macros, and inlines from userland. 1999-06-21 17:25:11 +00:00