aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/quota/xfs_quota_priv.h
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2010-04-13 01:06:52 -0400
committerAlex Elder <aelder@sgi.com>2010-05-19 10:58:11 -0400
commit3a8406f6d6916e8211936edb9e1193123df2daab (patch)
tree53f490a433ef3bd2f430ef19cdfbbe5dc514e89d /fs/xfs/quota/xfs_quota_priv.h
parente6a81f13aa9aa20ef03174210aed24791865b05e (diff)
xfs: convert the dquot free list to use list heads
Convert the dquot free list on the filesystem to use listhead infrastructure rather than the roll-your-own in the quota code. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/quota/xfs_quota_priv.h')
-rw-r--r--fs/xfs/quota/xfs_quota_priv.h17
1 files changed, 0 insertions, 17 deletions
diff --git a/fs/xfs/quota/xfs_quota_priv.h b/fs/xfs/quota/xfs_quota_priv.h
index 3a1b9aa763fc..3eeee2e591df 100644
--- a/fs/xfs/quota/xfs_quota_priv.h
+++ b/fs/xfs/quota/xfs_quota_priv.h
@@ -40,13 +40,6 @@
40#define XFS_QI_IWARNLIMIT(mp) ((mp)->m_quotainfo->qi_iwarnlimit) 40#define XFS_QI_IWARNLIMIT(mp) ((mp)->m_quotainfo->qi_iwarnlimit)
41#define XFS_QI_QOFFLOCK(mp) ((mp)->m_quotainfo->qi_quotaofflock) 41#define XFS_QI_QOFFLOCK(mp) ((mp)->m_quotainfo->qi_quotaofflock)
42 42
43#define xfs_qm_freelist_lock(qm) \
44 mutex_lock(&((qm)->qm_dqfreelist.qh_lock))
45#define xfs_qm_freelist_lock_nowait(qm) \
46 mutex_trylock(&((qm)->qm_dqfreelist.qh_lock))
47#define xfs_qm_freelist_unlock(qm) \
48 mutex_unlock(&((qm)->qm_dqfreelist.qh_lock))
49
50/* 43/*
51 * Hash into a bucket in the dquot hash table, based on <mp, id>. 44 * Hash into a bucket in the dquot hash table, based on <mp, id>.
52 */ 45 */
@@ -72,16 +65,6 @@
72 !dqp->q_core.d_rtbcount && \ 65 !dqp->q_core.d_rtbcount && \
73 !dqp->q_core.d_icount) 66 !dqp->q_core.d_icount)
74 67
75#define FOREACH_DQUOT_IN_FREELIST(dqp, qlist) \
76for ((dqp) = (qlist)->qh_next; (dqp) != (xfs_dquot_t *)(qlist); \
77 (dqp) = (dqp)->dq_flnext)
78
79#define XQM_FREELIST_INSERT(h, dqp) \
80 xfs_qm_freelist_append(h, dqp)
81
82#define XQM_FREELIST_REMOVE(dqp) \
83 xfs_qm_freelist_unlink(dqp)
84
85#define XFS_DQ_IS_LOGITEM_INITD(dqp) ((dqp)->q_logitem.qli_dquot == (dqp)) 68#define XFS_DQ_IS_LOGITEM_INITD(dqp) ((dqp)->q_logitem.qli_dquot == (dqp))
86 69
87#define XFS_QM_DQP_TO_DQACCT(tp, dqp) (XFS_QM_ISUDQ(dqp) ? \ 70#define XFS_QM_DQP_TO_DQACCT(tp, dqp) (XFS_QM_ISUDQ(dqp) ? \