]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit - contrib/unbound/libunbound/python/examples/ns-lookup.py
9018 Replace kmem_cache_reap_now() with kmem_cache_reap_soon()
authorAlexander Motin <mav@FreeBSD.org>
Wed, 21 Feb 2018 23:15:06 +0000 (23:15 +0000)
committerAlexander Motin <mav@FreeBSD.org>
Wed, 21 Feb 2018 23:15:06 +0000 (23:15 +0000)
commitb17bfcde3d6390b47114df7d325aee680424f19e
treeb0e7acc64c80b32bf032497b74d9bdc3b26dbc9e
parent603fe87c563c92bca3aefd576646e56fa8b686d2
parentffaf1cfabc59a59d45737e6330696b8e92c7b8c7
9018 Replace kmem_cache_reap_now() with kmem_cache_reap_soon()

illumos/illumos-gate@36a64e62848b51ac5a9a5216e894ec723cfef14e

To prevent kmem_cache reaping from blocking other system resources, turn
kmem_cache_reap_now() (which blocks) into kmem_cache_reap_soon(). Callers
to kmem_cache_reap_soon() should use kmem_cache_reap_active(), which
exploits #9017's new taskq_empty().

Reviewed by: Bryan Cantrill <bryan@joyent.com>
Reviewed by: Dan McDonald <danmcd@joyent.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Yuri Pankov <yuripv@yuripv.net>
Author: Tim Kordas <tim.kordas@joyent.com>

FreeBSD does not use taskqueue for kmem caches reaping, so this change
is less dramatic then it is on Illumos, just limiting reaping to 1 time
per second.  It may possibly be improved later, if needed.
cddl/contrib/opensolaris/lib/libzpool/common/sys/zfs_context.h
sys/cddl/compat/opensolaris/kern/opensolaris_kmem.c
sys/cddl/compat/opensolaris/sys/kmem.h
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c