]> git.proxmox.com Git - mirror_zfs.git/commit
port async unlinked drain from illumos-nexenta
authorAlek P <alek-p@users.noreply.github.com>
Tue, 12 Feb 2019 18:41:15 +0000 (10:41 -0800)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 12 Feb 2019 18:41:15 +0000 (10:41 -0800)
commitdcec0a12c8e480262288ac76f6350652079ea173
tree1f23e1c575dc61d00484b627f61e1b5e9ba6bac0
parent425d3237ee88abc53d8522a7139c926d278b4b7f
port async unlinked drain from illumos-nexenta

This patch is an async implementation of the existing sync
zfs_unlinked_drain() function. This function is called at mount time and
is responsible for freeing znodes that we didn't get to freeing before.
We don't have to hold mounting of the dataset until the unlinked list is
fully drained as is done now. Since we can process the unlinked set
asynchronously this results in a better user experience when mounting a
dataset with entries in the unlinked set.

Reviewed by: Jorgen Lundman <lundman@lundman.net>
Reviewed by: Tom Caputi <tcaputi@datto.com>
Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Matt Ahrens <mahrens@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Signed-off-by: Alek Pinchuk <apinchuk@datto.com>
Closes #8142
13 files changed:
include/sys/dataset_kstats.h
include/sys/dsl_pool.h
include/sys/zfs_dir.h
include/sys/zfs_vfsops.h
man/man5/zfs-module-parameters.5
module/zfs/dataset_kstats.c
module/zfs/dsl_pool.c
module/zfs/zfs_dir.c
module/zfs/zfs_vfsops.c
module/zfs/zfs_znode.c
tests/runfiles/linux.run
tests/zfs-tests/tests/functional/mount/Makefile.am
tests/zfs-tests/tests/functional/mount/umount_unlinked_drain.ksh [new file with mode: 0755]