kernel - allow PG_NOTMETA to be set on regular files too
authorMatthew Dillon <dillon@apollo.backplane.com>
Sat, 2 Apr 2011 23:05:58 +0000 (16:05 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 2 Apr 2011 23:05:58 +0000 (16:05 -0700)
commitbfa86281b980fee652fa89f854faf34a4b9689ad
tree4e5d4a7bd8ba8ea585d5f3e8361aa78c0fcfe4bf
parente523b88119129cef0ed7e0ef9984e04fb12ca3ca
kernel - allow PG_NOTMETA to be set on regular files too

* Allow this flag to be set for VM pages associated with regular files
  too, the flag prevents the related VM page from being swapcache'd.

  The flag is set by HAMMER on normal file buffer cache buffers when
  double buffering is enabled to prevent swapcache from caching the
  data twice.

* This also fixes an issue when a large number of files exceeding the
  maxvnode limit are recycled, and double buffering is enabled along
  with vm.swapcache.data_enable.  We do not want swapcache to try to
  cache the pages via the vnode, instead we'd rather it cache them
  via the block device (whos vnode doesn't get recycled).
sys/vm/swap_pager.h
sys/vm/vm_swapcache.c