Commit eaab4bde authored by Erich Eckner's avatar Erich Eckner Committed by Mike Snitzer

dm integrity: print device name in integrity_metadata() error message

Similar to f710126c ("dm crypt: print
device name in integrity error message"), this message should also
better identify the device with the integrity failure.
Signed-off-by: default avatarErich Eckner <git@eckner.net>
Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>
parent 3fd53533
...@@ -1558,7 +1558,8 @@ static void integrity_metadata(struct work_struct *w) ...@@ -1558,7 +1558,8 @@ static void integrity_metadata(struct work_struct *w)
checksums_ptr - checksums, !dio->write ? TAG_CMP : TAG_WRITE); checksums_ptr - checksums, !dio->write ? TAG_CMP : TAG_WRITE);
if (unlikely(r)) { if (unlikely(r)) {
if (r > 0) { if (r > 0) {
DMERR_LIMIT("Checksum failed at sector 0x%llx", char b[BDEVNAME_SIZE];
DMERR_LIMIT("%s: Checksum failed at sector 0x%llx", bio_devname(bio, b),
(unsigned long long)(sector - ((r + ic->tag_size - 1) / ic->tag_size))); (unsigned long long)(sector - ((r + ic->tag_size - 1) / ic->tag_size)));
r = -EILSEQ; r = -EILSEQ;
atomic64_inc(&ic->number_of_mismatches); atomic64_inc(&ic->number_of_mismatches);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment