summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2015-10-25 20:37:39 +0100
committerZdenek Kabelac <zkabelac@redhat.com>2015-10-25 21:07:37 +0100
commit844b00958492224c448b30f89ae5532bb6591fd2 (patch)
treed6d175b0e745a0ebf2a5c10ea1d95991751b5017
parent9ef820a2a5e174cd08097981d7879e1f4cbded01 (diff)
downloadlvm2-844b00958492224c448b30f89ae5532bb6591fd2.tar.gz
dev_manager: enabled no_flush for suspend
While the activation code tries to evaluate which target really needs flush with suspend and which may go without flush, it has stayed effectively disabled by original commit: 33f732c5e9493cda4b161a18b3d53885d207e3b8 since here it only allows to pass non-pvmoving 'mirrors'. So remove check for mirror LV type and only disable no_flush for 'pvmove'.. TODO: Looking into history - it also seemed like raid target would have always required flushing but it's been later removed without clean explanation. If some more targets really do need 'no_flush' it should been handle at their 'level' - since we now stack multiple targets over itself.
-rw-r--r--WHATS_NEW1
-rw-r--r--lib/activate/dev_manager.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/WHATS_NEW b/WHATS_NEW
index 8ca0aa7f5..33d11a46d 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.02.133 -
======================================
+ Enable code which detects the need of flush during suspend.
Ensure --use-policy will resize volume to fit below threshold.
Correct percentage evaluation when checking thin-pool over threshold.
Fix lvmcache to move PV from VG to orphans if VG is removed and lvmetad used.
diff --git a/lib/activate/dev_manager.c b/lib/activate/dev_manager.c
index a5ee824fb..1caa2d77a 100644
--- a/lib/activate/dev_manager.c
+++ b/lib/activate/dev_manager.c
@@ -3277,7 +3277,7 @@ static int _tree_action(struct dev_manager *dm, const struct logical_volume *lv,
break;
case SUSPEND:
dm_tree_skip_lockfs(root);
- if (!dm->flush_required && lv_is_mirror(lv) && !lv_is_pvmove(lv))
+ if (!dm->flush_required && !lv_is_pvmove(lv))
dm_tree_use_no_flush_suspend(root);
/* Fall through */
case SUSPEND_WITH_LOCKFS: