]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r337594 (by mmacy):
authormav <mav@FreeBSD.org>
Thu, 25 Apr 2019 15:31:35 +0000 (15:31 +0000)
committermav <mav@FreeBSD.org>
Thu, 25 Apr 2019 15:31:35 +0000 (15:31 +0000)
commit43d8821f6a4fc8ab72a8a4db49e42ec0f3049b42
treee3834ac45404941e32a556d99ed593b9e62e7977
parenta72b9b5134c0162141d1e73f2d2f9ab5aa1f0327
MFC r337594 (by mmacy):
ZFS/MFV:    Use cached feature info in spa_add_feature_stats()

commit 417104bdd3c7ce07ec58674dd078f9891c3bc780
Author: Ned Bass <bass6@llnl.gov>
Date:   Thu Feb 26 12:24:11 2015 -0800

    Use cached feature info in spa_add_feature_stats()

    Avoid issuing I/O to the pool when retrieving feature flags information.
    Trying to read the ZAPs from disk means that zpool clear would hang if
    the pool is suspended and recovery would require a reboot. To keep the
    feature stats resident in memory, we hang a cached nvlist off of the
    spa.  It is built up from disk the first time spa_add_feature_stats() is
    called, and refreshed thereafter using the cached feature reference
    counts. spa_add_feature_stats() gets called at pool import time so we
    can be sure the cached nvlist will be available if the pool is later
    suspended.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
    Closes #3082
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa_impl.h
sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfeature.c