]> git.sesse.net Git - bcachefs-tools-debian/blobdiff - libbcachefs/quota.h
Update bcachefs sources to e99d29e402 bcachefs: zstd support, compression refactoring
[bcachefs-tools-debian] / libbcachefs / quota.h
index b5536be94ed407620c61c4911c23b79c34a963cb..509b7f0e069d0f33423f72f70fa5c7b05603b0cf 100644 (file)
@@ -20,6 +20,13 @@ static inline struct bch_qid bch_qid(struct bch_inode_unpacked *u)
        };
 }
 
+static inline unsigned enabled_qtypes(struct bch_fs *c)
+{
+       return ((c->opts.usrquota << QTYP_USR)|
+               (c->opts.grpquota << QTYP_GRP)|
+               (c->opts.prjquota << QTYP_PRJ));
+}
+
 #ifdef CONFIG_BCACHEFS_QUOTA
 
 int bch2_quota_acct(struct bch_fs *, struct bch_qid, enum quota_counters,