Lines Matching refs:dq
49 static void print_dquot(const char *desc, struct dquot *dq) in print_dquot() argument
54 dq->dq_id, (long long) dq->dq_dqb.dqb_curspace, in print_dquot()
55 (long long) dq->dq_dqb.dqb_bsoftlimit, in print_dquot()
56 (long long) dq->dq_dqb.dqb_bhardlimit, in print_dquot()
57 (long long) dq->dq_dqb.dqb_curinodes, in print_dquot()
58 (long long) dq->dq_dqb.dqb_isoftlimit, in print_dquot()
59 (long long) dq->dq_dqb.dqb_ihardlimit); in print_dquot()
63 struct dquot *dq EXT2FS_ATTR((unused))) in print_dquot()
150 struct dquot *dq; in write_dquots() local
153 dq = dnode_get(n); in write_dquots()
154 if (dq) { in write_dquots()
155 print_dquot("write", dq); in write_dquots()
156 dq->dq_h = qh; in write_dquots()
157 update_grace_times(dq); in write_dquots()
158 qh->qh_ops->commit_dquot(dq); in write_dquots()
365 struct dquot *dq; in get_dq() local
370 dq = dnode_get(n); in get_dq()
372 if (ext2fs_get_mem(sizeof(struct dquot), &dq)) { in get_dq()
376 memset(dq, 0, sizeof(struct dquot)); in get_dq()
377 dict_alloc_insert(dict, UINT_TO_VOIDPTR(key), dq); in get_dq()
378 dq->dq_id = key; in get_dq()
380 return dq; in get_dq()
391 struct dquot *dq; in quota_data_add() local
406 dq = get_dq(dict, get_qid(inode, qtype)); in quota_data_add()
407 if (dq) in quota_data_add()
408 dq->dq_dqb.dqb_curspace += space; in quota_data_add()
420 struct dquot *dq; in quota_data_sub() local
435 dq = get_dq(dict, get_qid(inode, qtype)); in quota_data_sub()
436 if (dq) in quota_data_sub()
437 dq->dq_dqb.dqb_curspace -= space; in quota_data_sub()
448 struct dquot *dq; in quota_data_inodes() local
463 dq = get_dq(dict, get_qid(inode, qtype)); in quota_data_inodes()
464 if (dq) in quota_data_inodes()
465 dq->dq_dqb.dqb_curinodes += adjust; in quota_data_inodes()
535 struct dquot *dq; in scan_dquots_callback() local
537 dq = get_dq(quota_dict, dquot->dq_id); in scan_dquots_callback()
538 if (!dq) in scan_dquots_callback()
540 dq->dq_id = dquot->dq_id; in scan_dquots_callback()
541 dq->dq_flags |= DQF_SEEN; in scan_dquots_callback()
543 print_dquot("mem", dq); in scan_dquots_callback()
548 (dq->dq_dqb.dqb_curspace != dquot->dq_dqb.dqb_curspace || in scan_dquots_callback()
549 dq->dq_dqb.dqb_curinodes != dquot->dq_dqb.dqb_curinodes)) { in scan_dquots_callback()
553 dq->dq_id, (long long) dq->dq_dqb.dqb_curspace, in scan_dquots_callback()
554 (long long) dq->dq_dqb.dqb_curinodes, in scan_dquots_callback()
560 dq->dq_dqb.dqb_ihardlimit = dquot->dq_dqb.dqb_ihardlimit; in scan_dquots_callback()
561 dq->dq_dqb.dqb_isoftlimit = dquot->dq_dqb.dqb_isoftlimit; in scan_dquots_callback()
562 dq->dq_dqb.dqb_bhardlimit = dquot->dq_dqb.dqb_bhardlimit; in scan_dquots_callback()
563 dq->dq_dqb.dqb_bsoftlimit = dquot->dq_dqb.dqb_bsoftlimit; in scan_dquots_callback()
567 dq->dq_dqb.dqb_curspace = dquot->dq_dqb.dqb_curspace; in scan_dquots_callback()
568 dq->dq_dqb.dqb_curinodes = dquot->dq_dqb.dqb_curinodes; in scan_dquots_callback()
659 struct dquot *dq; in quota_compare_and_update() local
686 dq = dnode_get(n); in quota_compare_and_update()
687 if (!dq) in quota_compare_and_update()
689 if ((dq->dq_flags & DQF_SEEN) == 0) { in quota_compare_and_update()
691 "Missing quota entry ID %d\n", dq->dq_id); in quota_compare_and_update()