diff options
author | Mitsuo Hayasaka <mitsuo.hayasaka.hu@hitachi.com> | 2012-02-06 12:50:07 +0000 |
---|---|---|
committer | Ben Myers <bpm@sgi.com> | 2012-02-21 10:13:49 -0600 |
commit | d0a3fe67e30261bb2018d2a06f33ff3303438c8e (patch) | |
tree | de66c14ce3b0d75bbf0a1827a3eda369331af2ec /fs/xfs/xfs_trans_dquot.c | |
parent | f65020a83ad570c1788f7d8ece67f3487166576b (diff) | |
download | op-kernel-dev-d0a3fe67e30261bb2018d2a06f33ff3303438c8e.zip op-kernel-dev-d0a3fe67e30261bb2018d2a06f33ff3303438c8e.tar.gz |
xfs: change available ranges of softlimit and hardlimit in quota check
In general, quota allows us to use disk blocks and inodes up to each
limit, that is, they are available if they don't exceed their limitations.
Current xfs sets their available ranges to lower than them except disk
inode quota check. So, this patch changes the ranges to not beyond them.
Signed-off-by: Mitsuo Hayasaka <mitsuo.hayasaka.hu@hitachi.com>
Cc: Ben Myers <bpm@sgi.com>
Cc: Alex Elder <elder@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Mark Tinguely <tinguely@sgi.com>
Signed-off-by: Ben Myers <bpm@sgi.com>
(cherry picked from commit 20f12d8ac01917d96860f352f67eddd912df0afb)
Diffstat (limited to 'fs/xfs/xfs_trans_dquot.c')
-rw-r--r-- | fs/xfs/xfs_trans_dquot.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/xfs/xfs_trans_dquot.c b/fs/xfs/xfs_trans_dquot.c index 4d00ee6..85255536 100644 --- a/fs/xfs/xfs_trans_dquot.c +++ b/fs/xfs/xfs_trans_dquot.c @@ -649,12 +649,12 @@ xfs_trans_dqresv( * nblks. */ if (hardlimit > 0ULL && - hardlimit <= nblks + *resbcountp) { + hardlimit < nblks + *resbcountp) { xfs_quota_warn(mp, dqp, QUOTA_NL_BHARDWARN); goto error_return; } if (softlimit > 0ULL && - softlimit <= nblks + *resbcountp) { + softlimit < nblks + *resbcountp) { if ((timer != 0 && get_seconds() > timer) || (warns != 0 && warns >= warnlimit)) { xfs_quota_warn(mp, dqp, |