add subvol support for directory storage

This storage type does not support subvol quotas, so we
only allow this if vdisk_alloc is called with size=0.
This commit is contained in:
Dietmar Maurer
2015-08-12 06:04:41 +02:00
parent dec97937f2
commit 35533c68fb
3 changed files with 56 additions and 38 deletions

View File

@ -613,7 +613,7 @@ sub vdisk_free {
# lock shared storage
$plugin->cluster_lock_storage($storeid, $scfg->{shared}, undef, sub {
my ($vtype, $name, $vmid, undef, undef, $isBase) =
my ($vtype, $name, $vmid, undef, undef, $isBase, $format) =
$plugin->parse_volname($volname);
if ($isBase) {
my $vollist = $plugin->list_images($storeid, $scfg);
@ -633,7 +633,7 @@ sub vdisk_free {
}
}
}
$cleanup_worker = $plugin->free_image($storeid, $scfg, $volname, $isBase);
$cleanup_worker = $plugin->free_image($storeid, $scfg, $volname, $isBase, $format);
});
return if !$cleanup_worker;