summaryrefslogtreecommitdiffstats
path: root/drivers/md/persistent-data/dm-block-manager.c
diff options
context:
space:
mode:
authorMike Snitzer <snitzer@redhat.com>2012-12-21 21:23:34 +0100
committerAlasdair G Kergon <agk@redhat.com>2012-12-21 21:23:34 +0100
commita5bd968aeb87af4a3a96ecdd78912832997e8a9d (patch)
treecb12dce916dfdbde42d1cf283d6756590bfd82fb /drivers/md/persistent-data/dm-block-manager.c
parentdm raid: round region_size to power of two (diff)
downloadlinux-a5bd968aeb87af4a3a96ecdd78912832997e8a9d.tar.xz
linux-a5bd968aeb87af4a3a96ecdd78912832997e8a9d.zip
dm block manager: reinstate message when validator fails
Reinstate a useful error message when the block manager buffer validator fails. This was mistakenly eliminated when the block manager was converted to use dm-bufio. Signed-off-by: Mike Snitzer <snitzer@redhat.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Diffstat (limited to '')
-rw-r--r--drivers/md/persistent-data/dm-block-manager.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/md/persistent-data/dm-block-manager.c b/drivers/md/persistent-data/dm-block-manager.c
index 5ba277768d99..47b683e67a7c 100644
--- a/drivers/md/persistent-data/dm-block-manager.c
+++ b/drivers/md/persistent-data/dm-block-manager.c
@@ -428,8 +428,11 @@ static int dm_bm_validate_buffer(struct dm_block_manager *bm,
if (!v)
return 0;
r = v->check(v, (struct dm_block *) buf, dm_bufio_get_block_size(bm->bufio));
- if (unlikely(r))
+ if (unlikely(r)) {
+ DMERR("%s validator check failed for block %llu", v->name,
+ (unsigned long long) dm_bufio_get_block_number(buf));
return r;
+ }
aux->validator = v;
} else {
if (unlikely(aux->validator != v)) {