Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 89413
b: refs/heads/master
c: 3c56836
h: refs/heads/master
i:
  89411: 2252e70
v: v3
  • Loading branch information
David Chinner authored and Lachlan McIlroy committed Apr 18, 2008
1 parent 0b9ccd8 commit a8e49d9
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4b8879df8c21bed3efd1eb2da5d72501199aba29
refs/heads/master: 3c56836f92683cb871ebbf44c512069b0d48a08f
10 changes: 6 additions & 4 deletions trunk/fs/xfs/quota/xfs_dquot.c
Original file line number Diff line number Diff line change
Expand Up @@ -1439,9 +1439,7 @@ xfs_qm_dqpurge(
uint flags)
{
xfs_dqhash_t *thishash;
xfs_mount_t *mp;

mp = dqp->q_mount;
xfs_mount_t *mp = dqp->q_mount;

ASSERT(XFS_QM_IS_MPLIST_LOCKED(mp));
ASSERT(XFS_DQ_IS_HASH_LOCKED(dqp->q_hash));
Expand Down Expand Up @@ -1485,6 +1483,7 @@ xfs_qm_dqpurge(
* we're unmounting, we do care, so we flush it and wait.
*/
if (XFS_DQ_IS_DIRTY(dqp)) {
int error;
xfs_dqtrace_entry(dqp, "DQPURGE ->DQFLUSH: DQDIRTY");
/* dqflush unlocks dqflock */
/*
Expand All @@ -1495,7 +1494,10 @@ xfs_qm_dqpurge(
* We don't care about getting disk errors here. We need
* to purge this dquot anyway, so we go ahead regardless.
*/
(void) xfs_qm_dqflush(dqp, XFS_QMOPT_SYNC);
error = xfs_qm_dqflush(dqp, XFS_QMOPT_SYNC);
if (error)
xfs_fs_cmn_err(CE_WARN, mp,
"xfs_qm_dqpurge: dquot %p flush failed", dqp);
xfs_dqflock(dqp);
}
ASSERT(dqp->q_pincount == 0);
Expand Down
7 changes: 6 additions & 1 deletion trunk/fs/xfs/quota/xfs_dquot_item.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ xfs_qm_dquot_logitem_push(
xfs_dq_logitem_t *logitem)
{
xfs_dquot_t *dqp;
int error;

dqp = logitem->qli_dquot;

Expand All @@ -161,7 +162,11 @@ xfs_qm_dquot_logitem_push(
* lock without sleeping, then there must not have been
* anyone in the process of flushing the dquot.
*/
xfs_qm_dqflush(dqp, XFS_B_DELWRI);
error = xfs_qm_dqflush(dqp, XFS_QMOPT_DELWRI);
if (error)
xfs_fs_cmn_err(CE_WARN, dqp->q_mount,
"xfs_qm_dquot_logitem_push: push error %d on dqp %p",
error, dqp);
xfs_dqunlock(dqp);
}

Expand Down
14 changes: 12 additions & 2 deletions trunk/fs/xfs/quota/xfs_qm.c
Original file line number Diff line number Diff line change
Expand Up @@ -2094,12 +2094,17 @@ xfs_qm_shake_freelist(
* dirty dquots.
*/
if (XFS_DQ_IS_DIRTY(dqp)) {
int error;
xfs_dqtrace_entry(dqp, "DQSHAKE: DQDIRTY");
/*
* We flush it delayed write, so don't bother
* releasing the mplock.
*/
(void) xfs_qm_dqflush(dqp, XFS_QMOPT_DELWRI);
error = xfs_qm_dqflush(dqp, XFS_QMOPT_DELWRI);
if (error) {
xfs_fs_cmn_err(CE_WARN, dqp->q_mount,
"xfs_qm_dqflush_all: dquot %p flush failed", dqp);
}
xfs_dqunlock(dqp); /* dqflush unlocks dqflock */
dqp = dqp->dq_flnext;
continue;
Expand Down Expand Up @@ -2266,12 +2271,17 @@ xfs_qm_dqreclaim_one(void)
* dirty dquots.
*/
if (XFS_DQ_IS_DIRTY(dqp)) {
int error;
xfs_dqtrace_entry(dqp, "DQRECLAIM: DQDIRTY");
/*
* We flush it delayed write, so don't bother
* releasing the freelist lock.
*/
(void) xfs_qm_dqflush(dqp, XFS_QMOPT_DELWRI);
error = xfs_qm_dqflush(dqp, XFS_QMOPT_DELWRI);
if (error) {
xfs_fs_cmn_err(CE_WARN, dqp->q_mount,
"xfs_qm_dqreclaim: dquot %p flush failed", dqp);
}
xfs_dqunlock(dqp); /* dqflush unlocks dqflock */
continue;
}
Expand Down

0 comments on commit a8e49d9

Please sign in to comment.