From: Zdenek Kabelac <zkabelac@sourceware.org>
To: lvm-devel@redhat.com
Subject: master - raid: add _rimage and _rmeta as origin_only
Date: Tue, 8 Sep 2020 22:03:41 +0000 (GMT) [thread overview]
Message-ID: <20200908220341.953F4385702B@sourceware.org> (raw)
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=3388e194892e9ab7a36b72e512796c2d218dae6e
Commit: 3388e194892e9ab7a36b72e512796c2d218dae6e
Parent: 3e6bb772287a6d7f753b08780c7e913c98f5e307
Author: Zdenek Kabelac <zkabelac@redhat.com>
AuthorDate: Tue Sep 8 21:06:23 2020 +0200
Committer: Zdenek Kabelac <zkabelac@redhat.com>
CommitterDate: Tue Sep 8 21:23:03 2020 +0200
raid: add _rimage and _rmeta as origin_only
Since we do not support rimage & rmeta for snapshots - we can
avoid quering for -cow devices and add them as origin_only -
since their snapshots (-cow) could have never existed.
This redumes several ioctl operation during table preloading.
---
WHATS_NEW | 1 +
lib/activate/dev_manager.c | 5 +++--
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index 1fffbb5d7..aa3960b31 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.03.11 -
==================================
+ Use _rmeta and _rimage as origin only devices for table loading.
Switch code base to use flexible array syntax.
Fix 64bit math when calculation cachevol size.
Preserve uint32_t for seqno handling.
diff --git a/lib/activate/dev_manager.c b/lib/activate/dev_manager.c
index a626b000a..e98cf578b 100644
--- a/lib/activate/dev_manager.c
+++ b/lib/activate/dev_manager.c
@@ -2642,10 +2642,11 @@ static int _add_lv_to_dtree(struct dev_manager *dm, struct dm_tree *dtree,
/* origin only for cache without pending delete */
(!dm->track_pending_delete || !lv_is_cache(lv)) &&
!_add_lv_to_dtree(dm, dtree, seg_lv(seg, s),
- lv_is_vdo_pool(seg_lv(seg, s)) ? 1 : 0))
+ (lv_is_vdo_pool(seg_lv(seg, s)) ||
+ lv_is_raid_image(seg_lv(seg, s))) ? 1 : 0))
return_0;
if (seg_is_raid_with_meta(seg) && seg->meta_areas && seg_metalv(seg, s) &&
- !_add_lv_to_dtree(dm, dtree, seg_metalv(seg, s), 0))
+ !_add_lv_to_dtree(dm, dtree, seg_metalv(seg, s), 1))
return_0;
}
reply other threads:[~2020-09-08 22:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200908220341.953F4385702B@sourceware.org \
--to=zkabelac@sourceware.org \
--cc=lvm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.