master - WHATS_NEW
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=3003a9a7be35dc...
Commit: 3003a9a7be35dc8a6f87ceddd5cdc9bf6b021bfa
Parent: 22bfac5dc24f0f10be270cf86e9d7bc2d627cc6c
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Aug 27 16:52:32 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Aug 27 16:52:32 2014 +0200
WHATS_NEW
---
WHATS_NEW | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index 46d5791..02ee1b0 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.02.111 -
===================================
+ Fix regression in cache pool allocation (2.02.110).
Version 2.02.110 - 26th August 2014
===================================
9 years, 8 months
master - cache: fix allocation size
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=22bfac5dc24f0f...
Commit: 22bfac5dc24f0f10be270cf86e9d7bc2d627cc6c
Parent: 8b9eb95ea9d2a950286f622f6d2d571c76642654
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Aug 27 16:45:39 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Aug 27 16:47:14 2014 +0200
cache: fix allocation size
Commit 0b3d0e79f694ac9dc5a29270b2f791a250980058 caused regression
in allocation of cache pool. This patch is restoring corect size
for allocation.
---
lib/metadata/lv_manip.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index a5614f6..baf431f 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -1655,8 +1655,10 @@ static struct alloc_handle *_alloc_init(struct cmd_context *cmd,
ah->region_size = 0;
ah->mirror_logs_separate =
find_config_tree_bool(cmd, allocation_cache_pool_metadata_require_separate_pvs_CFG, NULL);
- if (!ah->mirror_logs_separate)
+ if (!ah->mirror_logs_separate) {
ah->alloc_and_split_meta = 1;
+ total_extents += ah->log_len;
+ }
} else {
ah->log_area_count = metadata_area_count;
ah->log_len = !metadata_area_count ? 0 :
9 years, 8 months
master - cache: Clean-up error message.
by Jonathan Brassow
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=8b9eb95ea9d2a9...
Commit: 8b9eb95ea9d2a950286f622f6d2d571c76642654
Parent: dd9700f1925dbe20e657765400a80b62a9d0adb3
Author: Jonathan Brassow <jbrassow(a)redhat.com>
AuthorDate: Sun Aug 24 19:44:37 2014 -0500
Committer: Jonathan Brassow <jbrassow(a)redhat.com>
CommitterDate: Sun Aug 24 19:44:37 2014 -0500
cache: Clean-up error message.
It is not an internal error message to report to the user that they
cannot create a cache LV on top of a cache LV. It is simply not
supported yet.
---
lib/metadata/cache_manip.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/lib/metadata/cache_manip.c b/lib/metadata/cache_manip.c
index f617f4e..04e165f 100644
--- a/lib/metadata/cache_manip.c
+++ b/lib/metadata/cache_manip.c
@@ -117,9 +117,8 @@ struct logical_volume *lv_cache_create(struct logical_volume *pool,
* The origin under the origin would become *_corig_corig
* before renaming the origin above to *_corig.
*/
- log_error(INTERNAL_ERROR
- "The origin, %s, cannot be of cache type",
- origin->name);
+ log_error("Creating a cache LV from an existing cache LV is"
+ "not yet supported.");
return NULL;
}
9 years, 8 months
master - post-release
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=dd9700f1925dbe...
Commit: dd9700f1925dbe20e657765400a80b62a9d0adb3
Parent: 8b8d21f8733d800dd672bcc629b20d8585d2021a
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Tue Aug 26 16:41:18 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Tue Aug 26 16:41:18 2014 +0100
post-release
---
VERSION | 2 +-
VERSION_DM | 2 +-
WHATS_NEW | 3 +++
WHATS_NEW_DM | 3 +++
4 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/VERSION b/VERSION
index 86bdbb0..234d9db 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.02.110(2)-git (2014-08-26)
+2.02.111(2)-git (2014-08-26)
diff --git a/VERSION_DM b/VERSION_DM
index 27fe4c7..fe3203c 100644
--- a/VERSION_DM
+++ b/VERSION_DM
@@ -1 +1 @@
-1.02.89-git (2014-08-26)
+1.02.90-git (2014-08-26)
diff --git a/WHATS_NEW b/WHATS_NEW
index 1d82ed5..46d5791 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,3 +1,6 @@
+Version 2.02.111 -
+===================================
+
Version 2.02.110 - 26th August 2014
===================================
Fix manipulation with thin-pools which are excluded via volume_list.
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index 83119f6..afdb1d0 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,3 +1,6 @@
+Version 1.02.90 -
+==================================
+
Version 1.02.89 - 26th August 2014
==================================
Improve libdevmapper-event select() error handling.
9 years, 8 months
master - pre-release
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=8b8d21f8733d80...
Commit: 8b8d21f8733d800dd672bcc629b20d8585d2021a
Parent: 50babdf123349f9efdcf91f63d11bfece98ee6ab
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Tue Aug 26 16:34:14 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Tue Aug 26 16:34:14 2014 +0100
pre-release
---
VERSION | 2 +-
VERSION_DM | 2 +-
WHATS_NEW | 5 +++--
WHATS_NEW_DM | 5 +++--
lib/metadata/lv_manip.c | 4 ++--
lib/report/columns.h | 2 +-
man/lvm.8.in | 5 ++---
tools/lvconvert.c | 2 +-
8 files changed, 14 insertions(+), 13 deletions(-)
diff --git a/VERSION b/VERSION
index 81e874b..86bdbb0 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.02.110(2)-git (2014-08-05)
+2.02.110(2)-git (2014-08-26)
diff --git a/VERSION_DM b/VERSION_DM
index f2b3ee8..27fe4c7 100644
--- a/VERSION_DM
+++ b/VERSION_DM
@@ -1 +1 @@
-1.02.89-git (2014-08-05)
+1.02.89-git (2014-08-26)
diff --git a/WHATS_NEW b/WHATS_NEW
index 2e27043..1d82ed5 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,9 +1,10 @@
-Version 2.02.110 -
-==================================
+Version 2.02.110 - 26th August 2014
+===================================
Fix manipulation with thin-pools which are excluded via volume_list.
Support lv/vgremove -ff to remove thin vols from broken/inactive thin pools.
Fix typo breaking configure --with-lvm1=shared.
Modify lvresize code to handle raid/mirrors and physical extents.
+ Don't allow pvcreate to proceed if scanning or filtering fails.
Cleanly error when creating RAID with stripe size < PAGE_SIZE.
Print name of LV which on activation triggers delayed snapshot merge.
Add lv_layout and lv_role LV reporting fields.
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index 484cb7e..83119f6 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,5 +1,6 @@
-Version 1.02.89 -
-=================================
+Version 1.02.89 - 26th August 2014
+==================================
+ Improve libdevmapper-event select() error handling.
Add extra check for matching transation_id after message submitting.
Add dm_report_field_string_list_unsorted for str. list report without sorting.
Support --deferred with dmsetup remove to defer removal of open devices.
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index 3d91856..a5614f6 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -6570,8 +6570,8 @@ static struct logical_volume *_lv_create_an_lv(struct volume_group *vg,
* volumes as well. Avoiding doing that now
* only to minimize the change.
*/
- log_error("The extent size in volume group %s is too"
- " small to support striped RAID volumes.",
+ log_error("The extent size in volume group %s is too "
+ "small to support striped RAID volumes.",
vg->name);
return NULL;
}
diff --git a/lib/report/columns.h b/lib/report/columns.h
index 78f5832..796ac4e 100644
--- a/lib/report/columns.h
+++ b/lib/report/columns.h
@@ -148,7 +148,7 @@ FIELD(VGS, vg, SIZ, "VMdaFree", cmd, 9, vgmdafree, vg_mda_free, "Free metadata a
FIELD(VGS, vg, SIZ, "VMdaSize", cmd, 9, vgmdasize, vg_mda_size, "Size of smallest metadata area for this VG in current units.", 0)
FIELD(VGS, vg, NUM, "#VMdaCps", cmd, 8, vgmdacopies, vg_mda_copies, "Target number of in use metadata areas in the VG.", 1)
-FIELD(SEGS, seg, STR, "SegType", list, 4, segtype, segtype, "Type of LV segment.", 0)
+FIELD(SEGS, seg, STR, "Type", list, 4, segtype, segtype, "Type of LV segment.", 0)
FIELD(SEGS, seg, NUM, "#Str", area_count, 4, uint32, stripes, "Number of stripes or mirror legs.", 0)
FIELD(SEGS, seg, SIZ, "Stripe", stripe_size, 6, size32, stripesize, "For stripes, amount of data placed on one device before switching to the next.", 0)
FIELD(SEGS, seg, SIZ, "Stripe", stripe_size, 6, size32, stripe_size, "For stripes, amount of data placed on one device before switching to the next.", 0)
diff --git a/man/lvm.8.in b/man/lvm.8.in
index 069194c..c6f72a3 100644
--- a/man/lvm.8.in
+++ b/man/lvm.8.in
@@ -345,9 +345,8 @@ The valid characters for VG and LV names are:
VG and LV names cannot begin with a hyphen.
There are also various reserved names that are used internally by lvm that can not be used as LV or VG names.
A VG cannot be called anything that exists in /dev/ at the time of creation, nor can it be called '.' or '..'.
-A LV cannot be called '.' '..' 'snapshot' or 'pvmove'. The LV name may also not contain
-the strings '_cdata', '_cmeta', '_mlog', '_mimage', '_pmspare',
-'_rimage', '_rlog', '_tdata', '_tmeta'.
+An LV cannot be called '.', '..', 'snapshot' or 'pvmove'. The LV name may also not contain any of the following
+strings: '_cdata', '_cmeta', '_mlog', '_mimage', '_pmspare', '_rimage', '_rlog', '_tdata' or '_tmeta'.
A directory bearing the name of each Volume Group is created under /dev when any of its Logical Volumes are activated.
Each active Logical Volume is accessible from this directory as a symbolic link leading to a device node.
Links or nodes in /dev/mapper are intended only for internal use and the precise format and escaping might change between releases and distributions.
diff --git a/tools/lvconvert.c b/tools/lvconvert.c
index cf8d2c0..185cd59 100644
--- a/tools/lvconvert.c
+++ b/tools/lvconvert.c
@@ -2217,7 +2217,7 @@ static int _lvconvert_merge_old_snapshot(struct cmd_context *cmd,
if (!vg_commit(lv->vg))
return_0;
r = 1;
- log_print_unless_silent("Merging of snapshot %s will start "
+ log_print_unless_silent("Merging of snapshot %s will occur on "
"next activation of %s.",
display_lvname(lv), display_lvname(origin));
goto out;
9 years, 8 months
master - revert: commit 8d00499167f010b82ea6ddebcc6b22ec170002f9
by Peter Rajnoha
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=50babdf123349f...
Commit: 50babdf123349f9efdcf91f63d11bfece98ee6ab
Parent: 70e998754e852fd3052daa5d79213af2f632ac44
Author: Peter Rajnoha <prajnoha(a)redhat.com>
AuthorDate: Tue Aug 26 17:07:37 2014 +0200
Committer: Peter Rajnoha <prajnoha(a)redhat.com>
CommitterDate: Tue Aug 26 17:07:37 2014 +0200
revert: commit 8d00499167f010b82ea6ddebcc6b22ec170002f9
Let's test this more...
---
WHATS_NEW | 1 -
tools/lvconvert.c | 6 ++----
2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index 9ddb232..2e27043 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -4,7 +4,6 @@ Version 2.02.110 -
Support lv/vgremove -ff to remove thin vols from broken/inactive thin pools.
Fix typo breaking configure --with-lvm1=shared.
Modify lvresize code to handle raid/mirrors and physical extents.
- Allow conversion of raid1 LV into a snapshot LV or snapshot origin LV.
Cleanly error when creating RAID with stripe size < PAGE_SIZE.
Print name of LV which on activation triggers delayed snapshot merge.
Add lv_layout and lv_role LV reporting fields.
diff --git a/tools/lvconvert.c b/tools/lvconvert.c
index 00bfe80..cf8d2c0 100644
--- a/tools/lvconvert.c
+++ b/tools/lvconvert.c
@@ -2041,7 +2041,7 @@ static int _lvconvert_snapshot(struct cmd_context *cmd,
{
struct logical_volume *org;
- if ((lv->status & MIRRORED) && !lv_is_raid(lv)) {
+ if (lv->status & MIRRORED) {
log_error("Unable to convert mirrored LV \"%s\" into a snapshot.", lv->name);
return 0;
}
@@ -2066,9 +2066,7 @@ static int _lvconvert_snapshot(struct cmd_context *cmd,
if (!cow_has_min_chunks(lv->vg, lv->le_count, lp->chunk_size))
return_0;
- if ((org->status & (LOCKED|PVMOVE)) ||
- ((org->status & MIRRORED) && !lv_is_raid(org)) ||
- lv_is_cow(org)) {
+ if (org->status & (LOCKED|PVMOVE|MIRRORED) || lv_is_cow(org)) {
log_error("Unable to convert an LV into a snapshot of a %s LV.",
org->status & LOCKED ? "locked" :
org->status & PVMOVE ? "pvmove" :
9 years, 8 months
master - tests: thin and volume_list testing
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=70e998754e852f...
Commit: 70e998754e852fd3052daa5d79213af2f632ac44
Parent: c37ca279e33b532f00da4b2f50e8e1ad547e8a77
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Tue Aug 26 12:26:17 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Tue Aug 26 14:13:07 2014 +0200
tests: thin and volume_list testing
---
test/shell/thin-volume-list.sh | 51 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 51 insertions(+), 0 deletions(-)
diff --git a/test/shell/thin-volume-list.sh b/test/shell/thin-volume-list.sh
new file mode 100644
index 0000000..b53e772
--- /dev/null
+++ b/test/shell/thin-volume-list.sh
@@ -0,0 +1,51 @@
+#!/bin/bash
+# Copyright (C) 2014 Red Hat, Inc. All rights reserved.
+#
+# This copyrighted material is made available to anyone wishing to use,
+# modify, copy, or redistribute it subject to the terms and conditions
+# of the GNU General Public License v.2.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+# test pool behaviour when volume_list masks activation
+
+. lib/inittest
+
+#
+# Main
+#
+aux have_thin 1 0 0 || skip
+
+aux prepare_vg 2
+
+lvcreate -T -L8M $vg/pool -V10M -n $lv1
+
+aux lvmconf "activation/volume_list = [ \"$vg1\" ]"
+
+# We still could pass - since pool is still active
+lvcreate -V10 -n $lv2 -T $vg/pool
+
+# but $lv2 is not active
+check inactive $vg $lv2
+
+vgchange -an $vg
+
+# skip $vg from activation
+aux lvmconf "activation/volume_list = [ \"$vg1\" ]"
+
+# Pool is not active - so it cannot create thin volume
+not lvcreate -V10 -T $vg/pool
+
+aux lvmconf "activation/volume_list = [ \"$vg\" ]"
+
+lvcreate -V10 -T $vg/pool
+
+lvs -o +transaction_id,thin_id $vg
+
+lvremove -ff $vg
+
+check vg_field $vg lv_count "0"
+
+vgremove -ff $vg
9 years, 8 months
master - tests: fix volume list test
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=c37ca279e33b53...
Commit: c37ca279e33b532f00da4b2f50e8e1ad547e8a77
Parent: 25fe716b123109dee83a593d3c354ffac13b06b1
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Tue Aug 26 12:09:03 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Tue Aug 26 14:13:07 2014 +0200
tests: fix volume list test
Proper use of \" escaping and shell vars.
---
test/shell/lvchange-thin.sh | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/test/shell/lvchange-thin.sh b/test/shell/lvchange-thin.sh
index cb9be53..4d33563 100644
--- a/test/shell/lvchange-thin.sh
+++ b/test/shell/lvchange-thin.sh
@@ -99,7 +99,7 @@ not lvchange --resync --addtag foo $vg/$lv1
# Play with tags and activation
#
TAG=$(uname -n)
-aux lvmconf 'activation/volume_list = [ "$vg/$lv2", "@mytag", "$vg2" ]'
+aux lvmconf "activation/volume_list = [ \"$vg/$lv2\", \"@mytag\" ]"
lvchange -ay $vg/$lv1
check inactive $vg $lv1
@@ -123,9 +123,11 @@ not lvcreate -Zy -L10 -n $lv3 $vg2
lvcreate -Zn -L10 -n $lv3 $vg2
check inactive $vg2 $lv3
-aux lvmconf 'activation/volume_list = [ "$vg2" ]'
+aux lvmconf "activation/volume_list = [ \"$vg2\" ]"
vgchange -an $vg
vgchange -ay $vg $vg2
lvs -a -o+lv_active $vg $vg2
+aux lvmconf "activation/volume_list = [ \"$vg\", \"$vg2\" ]"
+
vgremove -ff $vg $vg2
9 years, 8 months
master - cleanup: indent and stacktrack
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=25fe716b123109...
Commit: 25fe716b123109dee83a593d3c354ffac13b06b1
Parent: 24001a08ab92737b32968aeba5f6b2b9c036c480
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Tue Aug 26 11:39:51 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Tue Aug 26 14:13:07 2014 +0200
cleanup: indent and stacktrack
Add missing stacktrace on error path
and newline indent.
---
lib/activate/dev_manager.c | 2 +-
lib/metadata/lv_manip.c | 1 +
lib/metadata/metadata.c | 2 +-
3 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/activate/dev_manager.c b/lib/activate/dev_manager.c
index 2cf0b65..d336afc 100644
--- a/lib/activate/dev_manager.c
+++ b/lib/activate/dev_manager.c
@@ -2330,7 +2330,7 @@ static int _add_target_to_dtree(struct dev_manager *dm,
&dm->target_state, seg,
laopts, dnode,
extent_size * seg->len,
- &dm-> pvmove_mirror_count);
+ &dm->pvmove_mirror_count);
}
static int _add_new_lv_to_dtree(struct dev_manager *dm, struct dm_tree *dtree,
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index e57e7b3..3d91856 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -5698,6 +5698,7 @@ int lv_remove_with_dependencies(struct cmd_context *cmd, struct logical_volume *
if (lv_is_used_thin_pool(lv) &&
!_lv_remove_segs_using_this_lv(cmd, lv, force, level, "pool"))
return_0;
+
if ((lv_is_thin_pool(lv) || lv_is_cache_pool(lv)) &&
lv->vg->pool_metadata_spare_lv) {
/* When removing last pool, also remove the spare */
diff --git a/lib/metadata/metadata.c b/lib/metadata/metadata.c
index 168c110..f8ffe30 100644
--- a/lib/metadata/metadata.c
+++ b/lib/metadata/metadata.c
@@ -531,7 +531,7 @@ int remove_lvs_in_vg(struct cmd_context *cmd,
while ((lst = dm_list_first(&vg->lvs))) {
lvl = dm_list_item(lst, struct lv_list);
if (!lv_remove_with_dependencies(cmd, lvl->lv, force, 0))
- return 0;
+ return_0;
}
return 1;
9 years, 8 months
master - cleanup: check pv_count is not 0
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=24001a08ab9273...
Commit: 24001a08ab92737b32968aeba5f6b2b9c036c480
Parent: 3b5afac9b433dd26f4461d4f59401bbb299219ec
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Thu Aug 21 15:38:18 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Tue Aug 26 14:13:06 2014 +0200
cleanup: check pv_count is not 0
Since we already detect writemostly_ARG is non-zero
make it obvious pv_count will also be non-zero in this case.
---
tools/lvchange.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/tools/lvchange.c b/tools/lvchange.c
index 42769c2..0981f2c 100644
--- a/tools/lvchange.c
+++ b/tools/lvchange.c
@@ -740,9 +740,8 @@ static int lvchange_writemostly(struct logical_volume *lv)
if (arg_count(cmd, writebehind_ARG))
raid_seg->writebehind = arg_uint_value(cmd, writebehind_ARG, 0);
- if (arg_count(cmd, writemostly_ARG)) {
+ if ((pv_count = arg_count(cmd, writemostly_ARG))) {
/* writemostly can be specified more than once */
- pv_count = arg_count(cmd, writemostly_ARG);
pv_names = dm_pool_alloc(lv->vg->vgmem, sizeof(char *) * pv_count);
if (!pv_names)
return_0;
9 years, 8 months