ext4: remove redundant offset check in mext_check_arguments()
authorWang Sheng-Hui <shhuiw@gmail.com>
Thu, 27 Sep 2012 12:00:01 +0000 (08:00 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 27 Sep 2012 12:00:01 +0000 (08:00 -0400)
In the check code above, if orig_start != donor_start, we would
return -EINVAL. So here, orig_start should be equal with donor_start.
Remove the redundant check here.

Signed-off-by: Wang Sheng-Hui <shhuiw@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
fs/ext4/move_extent.c

index c2e47da7c2ba760e680590f6f08a276e9128e03d..cee4bd066b7af395361792ce964bba639718c44b 100644 (file)
@@ -1134,7 +1134,6 @@ mext_check_arguments(struct inode *orig_inode,
        }
 
        if ((orig_start >= EXT_MAX_BLOCKS) ||
-           (donor_start >= EXT_MAX_BLOCKS) ||
            (*len > EXT_MAX_BLOCKS) ||
            (orig_start + *len >= EXT_MAX_BLOCKS))  {
                ext4_debug("ext4 move extent: Can't handle over [%u] blocks "