]> xenbits.xensource.com Git - people/iwj/osstest.git/commitdiff
ts-xen-build-prep: actually honour build_lvextend_max
authorIan Jackson <ian.jackson@eu.citrix.com>
Tue, 17 Sep 2013 14:01:05 +0000 (15:01 +0100)
committerWei Liu <wei.liu2@citrix.com>
Tue, 17 Sep 2013 15:05:01 +0000 (16:05 +0100)
ts-xen-build-prep

index daba0923fce177cdb0a6f03d82fc48921c754cf7..b1e6a6cc6cd53abe9fac47d5e7dcf0c48d7038d5 100755 (executable)
@@ -133,8 +133,8 @@ sub lvextend1 ($$$) {
 
     my $stripes_free = $stripe_count * $stripe_minfree;
     $do_limit_pe->(\$stripes_free, 'striped');
-    overall_limit_pe(\$stripes_free);
     if ($stripe_minfree && $stripe_count>1) {
+        overall_limit_pe(\$stripes_free);
         $more_pe += $stripes_free;
         target_cmd_root($ho, "lvextend -i$stripe_count -l +$stripes_free $lv");
     }
@@ -146,6 +146,7 @@ sub lvextend1 ($$$) {
 
     if ($vg_more_free_pe) {
         logm("$what: unstriped $vg_more_free_pe PEs");
+        overall_limit_pe(\$vg_more_free_pe);
         $more_pe += $vg_more_free_pe;
         target_cmd_root($ho, "lvextend -i1 -l +$vg_more_free_pe $lv");
     }