- if (INT_ISZERO(d->d_btimer, ARCH_CONVERT)) {
- if ((INT_GET(d->d_blk_softlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_bcount, ARCH_CONVERT) >=
- INT_GET(d->d_blk_softlimit, ARCH_CONVERT))) ||
- (INT_GET(d->d_blk_hardlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_bcount, ARCH_CONVERT) >=
- INT_GET(d->d_blk_hardlimit, ARCH_CONVERT)))) {
- INT_SET(d->d_btimer, ARCH_CONVERT,
- get_seconds() + XFS_QI_BTIMELIMIT(mp));
- }
- } else {
- if ((INT_ISZERO(d->d_blk_softlimit, ARCH_CONVERT) ||
- (INT_GET(d->d_bcount, ARCH_CONVERT) <
- INT_GET(d->d_blk_softlimit, ARCH_CONVERT))) &&
- (INT_ISZERO(d->d_blk_hardlimit, ARCH_CONVERT) ||
- (INT_GET(d->d_bcount, ARCH_CONVERT) <
- INT_GET(d->d_blk_hardlimit, ARCH_CONVERT)))) {
- INT_ZERO(d->d_btimer, ARCH_CONVERT);
- }
- }
-
- if (INT_ISZERO(d->d_itimer, ARCH_CONVERT)) {
- if ((INT_GET(d->d_ino_softlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_icount, ARCH_CONVERT) >=
- INT_GET(d->d_ino_softlimit, ARCH_CONVERT))) ||
- (INT_GET(d->d_ino_hardlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_icount, ARCH_CONVERT) >=
- INT_GET(d->d_ino_hardlimit, ARCH_CONVERT)))) {
- INT_SET(d->d_itimer, ARCH_CONVERT,
- get_seconds() + XFS_QI_ITIMELIMIT(mp));
- }
- } else {
- if ((INT_ISZERO(d->d_ino_softlimit, ARCH_CONVERT) ||
- (INT_GET(d->d_icount, ARCH_CONVERT) <
- INT_GET(d->d_ino_softlimit, ARCH_CONVERT))) &&
- (INT_ISZERO(d->d_ino_hardlimit, ARCH_CONVERT) ||
- (INT_GET(d->d_icount, ARCH_CONVERT) <
- INT_GET(d->d_ino_hardlimit, ARCH_CONVERT)))) {
- INT_ZERO(d->d_itimer, ARCH_CONVERT);
- }
- }
-
- if (INT_ISZERO(d->d_rtbtimer, ARCH_CONVERT)) {
- if ((INT_GET(d->d_rtb_softlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_rtbcount, ARCH_CONVERT) >=
- INT_GET(d->d_rtb_softlimit, ARCH_CONVERT))) ||
- (INT_GET(d->d_rtb_hardlimit, ARCH_CONVERT) &&
- (INT_GET(d->d_rtbcount, ARCH_CONVERT) >=
- INT_GET(d->d_rtb_hardlimit, ARCH_CONVERT)))) {
- INT_SET(d->d_rtbtimer, ARCH_CONVERT,
- get_seconds() + XFS_QI_RTBTIMELIMIT(mp));