aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/quota/xfs_qm.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/quota/xfs_qm.c')
-rw-r--r--fs/xfs/quota/xfs_qm.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/fs/xfs/quota/xfs_qm.c b/fs/xfs/quota/xfs_qm.c
index 38e764146644..8c117ff2e3ab 100644
--- a/fs/xfs/quota/xfs_qm.c
+++ b/fs/xfs/quota/xfs_qm.c
@@ -249,8 +249,10 @@ xfs_qm_hold_quotafs_ref(
249 249
250 if (!xfs_Gqm) { 250 if (!xfs_Gqm) {
251 xfs_Gqm = xfs_Gqm_init(); 251 xfs_Gqm = xfs_Gqm_init();
252 if (!xfs_Gqm) 252 if (!xfs_Gqm) {
253 mutex_unlock(&xfs_Gqm_lock);
253 return ENOMEM; 254 return ENOMEM;
255 }
254 } 256 }
255 257
256 /* 258 /*
@@ -1630,10 +1632,7 @@ xfs_qm_dqusage_adjust(
1630 xfs_ino_t ino, /* inode number to get data for */ 1632 xfs_ino_t ino, /* inode number to get data for */
1631 void __user *buffer, /* not used */ 1633 void __user *buffer, /* not used */
1632 int ubsize, /* not used */ 1634 int ubsize, /* not used */
1633 void *private_data, /* not used */
1634 xfs_daddr_t bno, /* starting block of inode cluster */
1635 int *ubused, /* not used */ 1635 int *ubused, /* not used */
1636 void *dip, /* on-disk inode pointer (not used) */
1637 int *res) /* result code value */ 1636 int *res) /* result code value */
1638{ 1637{
1639 xfs_inode_t *ip; 1638 xfs_inode_t *ip;
@@ -1658,7 +1657,7 @@ xfs_qm_dqusage_adjust(
1658 * the case in all other instances. It's OK that we do this because 1657 * the case in all other instances. It's OK that we do this because
1659 * quotacheck is done only at mount time. 1658 * quotacheck is done only at mount time.
1660 */ 1659 */
1661 if ((error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_EXCL, &ip, bno))) { 1660 if ((error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_EXCL, &ip))) {
1662 *res = BULKSTAT_RV_NOTHING; 1661 *res = BULKSTAT_RV_NOTHING;
1663 return error; 1662 return error;
1664 } 1663 }
@@ -1794,12 +1793,13 @@ xfs_qm_quotacheck(
1794 * Iterate thru all the inodes in the file system, 1793 * Iterate thru all the inodes in the file system,
1795 * adjusting the corresponding dquot counters in core. 1794 * adjusting the corresponding dquot counters in core.
1796 */ 1795 */
1797 if ((error = xfs_bulkstat(mp, &lastino, &count, 1796 error = xfs_bulkstat(mp, &lastino, &count,
1798 xfs_qm_dqusage_adjust, NULL, 1797 xfs_qm_dqusage_adjust,
1799 structsz, NULL, BULKSTAT_FG_IGET, &done))) 1798 structsz, NULL, &done);
1799 if (error)
1800 break; 1800 break;
1801 1801
1802 } while (! done); 1802 } while (!done);
1803 1803
1804 /* 1804 /*
1805 * We've made all the changes that we need to make incore. 1805 * We've made all the changes that we need to make incore.
@@ -1887,14 +1887,14 @@ xfs_qm_init_quotainos(
1887 mp->m_sb.sb_uquotino != NULLFSINO) { 1887 mp->m_sb.sb_uquotino != NULLFSINO) {
1888 ASSERT(mp->m_sb.sb_uquotino > 0); 1888 ASSERT(mp->m_sb.sb_uquotino > 0);
1889 if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_uquotino, 1889 if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_uquotino,
1890 0, 0, &uip, 0))) 1890 0, 0, &uip)))
1891 return XFS_ERROR(error); 1891 return XFS_ERROR(error);
1892 } 1892 }
1893 if (XFS_IS_OQUOTA_ON(mp) && 1893 if (XFS_IS_OQUOTA_ON(mp) &&
1894 mp->m_sb.sb_gquotino != NULLFSINO) { 1894 mp->m_sb.sb_gquotino != NULLFSINO) {
1895 ASSERT(mp->m_sb.sb_gquotino > 0); 1895 ASSERT(mp->m_sb.sb_gquotino > 0);
1896 if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_gquotino, 1896 if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_gquotino,
1897 0, 0, &gip, 0))) { 1897 0, 0, &gip))) {
1898 if (uip) 1898 if (uip)
1899 IRELE(uip); 1899 IRELE(uip);
1900 return XFS_ERROR(error); 1900 return XFS_ERROR(error);