diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2020-07-14 19:37:32 +0200 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2020-07-29 05:24:14 +0200 |
commit | 438769e31e4410a20ea0df0ed1769516ae80740d (patch) | |
tree | 3a1193e01e87e6e123f5dfb5c5bdc59914c74bf6 /fs/xfs/xfs_qm.h | |
parent | xfs: remove qcore from incore dquots (diff) | |
download | linux-438769e31e4410a20ea0df0ed1769516ae80740d.tar.xz linux-438769e31e4410a20ea0df0ed1769516ae80740d.zip |
xfs: refactor default quota limits by resource
Now that we've split up the dquot resource fields into separate structs,
do the same for the default limits to enable further refactoring.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Chandan Babu R <chandanrlinux@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/xfs_qm.h')
-rw-r--r-- | fs/xfs/xfs_qm.h | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/fs/xfs/xfs_qm.h b/fs/xfs/xfs_qm.h index 57bddadbc051..11c28ff0298c 100644 --- a/fs/xfs/xfs_qm.h +++ b/fs/xfs/xfs_qm.h @@ -30,20 +30,18 @@ extern struct kmem_zone *xfs_qm_dqtrxzone; !dqp->q_rtb.count && \ !dqp->q_ino.count) +struct xfs_quota_limits { + xfs_qcnt_t hard; /* default hard limit */ + xfs_qcnt_t soft; /* default soft limit */ + time64_t time; /* limit for timers */ + xfs_qwarncnt_t warn; /* limit for warnings */ +}; + /* Defaults for each quota type: time limits, warn limits, usage limits */ struct xfs_def_quota { - time64_t btimelimit; /* limit for blks timer */ - time64_t itimelimit; /* limit for inodes timer */ - time64_t rtbtimelimit; /* limit for rt blks timer */ - xfs_qwarncnt_t bwarnlimit; /* limit for blks warnings */ - xfs_qwarncnt_t iwarnlimit; /* limit for inodes warnings */ - xfs_qwarncnt_t rtbwarnlimit; /* limit for rt blks warnings */ - xfs_qcnt_t bhardlimit; /* default data blk hard limit */ - xfs_qcnt_t bsoftlimit; /* default data blk soft limit */ - xfs_qcnt_t ihardlimit; /* default inode count hard limit */ - xfs_qcnt_t isoftlimit; /* default inode count soft limit */ - xfs_qcnt_t rtbhardlimit; /* default realtime blk hard limit */ - xfs_qcnt_t rtbsoftlimit; /* default realtime blk soft limit */ + struct xfs_quota_limits blk; + struct xfs_quota_limits ino; + struct xfs_quota_limits rtb; }; /* |