diff options
author | David Teigland <teigland@redhat.com> | 2021-06-17 16:15:18 -0500 |
---|---|---|
committer | Marian Csontos <mcsontos@redhat.com> | 2021-08-11 13:02:02 +0200 |
commit | 303017a9095317946fa0244670a5cc7ed35125f5 (patch) | |
tree | e88934b8076c0d715c12ec12c7572479fcdc2181 | |
parent | 4d6035d2a8b9c7bd3eef9ca66c4c4838401e595d (diff) | |
download | lvm2-303017a9095317946fa0244670a5cc7ed35125f5.tar.gz |
lvconvert: allow writecache with other thinpool command syntax
"lvconvert --thinpool LV" should allow LV to have a writecache,
but there was an extra type check preventing it.
(cherry picked from commit c35f7722d588009edad22d59c68c82150bb5c216)
(cherry picked from commit 118ba7161355132420296546711baf13d94fa36f)
-rw-r--r-- | tools/lvconvert.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/lvconvert.c b/tools/lvconvert.c index 8dd8a15c4..6066d1f46 100644 --- a/tools/lvconvert.c +++ b/tools/lvconvert.c @@ -4803,7 +4803,7 @@ static int _lvconvert_to_pool_or_swap_metadata_single(struct cmd_context *cmd, switch (cmd->command->command_enum) { case lvconvert_to_thinpool_or_swap_metadata_CMD: - if (lv_is_cache(lv)) + if (lv_is_cache(lv) || lv_is_writecache(lv)) /* For cached LV check the cache origin LV type */ lvt_enum = get_lvt_enum(seg_lv(first_seg(lv), 0)); to_thinpool = 1; |