[PATCH] mutex subsystem, semaphore to mutex: XFS
This patch switches XFS over to use the new mutex code directly as opposed to the previous workaround patch I posted earlier that avoided the namespace clash by forcing it back to semaphores. This falls in the 'works for me<tm>' category. Signed-off-by: Jes Sorensen <jes@trained-monkey.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
committed by
Ingo Molnar
parent
de5097c2e7
commit
794ee1baee
@@ -167,7 +167,7 @@ xfs_Gqm_init(void)
|
||||
xqm->qm_dqfree_ratio = XFS_QM_DQFREE_RATIO;
|
||||
xqm->qm_nrefs = 0;
|
||||
#ifdef DEBUG
|
||||
mutex_init(&qcheck_lock, MUTEX_DEFAULT, "qchk");
|
||||
xfs_mutex_init(&qcheck_lock, MUTEX_DEFAULT, "qchk");
|
||||
#endif
|
||||
return xqm;
|
||||
}
|
||||
@@ -1166,7 +1166,7 @@ xfs_qm_init_quotainfo(
|
||||
qinf->qi_dqreclaims = 0;
|
||||
|
||||
/* mutex used to serialize quotaoffs */
|
||||
mutex_init(&qinf->qi_quotaofflock, MUTEX_DEFAULT, "qoff");
|
||||
mutex_init(&qinf->qi_quotaofflock);
|
||||
|
||||
/* Precalc some constants */
|
||||
qinf->qi_dqchunklen = XFS_FSB_TO_BB(mp, XFS_DQUOT_CLUSTER_SIZE_FSB);
|
||||
@@ -1285,7 +1285,7 @@ xfs_qm_list_init(
|
||||
char *str,
|
||||
int n)
|
||||
{
|
||||
mutex_init(&list->qh_lock, MUTEX_DEFAULT, str);
|
||||
mutex_init(&list->qh_lock);
|
||||
list->qh_next = NULL;
|
||||
list->qh_version = 0;
|
||||
list->qh_nelems = 0;
|
||||
@@ -2762,7 +2762,7 @@ STATIC void
|
||||
xfs_qm_freelist_init(xfs_frlist_t *ql)
|
||||
{
|
||||
ql->qh_next = ql->qh_prev = (xfs_dquot_t *) ql;
|
||||
mutex_init(&ql->qh_lock, MUTEX_DEFAULT, "dqf");
|
||||
mutex_init(&ql->qh_lock);
|
||||
ql->qh_version = 0;
|
||||
ql->qh_nelems = 0;
|
||||
}
|
||||
@@ -2772,7 +2772,7 @@ xfs_qm_freelist_destroy(xfs_frlist_t *ql)
|
||||
{
|
||||
xfs_dquot_t *dqp, *nextdqp;
|
||||
|
||||
mutex_lock(&ql->qh_lock, PINOD);
|
||||
mutex_lock(&ql->qh_lock);
|
||||
for (dqp = ql->qh_next;
|
||||
dqp != (xfs_dquot_t *)ql; ) {
|
||||
xfs_dqlock(dqp);
|
||||
|
Reference in New Issue
Block a user