From: David Chinner Date: Thu, 17 Apr 2008 06:49:49 +0000 (+1000) Subject: [XFS] fix logic error in xfs_alloc_ag_vextent_near() X-Git-Tag: v2.6.26-rc1~1147^2~10 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=e6430037e9fd0b3d02ceaf5ab99bfe3ccb763be7;p=linux-2.6-omap-h63xx.git [XFS] fix logic error in xfs_alloc_ag_vextent_near() Fix a logic error in xfs_alloc_ag_vextent_near(). This is a regression introduced by the error handling changes. SGI-PV: 890084 SGI-Modid: xfs-linux-melb:xfs-kern:30838a Signed-off-by: David Chinner Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy --- diff --git a/fs/xfs/xfs_alloc.c b/fs/xfs/xfs_alloc.c index facdae14edd..1956f83489f 100644 --- a/fs/xfs/xfs_alloc.c +++ b/fs/xfs/xfs_alloc.c @@ -838,7 +838,7 @@ xfs_alloc_ag_vextent_near( XFS_WANT_CORRUPTED_GOTO(i == 1, error0); xfs_alloc_compute_aligned(ltbno, ltlen, args->alignment, args->minlen, <bnoa, <lena); - if (ltlena >= args->minlen) + if (ltlena < args->minlen) continue; args->len = XFS_EXTLEN_MIN(ltlena, args->maxlen); xfs_alloc_fix_len(args);