summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAkira Fujita2009-09-06 04:11:55 +0200
committerTheodore Ts'o2009-09-06 04:11:55 +0200
commitdaea696dbac0e33af3cfe304efbfb8d74e0effe6 (patch)
tree35b64870a9377d1a89d2891084623bca8dd13e70
parentext4: Fix wrong comparisons in mext_check_arguments() (diff)
downloadkernel-qcow2-linux-daea696dbac0e33af3cfe304efbfb8d74e0effe6.tar.gz
kernel-qcow2-linux-daea696dbac0e33af3cfe304efbfb8d74e0effe6.tar.xz
kernel-qcow2-linux-daea696dbac0e33af3cfe304efbfb8d74e0effe6.zip
ext4: Remove unneeded BUG_ON() in ext4_move_extents()
The ext4_move_extents() functions checks with BUG_ON() whether the exchanged blocks count accords with request blocks count. But, if the target range (orig_start + len) includes sparse block(s), 'moved_len' (exchanged blocks count) does not agree with 'len' (request blocks count), since sparse block is not counted in 'moved_len'. This causes us to hit the BUG_ON(), even though the function succeeded. Signed-off-by: Akira Fujita <a-fujita@rs.jp.nec.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
-rw-r--r--fs/ext4/move_extent.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/fs/ext4/move_extent.c b/fs/ext4/move_extent.c
index c593eb2b193a..c8c66b167cd7 100644
--- a/fs/ext4/move_extent.c
+++ b/fs/ext4/move_extent.c
@@ -1322,8 +1322,5 @@ out2:
if (ret)
return ret;
- /* All of the specified blocks must be exchanged in succeed */
- BUG_ON(*moved_len != len);
-
return 0;
}