[lvm-devel] LVM2/lib/metadata lv_manip.c
zkabelac at sourceware.org
zkabelac at sourceware.org
Thu Mar 1 10:09:37 UTC 2012
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: zkabelac at sourceware.org 2012-03-01 10:09:37
Modified files:
lib/metadata : lv_manip.c
Log message:
Add stack trace for lv_reduce
Use common code call with stack trace.
TODO: maybe the release_lv_segment_area()
should be actually able to return error code to upper level.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/lv_manip.c.diff?cvsroot=lvm2&r1=1.368&r2=1.369
--- LVM2/lib/metadata/lv_manip.c 2012/02/29 22:08:58 1.368
+++ LVM2/lib/metadata/lv_manip.c 2012/03/01 10:09:36 1.369
@@ -312,13 +312,10 @@
return;
}
- if (seg_lv(seg, s)->status & MIRROR_IMAGE) {
- lv_reduce(seg_lv(seg, s), area_reduction);
- return;
- }
-
- if (seg_lv(seg, s)->status & THIN_POOL_DATA) {
- lv_reduce(seg_lv(seg, s), area_reduction);
+ if ((seg_lv(seg, s)->status & MIRROR_IMAGE) ||
+ (seg_lv(seg, s)->status & THIN_POOL_DATA)) {
+ if (!lv_reduce(seg_lv(seg, s), area_reduction))
+ stack; /* FIXME: any upper level reporting */
return;
}
More information about the lvm-devel
mailing list