struct qmt_pool_info *pool = (struct qmt_pool_info *)arg;
libcfs_debug_vmsg2(msgdata, fmt, args,
struct qmt_pool_info *pool = (struct qmt_pool_info *)arg;
libcfs_debug_vmsg2(msgdata, fmt, args,
- "qmt:%s pool:%d-%s id:"LPU64" enforced:%d hard:"LPU64
- " soft:"LPU64" granted:"LPU64" time:"LPU64" qunit:"
- LPU64" edquot:%d may_rel:"LPU64" revoke:"LPU64"\n",
+ "qmt:%s pool:%d-%s id:%llu enforced:%d hard:%llu"
+ " soft:%llu granted:%llu time:%llu qunit:"
+ "%llu edquot:%d may_rel:%llu revoke:%llu\n",
pool->qpi_qmt->qmt_svname,
pool->qpi_key & 0x0000ffff,
RES_NAME(pool->qpi_key >> 16),
pool->qpi_qmt->qmt_svname,
pool->qpi_key & 0x0000ffff,
RES_NAME(pool->qpi_key >> 16),
PFID(lu_object_fid(&slv_obj->do_lu)), granted);
/* never delete the entry, otherwise, it'll not be transferred
PFID(lu_object_fid(&slv_obj->do_lu)), granted);
/* never delete the entry, otherwise, it'll not be transferred
(struct dt_rec *)rec, flags, ver);
if (rc) {
LQUOTA_ERROR(lqe, "failed to update slave index "DFID" granted:"
(struct dt_rec *)rec, flags, ver);
if (rc) {
LQUOTA_ERROR(lqe, "failed to update slave index "DFID" granted:"
/* we haven't reached the minimal qunit yet so there is
* still hope that the rebalancing process might free
* up some quota space */
/* we haven't reached the minimal qunit yet so there is
* still hope that the rebalancing process might free
* up some quota space */
- /* When exceeding softlimit, block qunit will be shrunk
- * to (4 * least_qunit) finally. */
- if (lqe->lqe_qunit > (pool->qpi_least_qunit << 2))
+ if (lqe->lqe_qunit > pool->qpi_soft_least_qunit)
remaining = qmt_calc_softlimit(lqe, &oversoft);
if (remaining == 0)
remaining = lqe->lqe_granted +
remaining = qmt_calc_softlimit(lqe, &oversoft);
if (remaining == 0)
remaining = lqe->lqe_granted +
bool oversoft;
/* As a compromise of write performance and the grace time
* accuracy, the block qunit size will be shrunk to
bool oversoft;
/* As a compromise of write performance and the grace time
* accuracy, the block qunit size will be shrunk to
if (limit == 0)
GOTO(done, qunit = qunit2);
} else if (lqe->lqe_hardlimit != 0) {
if (limit == 0)
GOTO(done, qunit = qunit2);
} else if (lqe->lqe_hardlimit != 0) {
/* current qunit value still fits, let's see if we can afford to
* increase qunit now ...
* To increase qunit again, we have to be under 25% */
/* current qunit value still fits, let's see if we can afford to
* increase qunit now ...
* To increase qunit again, we have to be under 25% */