[XFS] correctly select first log item to push
authorDavid Chinner <david@fromorbit.com>
Thu, 30 Oct 2008 07:26:51 +0000 (18:26 +1100)
committerLachlan McIlroy <lachlan@redback.melbourne.sgi.com>
Thu, 30 Oct 2008 07:26:51 +0000 (18:26 +1100)
Under heavy metadata load we are seeing log hangs. The AIL has items in it
ready to be pushed, and they are within the push target window. However,
we are not pushing them when the last pushed LSN is less than the LSN of
the first log item on the AIL. This is a regression introduced by the AIL
push cursor modifications.

SGI-PV: 987246

SGI-Modid: xfs-linux-melb:xfs-kern:32409a

Signed-off-by: David Chinner <david@fromorbit.com>
Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Signed-off-by: Tim Shimmin <tes@sgi.com>
fs/xfs/xfs_trans_ail.c

index 67ee4663336cba0de57dd99c87896b14f27e8b60..2d47f10f8bed4cbe9b2441a29649311c2aa0acae 100644 (file)
@@ -228,7 +228,7 @@ xfs_trans_ail_cursor_first(
 
        list_for_each_entry(lip, &ailp->xa_ail, li_ail) {
                if (XFS_LSN_CMP(lip->li_lsn, lsn) >= 0)
-                       break;
+                       goto out;
        }
        lip = NULL;
 out: