aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/quota/xfs_qm.c
diff options
context:
space:
mode:
authorDavid Chinner <david@fromorbit.com>2008-08-13 02:41:43 -0400
committerLachlan McIlroy <lachlan@redback.melbourne.sgi.com>2008-08-13 02:41:43 -0400
commite1f49cf20cea18e3d1963939fe8612a75e319fbd (patch)
tree3007ce4d1245487ed956c78591d9d4275793121f /fs/xfs/quota/xfs_qm.c
parentc63942d3eeffb98219e05d0976862ab9907d297d (diff)
[XFS] replace dquot flush semaphore with a completion
Use the new completion flush code to implement the dquot flush lock. Removes one of the final users of semaphores in the XFS code base. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31822a Signed-off-by: David Chinner <david@fromorbit.com> Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs/xfs/quota/xfs_qm.c')
-rw-r--r--fs/xfs/quota/xfs_qm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/xfs/quota/xfs_qm.c b/fs/xfs/quota/xfs_qm.c
index 021934a3d456..3825d7484079 100644
--- a/fs/xfs/quota/xfs_qm.c
+++ b/fs/xfs/quota/xfs_qm.c
@@ -484,7 +484,7 @@ again:
484 xfs_dqtrace_entry(dqp, "FLUSHALL: DQDIRTY"); 484 xfs_dqtrace_entry(dqp, "FLUSHALL: DQDIRTY");
485 /* XXX a sentinel would be better */ 485 /* XXX a sentinel would be better */
486 recl = XFS_QI_MPLRECLAIMS(mp); 486 recl = XFS_QI_MPLRECLAIMS(mp);
487 if (! xfs_qm_dqflock_nowait(dqp)) { 487 if (!xfs_dqflock_nowait(dqp)) {
488 /* 488 /*
489 * If we can't grab the flush lock then check 489 * If we can't grab the flush lock then check
490 * to see if the dquot has been flushed delayed 490 * to see if the dquot has been flushed delayed
@@ -1062,7 +1062,7 @@ xfs_qm_sync(
1062 1062
1063 /* XXX a sentinel would be better */ 1063 /* XXX a sentinel would be better */
1064 recl = XFS_QI_MPLRECLAIMS(mp); 1064 recl = XFS_QI_MPLRECLAIMS(mp);
1065 if (! xfs_qm_dqflock_nowait(dqp)) { 1065 if (!xfs_dqflock_nowait(dqp)) {
1066 if (nowait) { 1066 if (nowait) {
1067 xfs_dqunlock(dqp); 1067 xfs_dqunlock(dqp);
1068 continue; 1068 continue;
@@ -2079,7 +2079,7 @@ xfs_qm_shake_freelist(
2079 * Try to grab the flush lock. If this dquot is in the process of 2079 * Try to grab the flush lock. If this dquot is in the process of
2080 * getting flushed to disk, we don't want to reclaim it. 2080 * getting flushed to disk, we don't want to reclaim it.
2081 */ 2081 */
2082 if (! xfs_qm_dqflock_nowait(dqp)) { 2082 if (!xfs_dqflock_nowait(dqp)) {
2083 xfs_dqunlock(dqp); 2083 xfs_dqunlock(dqp);
2084 dqp = dqp->dq_flnext; 2084 dqp = dqp->dq_flnext;
2085 continue; 2085 continue;
@@ -2257,7 +2257,7 @@ xfs_qm_dqreclaim_one(void)
2257 * Try to grab the flush lock. If this dquot is in the process of 2257 * Try to grab the flush lock. If this dquot is in the process of
2258 * getting flushed to disk, we don't want to reclaim it. 2258 * getting flushed to disk, we don't want to reclaim it.
2259 */ 2259 */
2260 if (! xfs_qm_dqflock_nowait(dqp)) { 2260 if (!xfs_dqflock_nowait(dqp)) {
2261 xfs_dqunlock(dqp); 2261 xfs_dqunlock(dqp);
2262 continue; 2262 continue;
2263 } 2263 }