From: "Jun'ichi Nomura" <j-nomura@ce.jp.nec.com>
To: linux-lvm@redhat.com, Alasdair Kergon <agk@redhat.com>,
Jonathan Brassow <jbrassow@redhat.com>
Subject: [linux-lvm] [PATCH LVM2] Fix _for_each_pv() to return correct segment end
Date: Tue, 29 Aug 2006 13:12:21 -0400 [thread overview]
Message-ID: <44F47575.6090006@ce.jp.nec.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 486 bytes --]
Hi,
_for_each_pv() is a function to walk through all PVs used by
given part of LV. The function is expected to set smallest length
of PV segment consists of the part of LV.
However, current code doesn't work as expected.
As a result, build_parallel_areas_from_lv() considers only the
first segment of the LV and fails to build appropriate list of
PVs to be avoided.
Attached patch fixes this problem.
Applicable to 2.02.09.
Thanks,
--
Jun'ichi Nomura, NEC Corporation of America
[-- Attachment #2: 01-fix-for_each_pv-to-return-correct-segment-end.patch --]
[-- Type: text/x-patch, Size: 869 bytes --]
_for_each_pv() is a function to walk through all PVs used by
given part of LV. The function is expected to set smallest length
of PV segment consists of the part of LV.
However, current code doesn't work as expected.
As a result, build_parallel_areas_from_lv() considers only the
first segment of the LV and fails to build appropriate list of
PVs to be avoided.
diff -urp LVM2.00/lib/metadata/lv_manip.c LVM2.01/lib/metadata/lv_manip.c
--- LVM2.00/lib/metadata/lv_manip.c 2006-08-25 03:50:56.000000000 -0400
+++ LVM2.01/lib/metadata/lv_manip.c 2006-08-26 00:06:29.000000000 -0400
@@ -1358,7 +1358,7 @@ static int _for_each_pv(struct cmd_conte
/* Remaining logical length of segment */
remaining_seg_len = seg->len - (le - seg->le);
- if (len > remaining_seg_len)
+ if (remaining_seg_len > len)
remaining_seg_len = len;
if (spvs->len > remaining_seg_len)
reply other threads:[~2006-08-29 17:12 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=44F47575.6090006@ce.jp.nec.com \
--to=j-nomura@ce.jp.nec.com \
--cc=agk@redhat.com \
--cc=jbrassow@redhat.com \
--cc=linux-lvm@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.