]> git.proxmox.com Git - mirror_zfs.git/commit
Make vdev_set_deferred_resilver() recursive
authorTom Caputi <tcaputi@datto.com>
Wed, 7 Nov 2018 23:33:17 +0000 (18:33 -0500)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 7 Nov 2018 23:33:17 +0000 (15:33 -0800)
commit4021ba4cfaa861602ae75d45713224d5a7866004
tree31347e819c53a5e42a41a36d132fa4e56a37e4e1
parent95692927f28479c2d3cf0c1e60ad278c8748377c
Make vdev_set_deferred_resilver() recursive

vdev_clear() can call vdev_set_deferred_resilver() with a
non-leaf vdev to setup a deferred resilver. However, this
function is currently written to only handle leaf vdevs.
This bug was introduced with deferred resilvers in 80a91e74.
This patch makes this function recursive so that it can find
appropriate vdevs to resilver and set vdev_resilver_deferred
on them.

Reviewed-by: Matthew Ahrens <mahrens@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tom Caputi <tcaputi@datto.com>
Issue #7732
Closes #8082
module/zfs/vdev.c