freebsd-dev/include
Brian Behlendorf f604673836 Make arc_prune() asynchronous
As described in the comment above arc_adapt_thread() it is critical
that the arc_adapt_thread() function never sleep while holding a hash
lock.  This behavior was possible in the Linux implementation because
the arc_prune() logic was implemented to be synchronous.  Under
illumos the analogous dnlc_reduce_cache() function is asynchronous.

To address this the arc_do_user_prune() function is has been reworked
in to two new functions as follows:

* arc_prune_async() is an asynchronous implementation which dispatches
the prune callback to be run by the system taskq.  This makes it
suitable to use in the context of the arc_adapt_thread().

* arc_prune() is a synchronous implementation which depends on the
arc_prune_async() implementation but blocks until the outstanding
callbacks complete.  This is used in arc_kmem_reap_now() where it
is safe, and expected, that memory will be freed.

This patch additionally adds the zfs_arc_meta_strategy module option
while allows the meta reclaim strategy to be configured.  It defaults
to a balanced strategy which has been proved to work well under Linux
but the illumos meta-only strategy can be enabled.

Signed-off-by: Tim Chase <tim@chase2k.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
2015-06-11 10:27:25 -07:00
..
linux Linux 2.6.36 compat, use REQ_FAILFAST_MASK and remove pre-2.6.36 support 2015-05-11 15:07:00 -07:00
sys Make arc_prune() asynchronous 2015-06-11 10:27:25 -07:00
libnvpair.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libuutil_common.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libuutil_impl.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libuutil.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libzfs_core.h Illumos 5027 - zfs large block support 2015-05-11 12:23:16 -07:00
libzfs_impl.h Illumos 4368, 4369. 2014-07-29 10:55:29 -07:00
libzfs.h Add libzfs_error_init() function 2015-05-22 13:34:58 -07:00
Makefile.am Kernel header installation should respect --prefix 2014-10-28 09:37:06 -07:00
zfeature_common.h Illumos 5027 - zfs large block support 2015-05-11 12:23:16 -07:00
zfs_comutil.h Illumos #2882, #2883, #2900 2013-09-04 15:49:00 -07:00
zfs_deleg.h Illumos 4368, 4369. 2014-07-29 10:55:29 -07:00
zfs_fletcher.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
zfs_namecheck.h Illumos 4368, 4369. 2014-07-29 10:55:29 -07:00
zfs_prop.h Check the dataset type more rigorously when fetching properties. 2014-05-06 10:41:46 -07:00
zpios-ctl.h Update code to use misc_register()/misc_deregister() 2014-10-17 14:58:44 -07:00
zpios-internal.h cstyle: Resolve C style issues 2013-12-18 16:46:35 -08:00