diff options
Diffstat (limited to 'fs/xfs/quota/xfs_qm.c')
| -rw-r--r-- | fs/xfs/quota/xfs_qm.c | 22 | 
1 files changed, 11 insertions, 11 deletions
diff --git a/fs/xfs/quota/xfs_qm.c b/fs/xfs/quota/xfs_qm.c index 38e76414664..8c117ff2e3a 100644 --- a/fs/xfs/quota/xfs_qm.c +++ b/fs/xfs/quota/xfs_qm.c @@ -249,8 +249,10 @@ xfs_qm_hold_quotafs_ref(  	if (!xfs_Gqm) {  		xfs_Gqm = xfs_Gqm_init(); -		if (!xfs_Gqm) +		if (!xfs_Gqm) { +			mutex_unlock(&xfs_Gqm_lock);  			return ENOMEM; +		}  	}  	/* @@ -1630,10 +1632,7 @@ xfs_qm_dqusage_adjust(  	xfs_ino_t	ino,		/* inode number to get data for */  	void		__user *buffer,	/* not used */  	int		ubsize,		/* not used */ -	void		*private_data,	/* not used */ -	xfs_daddr_t	bno,		/* starting block of inode cluster */  	int		*ubused,	/* not used */ -	void		*dip,		/* on-disk inode pointer (not used) */  	int		*res)		/* result code value */  {  	xfs_inode_t	*ip; @@ -1658,7 +1657,7 @@ xfs_qm_dqusage_adjust(  	 * the case in all other instances. It's OK that we do this because  	 * quotacheck is done only at mount time.  	 */ -	if ((error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_EXCL, &ip, bno))) { +	if ((error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_EXCL, &ip))) {  		*res = BULKSTAT_RV_NOTHING;  		return error;  	} @@ -1794,12 +1793,13 @@ xfs_qm_quotacheck(  		 * Iterate thru all the inodes in the file system,  		 * adjusting the corresponding dquot counters in core.  		 */ -		if ((error = xfs_bulkstat(mp, &lastino, &count, -				     xfs_qm_dqusage_adjust, NULL, -				     structsz, NULL, BULKSTAT_FG_IGET, &done))) +		error = xfs_bulkstat(mp, &lastino, &count, +				     xfs_qm_dqusage_adjust, +				     structsz, NULL, &done); +		if (error)  			break; -	} while (! done); +	} while (!done);  	/*  	 * We've made all the changes that we need to make incore. @@ -1887,14 +1887,14 @@ xfs_qm_init_quotainos(  		    mp->m_sb.sb_uquotino != NULLFSINO) {  			ASSERT(mp->m_sb.sb_uquotino > 0);  			if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_uquotino, -					     0, 0, &uip, 0))) +					     0, 0, &uip)))  				return XFS_ERROR(error);  		}  		if (XFS_IS_OQUOTA_ON(mp) &&  		    mp->m_sb.sb_gquotino != NULLFSINO) {  			ASSERT(mp->m_sb.sb_gquotino > 0);  			if ((error = xfs_iget(mp, NULL, mp->m_sb.sb_gquotino, -					     0, 0, &gip, 0))) { +					     0, 0, &gip))) {  				if (uip)  					IRELE(uip);  				return XFS_ERROR(error);  |