ref: 3cb26f0dbccb51de9a23976d24b0db045c995866
parent: e686e6cd460cc1767c1a6dcf19841d1d0df4bb7b
author: ngkaho1234 <ngkaho1234@gmail.com>
date: Wed Oct 28 10:20:10 EDT 2015
ext4_extent_full.c: print warning messages when extent block checksum verification fails
--- a/lwext4/ext4_extent_full.c
+++ b/lwext4/ext4_extent_full.c
@@ -392,6 +392,7 @@
ext4_fsblk_t pblk __unused)
{
struct ext4_extent_tail *tail;
+ struct ext4_sblock *sb = &inode_ref->fs->sb;
const char *error_msg;
(void)error_msg;
@@ -413,10 +414,13 @@
}
tail = find_ext4_extent_tail(eh);
- struct ext4_sblock *sb = &inode_ref->fs->sb;
if (ext4_sb_feature_ro_com(sb, EXT4_FRO_COM_METADATA_CSUM)) {
if (tail->et_checksum != to_le32(ext4_ext_block_csum(inode_ref, eh))) {
- /* FIXME: Warning: extent checksum damaged? */
+ ext4_dbg(DEBUG_EXTENT,
+ DBG_WARN "Extent block checksum failed."
+ "Blocknr: %" PRIu64"\n",
+ pblk);
+
}
}