summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_trans.c
diff options
context:
space:
mode:
authorDavid Chinner <david@fromorbit.com>2008-10-30 17:39:46 +1100
committerLachlan McIlroy <lachlan@sgi.com>2008-10-30 17:39:46 +1100
commitfc1829f34d30899701dfd5890030d39e13e1f47d (patch)
treec2532c6a1070396e39000f36a5728f0f0940b24d /fs/xfs/xfs_trans.c
parenta9c21c1b9deaced836034e77fe25fe0b55c21f02 (diff)
[XFS] Add ail pointer into log items
Add an xfs_ail pointer to log items so that the log items can reference the AIL directly during callbacks without needed a struct xfs_mount. SGI-PV: 988143 SGI-Modid: xfs-linux-melb:xfs-kern:32352a Signed-off-by: David Chinner <david@fromorbit.com> Signed-off-by: Lachlan McIlroy <lachlan@sgi.com> Signed-off-by: Christoph Hellwig <hch@infradead.org>
Diffstat (limited to 'fs/xfs/xfs_trans.c')
-rw-r--r--fs/xfs/xfs_trans.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/xfs/xfs_trans.c b/fs/xfs/xfs_trans.c
index 99ba0e2658b..5163e1216c8 100644
--- a/fs/xfs/xfs_trans.c
+++ b/fs/xfs/xfs_trans.c
@@ -1383,11 +1383,13 @@ xfs_trans_chunk_committed(
xfs_log_item_desc_t *lidp;
xfs_log_item_t *lip;
xfs_lsn_t item_lsn;
- struct xfs_mount *mp;
int i;
lidp = licp->lic_descs;
for (i = 0; i < licp->lic_unused; i++, lidp++) {
+ struct xfs_mount *mp;
+ struct xfs_ail *ailp;
+
if (xfs_lic_isfree(licp, i)) {
continue;
}
@@ -1425,7 +1427,8 @@ xfs_trans_chunk_committed(
* the test below.
*/
mp = lip->li_mountp;
- spin_lock(&mp->m_ail->xa_lock);
+ ailp = lip->li_ailp;
+ spin_lock(&ailp->xa_lock);
if (XFS_LSN_CMP(item_lsn, lip->li_lsn) > 0) {
/*
* This will set the item's lsn to item_lsn
@@ -1436,7 +1439,7 @@ xfs_trans_chunk_committed(
*/
xfs_trans_update_ail(mp, lip, item_lsn);
} else {
- spin_unlock(&mp->m_ail->xa_lock);
+ spin_unlock(&ailp->xa_lock);
}
/*