linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ext4: remove redundant offset check in move_extents.c/mext_check_arguments
@ 2012-07-23  8:03 Wang Sheng-Hui
  2012-09-27 12:03 ` Theodore Ts'o
  0 siblings, 1 reply; 2+ messages in thread
From: Wang Sheng-Hui @ 2012-07-23  8:03 UTC (permalink / raw)
  To: Andreas Dilger, Theodore Ts'o, ext4 development, linux-kernel

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>
---
 fs/ext4/move_extent.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/fs/ext4/move_extent.c b/fs/ext4/move_extent.c
index c5826c6..8383257 100644
--- a/fs/ext4/move_extent.c
+++ b/fs/ext4/move_extent.c
@@ -1002,7 +1002,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 "
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ext4: remove redundant offset check in move_extents.c/mext_check_arguments
  2012-07-23  8:03 [PATCH] ext4: remove redundant offset check in move_extents.c/mext_check_arguments Wang Sheng-Hui
@ 2012-09-27 12:03 ` Theodore Ts'o
  0 siblings, 0 replies; 2+ messages in thread
From: Theodore Ts'o @ 2012-09-27 12:03 UTC (permalink / raw)
  To: Wang Sheng-Hui; +Cc: Andreas Dilger, ext4 development, linux-kernel

On Mon, Jul 23, 2012 at 04:03:14PM +0800, Wang Sheng-Hui wrote:
> 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>

Applied, thanks.  (And apologies for the delay in getting back to
you!)

					- Ted

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-09-27 12:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-23  8:03 [PATCH] ext4: remove redundant offset check in move_extents.c/mext_check_arguments Wang Sheng-Hui
2012-09-27 12:03 ` Theodore Ts'o

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).