Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 319460
b: refs/heads/master
c: f09996c
h: refs/heads/master
v: v3
  • Loading branch information
Mike Snitzer authored and Alasdair G Kergon committed Jul 27, 2012
1 parent 6c22428 commit eb0819f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1a66a08ae82b16eb40705ad112ff28873981af92
refs/heads/master: f09996c993e256fce4b920588959866998d51250
8 changes: 6 additions & 2 deletions trunk/drivers/md/dm-thin.c
Original file line number Diff line number Diff line change
Expand Up @@ -1828,15 +1828,19 @@ static struct pool *__pool_find(struct mapped_device *pool_md,
struct pool *pool = __pool_table_lookup_metadata_dev(metadata_dev);

if (pool) {
if (pool->pool_md != pool_md)
if (pool->pool_md != pool_md) {
*error = "metadata device already in use by a pool";
return ERR_PTR(-EBUSY);
}
__pool_inc(pool);

} else {
pool = __pool_table_lookup(pool_md);
if (pool) {
if (pool->md_dev != metadata_dev)
if (pool->md_dev != metadata_dev) {
*error = "different pool cannot replace a pool";
return ERR_PTR(-EINVAL);
}
__pool_inc(pool);

} else {
Expand Down

0 comments on commit eb0819f

Please sign in to comment.