Commit 4b8879df authored by David Chinner's avatar David Chinner Committed by Lachlan McIlroy

[XFS] Propagate xfs_qm_dqflush_all() errors.

xfs_qm_dqflush_all() can return flush errors. Ensure they are propagated
into the quotacheck code to determine if the quotacheck succeeded or not.

SGI-PV: 980084
SGI-Modid: xfs-linux-melb:xfs-kern:30786a
Signed-off-by: default avatarDavid Chinner <dgc@sgi.com>
Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
parent 5b139738
...@@ -1877,6 +1877,14 @@ xfs_qm_quotacheck( ...@@ -1877,6 +1877,14 @@ xfs_qm_quotacheck(
} while (! done); } while (! done);
/*
* We've made all the changes that we need to make incore.
* Flush them down to disk buffers if everything was updated
* successfully.
*/
if (!error)
error = xfs_qm_dqflush_all(mp, XFS_QMOPT_DELWRI);
/* /*
* We can get this error if we couldn't do a dquot allocation inside * We can get this error if we couldn't do a dquot allocation inside
* xfs_qm_dqusage_adjust (via bulkstat). We don't care about the * xfs_qm_dqusage_adjust (via bulkstat). We don't care about the
...@@ -1888,11 +1896,6 @@ xfs_qm_quotacheck( ...@@ -1888,11 +1896,6 @@ xfs_qm_quotacheck(
xfs_qm_dqpurge_all(mp, XFS_QMOPT_QUOTALL | XFS_QMOPT_QUOTAOFF); xfs_qm_dqpurge_all(mp, XFS_QMOPT_QUOTALL | XFS_QMOPT_QUOTAOFF);
goto error_return; goto error_return;
} }
/*
* We've made all the changes that we need to make incore.
* Now flush_them down to disk buffers.
*/
xfs_qm_dqflush_all(mp, XFS_QMOPT_DELWRI);
/* /*
* We didn't log anything, because if we crashed, we'll have to * We didn't log anything, because if we crashed, we'll have to
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment