summaryrefslogtreecommitdiffstats
path: root/fs/xfs/quota/xfs_trans_dquot.c
diff options
context:
space:
mode:
authorLinus Torvalds2009-04-03 18:52:29 +0200
committerLinus Torvalds2009-04-03 18:52:29 +0200
commitac7c1a776dfe1a9c83ea7885f858f5f1a144d8af (patch)
tree4ad3158dd6dc5029a221421ae9a3c339f10c3f10 /fs/xfs/quota/xfs_trans_dquot.c
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6 (diff)
parentMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torval... (diff)
downloadkernel-qcow2-linux-ac7c1a776dfe1a9c83ea7885f858f5f1a144d8af.tar.gz
kernel-qcow2-linux-ac7c1a776dfe1a9c83ea7885f858f5f1a144d8af.tar.xz
kernel-qcow2-linux-ac7c1a776dfe1a9c83ea7885f858f5f1a144d8af.zip
Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs
* 'for-linus' of git://oss.sgi.com/xfs/xfs: (61 commits) Revert "xfs: increase the maximum number of supported ACL entries" xfs: cleanup uuid handling xfs: remove m_attroffset xfs: fix various typos xfs: pagecache usage optimization xfs: remove m_litino xfs: kill ino64 mount option xfs: kill mutex_t typedef xfs: increase the maximum number of supported ACL entries xfs: factor out code to find the longest free extent in the AG xfs: kill VN_BAD xfs: kill vn_atime_* helpers. xfs: cleanup xlog_bread xfs: cleanup xlog_recover_do_trans xfs: remove another leftover of the old inode log item format xfs: cleanup log unmount handling Fix xfs debug build breakage by pushing xfs_error.h after xfs: include header files for prototypes xfs: make symbols static xfs: move declaration to header file ...
Diffstat (limited to 'fs/xfs/quota/xfs_trans_dquot.c')
-rw-r--r--fs/xfs/quota/xfs_trans_dquot.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/fs/xfs/quota/xfs_trans_dquot.c b/fs/xfs/quota/xfs_trans_dquot.c
index 99611381e740..447173bcf96d 100644
--- a/fs/xfs/quota/xfs_trans_dquot.c
+++ b/fs/xfs/quota/xfs_trans_dquot.c
@@ -624,10 +624,9 @@ xfs_trans_dqresv(
xfs_qcnt_t *resbcountp;
xfs_quotainfo_t *q = mp->m_quotainfo;
- if (! (flags & XFS_QMOPT_DQLOCK)) {
- xfs_dqlock(dqp);
- }
- ASSERT(XFS_DQ_IS_LOCKED(dqp));
+
+ xfs_dqlock(dqp);
+
if (flags & XFS_TRANS_DQ_RES_BLKS) {
hardlimit = be64_to_cpu(dqp->q_core.d_blk_hardlimit);
if (!hardlimit)
@@ -740,10 +739,8 @@ xfs_trans_dqresv(
ASSERT(dqp->q_res_icount >= be64_to_cpu(dqp->q_core.d_icount));
error_return:
- if (! (flags & XFS_QMOPT_DQLOCK)) {
- xfs_dqunlock(dqp);
- }
- return (error);
+ xfs_dqunlock(dqp);
+ return error;
}
@@ -753,8 +750,7 @@ error_return:
* grp/prj quotas is important, because this follows a both-or-nothing
* approach.
*
- * flags = XFS_QMOPT_DQLOCK indicate if dquot(s) need to be locked.
- * XFS_QMOPT_FORCE_RES evades limit enforcement. Used by chown.
+ * flags = XFS_QMOPT_FORCE_RES evades limit enforcement. Used by chown.
* XFS_QMOPT_ENOSPC returns ENOSPC not EDQUOT. Used by pquota.
* XFS_TRANS_DQ_RES_BLKS reserves regular disk blocks
* XFS_TRANS_DQ_RES_RTBLKS reserves realtime disk blocks