]> git.proxmox.com Git - mirror_zfs.git/commit - include/libzfs.h
changelist should be able to iter on mounts
authorAlek P <alek-p@users.noreply.github.com>
Tue, 2 Oct 2018 19:30:58 +0000 (15:30 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 2 Oct 2018 19:30:58 +0000 (12:30 -0700)
commit0c6d09361dd8ab83f3193e6d7f398b4d20c9c300
treeea69b6b72b1629286b8026cd18813744b9469b31
parent838bd5ff35db04695ba4eadc7fdb2d56ff816ee5
changelist should be able to iter on mounts

Modified changelist_gather()ing for the mountpoint property.
Now instead of iterating on all dataset descendants, we read
/proc/self/mounts and iterate on the mounted descendant datasets only.

Switched changelist implementation from a uu_list_* to uu_avl_* in
order to  reduce changlist code-path's worst case time complexity.

Reviewed by: Don Brady <don.brady@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alek Pinchuk <apinchuk@datto.com>
Closes #7967
include/libzfs.h
lib/libzfs/libzfs_changelist.c
lib/libzfs/libzfs_iter.c
tests/runfiles/linux.run
tests/zfs-tests/tests/functional/cli_root/zfs_unmount/Makefile.am
tests/zfs-tests/tests/functional/cli_root/zfs_unmount/zfs_unmount_nested.ksh [new file with mode: 0755]