diff options
author | Alex Elder <elder@inktank.com> | 2013-04-30 01:44:32 -0400 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-05-02 00:20:10 -0400 |
commit | 96882f55c40dcb4cd80b81a4374fdd297109ec98 (patch) | |
tree | 68a83f8542a659aa6e5f398f0448d538ce999deb /drivers/block | |
parent | 812164f8c3f6f5348aa69003a2f81775c2872ac0 (diff) |
rbd: fix up the layering warning message
A warning gets spewed for any image being probed, including parent
images. Set up a condition such that the warning message only gets
printed for the image being mapped, not any of its parents.
Also, I didn't like the way the warning ended up being so long.
Make it a terse warning instead. People experimenting with layering
will know what the message means.
This is part of:
http://tracker.ceph.com/issues/4867
Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/rbd.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c index 5c1c38dc0b51..71e2de2cff22 100644 --- a/drivers/block/rbd.c +++ b/drivers/block/rbd.c | |||
@@ -4624,8 +4624,15 @@ static int rbd_dev_v2_probe(struct rbd_device *rbd_dev) | |||
4624 | ret = rbd_dev_v2_parent_info(rbd_dev); | 4624 | ret = rbd_dev_v2_parent_info(rbd_dev); |
4625 | if (ret) | 4625 | if (ret) |
4626 | goto out_err; | 4626 | goto out_err; |
4627 | rbd_warn(rbd_dev, "WARNING: kernel support for " | 4627 | |
4628 | "layered rbd images is EXPERIMENTAL!"); | 4628 | /* |
4629 | * Don't print a warning for parent images. We can | ||
4630 | * tell this point because we won't know its pool | ||
4631 | * name yet (just its pool id). | ||
4632 | */ | ||
4633 | if (rbd_dev->spec->pool_name) | ||
4634 | rbd_warn(rbd_dev, "WARNING: kernel layering " | ||
4635 | "is EXPERIMENTAL!"); | ||
4629 | } | 4636 | } |
4630 | 4637 | ||
4631 | /* If the image supports fancy striping, get its parameters */ | 4638 | /* If the image supports fancy striping, get its parameters */ |