From: zkabelac@sourceware.org <zkabelac@sourceware.org>
To: lvm-devel@redhat.com
Subject: LVM2 ./WHATS_NEW lib/format_text/import.c lib/ ...
Date: 17 Jun 2011 14:39:11 -0000 [thread overview]
Message-ID: <20110617143911.4873.qmail@sourceware.org> (raw)
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: zkabelac at sourceware.org 2011-06-17 14:39:10
Modified files:
. : WHATS_NEW
lib/format_text: import.c
lib/metadata : metadata.c
Log message:
Code move of vg_mark_partial() up in stack
It's useful to keep the partial flag cached - so just move the call
for vg_mark_partil_lvs() into import_vg_from_config_tree() so it gets
evaluated before it goes through the lvmcache.
This patch should not present any functional change.
Note: It is rather temporal solution - proper place is probably inside the
'read' call back - but needs some more discussion.
For now using this minor hack.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.2021&r2=1.2022
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/format_text/import.c.diff?cvsroot=lvm2&r1=1.53&r2=1.54
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/metadata.c.diff?cvsroot=lvm2&r1=1.458&r2=1.459
--- LVM2/WHATS_NEW 2011/06/17 14:30:58 1.2021
+++ LVM2/WHATS_NEW 2011/06/17 14:39:10 1.2022
@@ -1,5 +1,6 @@
Version 2.02.86 -
=================================
+ Call vg_mark_partial_lvs() before VG structure is returned from the cache.
Remove unused internal flag ACTIVATE_EXCL from the code.
Remove useless test of ACTIVATE_EXCL in lv_add_mirrors() clustered code path.
Use lv_activate_opts struct instead of MERGING status flag.
--- LVM2/lib/format_text/import.c 2011/01/10 13:13:42 1.53
+++ LVM2/lib/format_text/import.c 2011/06/17 14:39:10 1.54
@@ -136,6 +136,7 @@
{
struct volume_group *vg = NULL;
struct text_vg_version_ops **vsn;
+ int vg_missing;
_init_text_import();
@@ -148,6 +149,12 @@
*/
if (!(vg = (*vsn)->read_vg(fid, cft, 1)))
stack;
+ else if ((vg_missing = vg_missing_pv_count(vg))) {
+ log_verbose("There are %d physical volumes missing.",
+ vg_missing);
+ vg_mark_partial_lvs(vg, 1);
+ /* FIXME: move this code inside read_vg() */
+ }
break;
}
--- LVM2/lib/metadata/metadata.c 2011/06/15 17:45:03 1.458
+++ LVM2/lib/metadata/metadata.c 2011/06/17 14:39:10 1.459
@@ -2868,11 +2868,6 @@
else /* Inconsistent but we can't repair it */
correct_vg->status &= ~INCONSISTENT_VG;
- if (vg_missing_pv_count(correct_vg)) {
- log_verbose("There are %d physical volumes missing.",
- vg_missing_pv_count(correct_vg));
- vg_mark_partial_lvs(correct_vg, 1);
- }
return correct_vg;
} else {
free_vg(correct_vg);
next reply other threads:[~2011-06-17 14:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-17 14:39 zkabelac [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-03-31 17:23 LVM2 ./WHATS_NEW lib/format_text/import.c lib/ mbroz
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=20110617143911.4873.qmail@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.