From 20507534d4ede14d4dd82c99fc8d461704ce7419 Mon Sep 17 00:00:00 2001 From: Alexander Motin Date: Tue, 3 Apr 2018 14:57:15 -0400 Subject: [PATCH] OpenZFS 9434 - Speculative prefetch is blocked by device removal code Device removal code does not set spa_indirect_vdevs_loaded for pools that never experienced device removal. At least one visual consequence of it is completely blocked speculative prefetcher. This patch sets the variable in such situations. Authored by: Alexander Motin Reviewed by: Matthew Ahrens Reviewed by: Prashanth Sreenivasa Reviewed-by: George Melikov Reviewed-by: Brian Behlendorf Reviewed-by: Tim Chase Approved by: Matt Ahrens Ported-by: Giuseppe Di Natale OpenZFS-issue: https://www.illumos.org/issues/9434 OpenZFS-commit: https://github.com/openzfs/openzfs/commit/16127b627b Closes #7480 --- module/zfs/vdev_removal.c | 1 + 1 file changed, 1 insertion(+) diff --git a/module/zfs/vdev_removal.c b/module/zfs/vdev_removal.c index 0fca8fb03..826e5c421 100644 --- a/module/zfs/vdev_removal.c +++ b/module/zfs/vdev_removal.c @@ -352,6 +352,7 @@ spa_remove_init(spa_t *spa) spa->spa_removing_phys.sr_state = DSS_NONE; spa->spa_removing_phys.sr_removing_vdev = -1; spa->spa_removing_phys.sr_prev_indirect_vdev = -1; + spa->spa_indirect_vdevs_loaded = B_TRUE; return (0); } else if (error != 0) { return (error); -- 2.40.0