• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/usr.bin/quota/

Lines Matching refs:qup

95 static void showrawquotas(int type, u_long id, struct quotause *qup);
97 static int getufsquota(struct fstab *fs, struct quotause *qup, long id,
99 static int getnfsquota(struct statfs *fst, struct quotause *qup, long id,
280 struct quotause *qup;
291 for (qup = quplist; qup; qup = qup->next) {
293 if (qup->dqblk.dqb_ihardlimit &&
294 qup->dqblk.dqb_curinodes >= qup->dqblk.dqb_ihardlimit) {
298 else if (qup->dqblk.dqb_isoftlimit &&
299 qup->dqblk.dqb_curinodes >= qup->dqblk.dqb_isoftlimit) {
301 if (qup->dqblk.dqb_itime > now)
307 if (qup->dqblk.dqb_bhardlimit &&
308 qup->dqblk.dqb_curblocks >= qup->dqblk.dqb_bhardlimit) {
312 else if (qup->dqblk.dqb_bsoftlimit &&
313 qup->dqblk.dqb_curblocks >= qup->dqblk.dqb_bsoftlimit) {
315 if (qup->dqblk.dqb_btime > now)
321 showrawquotas(type, id, qup);
325 qup->dqblk.dqb_isoftlimit == 0 &&
326 qup->dqblk.dqb_ihardlimit == 0 &&
327 qup->dqblk.dqb_bsoftlimit == 0 &&
328 qup->dqblk.dqb_bhardlimit == 0)
335 printf("\t%s %s\n", msgi, qup->fsname);
337 printf("\t%s %s\n", msgb, qup->fsname);
341 qup->dqblk.dqb_curblocks == 0 &&
342 qup->dqblk.dqb_curinodes == 0)
346 nam = qup->fsname;
347 if (strlen(qup->fsname) > 15) {
348 printf("%s\n", qup->fsname);
353 prthumanval(7, dbtob(qup->dqblk.dqb_curblocks));
355 prthumanval(7, dbtob(qup->dqblk.dqb_bsoftlimit));
356 prthumanval(7, dbtob(qup->dqblk.dqb_bhardlimit));
359 (uintmax_t)dbtob(qup->dqblk.dqb_curblocks)
362 (uintmax_t)dbtob(qup->dqblk.dqb_bsoftlimit)
364 (uintmax_t)dbtob(qup->dqblk.dqb_bhardlimit)
368 bgrace = timeprt(qup->dqblk.dqb_btime);
370 igrace = timeprt(qup->dqblk.dqb_itime);
373 , (uintmax_t)qup->dqblk.dqb_curinodes
375 , (uintmax_t)qup->dqblk.dqb_isoftlimit
376 , (uintmax_t)qup->dqblk.dqb_ihardlimit
390 showrawquotas(int type, u_long id, struct quotause *qup)
395 type == USRQUOTA ? "user" : "group", id, qup->fsname);
397 (uintmax_t)qup->dqblk.dqb_bhardlimit);
399 (uintmax_t)qup->dqblk.dqb_bsoftlimit);
401 (uintmax_t)qup->dqblk.dqb_curblocks);
403 (uintmax_t)qup->dqblk.dqb_ihardlimit);
405 (uintmax_t)qup->dqblk.dqb_isoftlimit);
407 (uintmax_t)qup->dqblk.dqb_curinodes);
409 (intmax_t)qup->dqblk.dqb_btime);
410 if (qup->dqblk.dqb_btime != 0) {
411 t = qup->dqblk.dqb_btime;
416 printf("i-node grace time: %jd", (intmax_t)qup->dqblk.dqb_itime);
417 if (qup->dqblk.dqb_itime != 0) {
418 t = qup->dqblk.dqb_itime;
489 struct quotause *qup, *quptail = NULL;
496 qup = quphead = (struct quotause *)0;
505 if (qup == NULL) {
506 if ((qup = (struct quotause *)malloc(sizeof *qup))
520 if (getnfsquota(&fst[i], qup, id, quotatype) == 0)
533 if (getufsquota(fs, qup, id, quotatype) == 0)
537 strcpy(qup->fsname, fst[i].f_mntonname);
539 quphead = qup;
541 quptail->next = qup;
542 quptail = qup;
544 qup = NULL;
546 if (qup)
547 free(qup);
556 getufsquota(struct fstab *fs, struct quotause *qup, long id, int quotatype)
562 if (quota_read(qf, &qup->dqblk, id) != 0)
569 getnfsquota(struct statfs *fst, struct quotause *qup, long id, int quotatype)
574 struct dqblk *dqp = &qup->dqblk;