diff options
author | Lukas Czerner <lczerner@redhat.com> | 2012-03-19 23:07:43 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2012-03-19 23:07:43 -0400 |
commit | dc1841d6cff22b98deef46bfe768a9c678d917c2 (patch) | |
tree | 2d97eb9fd90fcd42bee4f5d7b7d9adb2459983f6 | |
parent | 7877191c28b1e140795c0c951dde8aad43757378 (diff) |
ext4: give more helpful error message in ext4_ext_rm_leaf()
The error message produced by the ext4_ext_rm_leaf() when we are
removing blocks which accidentally ends up inside the existing extent,
is not very helpful, because we would like to also know which extent did
we collide with.
This commit changes the error message to get us also the information
about the extent we are colliding with.
Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
-rw-r--r-- | fs/ext4/extents.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c index 9ac89b671047..5c9c067abca0 100644 --- a/fs/ext4/extents.c +++ b/fs/ext4/extents.c | |||
@@ -2366,8 +2366,11 @@ ext4_ext_rm_leaf(handle_t *handle, struct inode *inode, | |||
2366 | ex_ee_len = ext4_ext_get_actual_len(ex); | 2366 | ex_ee_len = ext4_ext_get_actual_len(ex); |
2367 | continue; | 2367 | continue; |
2368 | } else if (b != ex_ee_block + ex_ee_len - 1) { | 2368 | } else if (b != ex_ee_block + ex_ee_len - 1) { |
2369 | EXT4_ERROR_INODE(inode," bad truncate %u:%u\n", | 2369 | EXT4_ERROR_INODE(inode, |
2370 | start, end); | 2370 | "can not handle truncate %u:%u " |
2371 | "on extent %u:%u", | ||
2372 | start, end, ex_ee_block, | ||
2373 | ex_ee_block + ex_ee_len - 1); | ||
2371 | err = -EIO; | 2374 | err = -EIO; |
2372 | goto out; | 2375 | goto out; |
2373 | } else if (a != ex_ee_block) { | 2376 | } else if (a != ex_ee_block) { |