CONFIG_JFS_POSIX_ACL=y
CONFIG_JFS_SECURITY=y
CONFIG_XFS_FS=y
-CONFIG_XFS_QUOTA=y
CONFIG_GFS2_FS=m
CONFIG_GFS2_FS_LOCKING_DLM=y
CONFIG_OCFS2_FS=m
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_QUOTA=y
CONFIG_QUOTA_NETLINK_INTERFACE=y
# CONFIG_PRINT_QUOTA_WARNING is not set
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_BTRFS_FS=m
CONFIG_BTRFS_FS_POSIX_ACL=y
CONFIG_QUOTA_NETLINK_INTERFACE=y
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_BTRFS_FS=m
CONFIG_BTRFS_FS_POSIX_ACL=y
CONFIG_QUOTA_NETLINK_INTERFACE=y
CONFIG_EXT2_FS=m
CONFIG_EXT3_FS=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_AUTOFS_FS=m
CONFIG_FUSE_FS=m
CONFIG_ISO9660_FS=m
CONFIG_JFS_FS=m
CONFIG_JFS_POSIX_ACL=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_BTRFS_FS=m
CONFIG_QUOTA=y
CONFIG_QFMT_V2=m
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
CONFIG_XFS_FS=y
-CONFIG_XFS_QUOTA=y
CONFIG_QUOTA=y
# CONFIG_PRINT_QUOTA_WARNING is not set
CONFIG_AUTOFS_FS=y
CONFIG_JFS_POSIX_ACL=y
CONFIG_JFS_SECURITY=y
CONFIG_XFS_FS=m
-CONFIG_XFS_QUOT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CONFIG_XFS_FS=m
-CONFIG_XFS_QUOTA=y
CONFIG_GFS2_FS=m
CONFIG_FS_DAX=y
CONFIG_QUOTA_NETLINK_INTERFACE=y
CONFIG_JFS_SECURITY=y
CONFIG_JFS_STATISTICS=y
CONFIG_XFS_FS=y
-CONFIG_XFS_QUOTA=y
CONFIG_XFS_DEBUG=y
CONFIG_GFS2_FS=m
CONFIG_GFS2_FS_LOCKING_DLM=y
CONFIG_JFS_SECURITY=y
CONFIG_JFS_STATISTICS=y
CONFIG_XFS_FS=y
-CONFIG_XFS_QUOTA=y
CONFIG_GFS2_FS=m
CONFIG_GFS2_FS_LOCKING_DLM=y
CONFIG_OCFS2_FS=m
select FS_IOMAP
select FS_POSIX_ACL
select LIBCRC32C
+ select QUOTACTL
help
XFS is a high performance journaling filesystem which originated
on the SGI IRIX platform. It is completely multi-threaded, can
To continue supporting case-insensitivity (ascii-ci=1), say Y.
To close off an attack surface, say N.
-config XFS_QUOTA
- bool "XFS Quota support"
- depends on XFS_FS
- select QUOTACTL
- help
- If you say Y here, you will be able to set limits for disk usage on
- a per user and/or a per group basis under XFS. XFS considers quota
- information as filesystem metadata and uses journaling to provide a
- higher level guarantee of consistency. The on-disk data format for
- quota is also compatible with the IRIX version of XFS, allowing a
- filesystem to be migrated between Linux and IRIX without any need
- for conversion.
-
- If unsure, say N. More comprehensive documentation can be found in
- README.quota in the xfsprogs package. XFS quota can be used either
- with or without the generic quota support enabled (CONFIG_QUOTA) -
- they are completely independent subsystems.
-
config XFS_DRAIN_INTENTS
bool
select JUMP_LABEL if HAVE_ARCH_JUMP_LABEL
xfs_dahash_test.o \
xfs_dir2_readdir.o \
xfs_discard.o \
+ xfs_dquot.o \
xfs_error.o \
xfs_exchrange.o \
xfs_export.o \
xfs_mount.o \
xfs_mru_cache.o \
xfs_pwork.o \
+ xfs_qm.o \
+ xfs_qm_bhv.o \
+ xfs_qm_syscalls.o \
+ xfs_quotaops.o \
xfs_reflink.o \
xfs_rtalloc.o \
xfs_stats.o \
xfs_exchmaps_item.o \
xfs_extfree_item.o \
xfs_attr_item.o \
+ xfs_dquot_item.o \
xfs_icreate_item.o \
xfs_inode_item.o \
xfs_inode_item_recover.o \
xfs_rmap_item.o \
xfs_log_recover.o \
xfs_trans_ail.o \
- xfs_trans_buf.o
-
-# optional features
-xfs-$(CONFIG_XFS_QUOTA) += xfs_dquot.o \
- xfs_dquot_item.o \
- xfs_trans_dquot.o \
- xfs_qm_syscalls.o \
- xfs_qm_bhv.o \
- xfs_qm.o \
- xfs_quotaops.o
+ xfs_trans_buf.o \
+ xfs_trans_dquot.o
xfs-$(CONFIG_SYSCTL) += xfs_sysctl.o
xfs-$(CONFIG_COMPAT) += xfs_ioctl32.o
dabtree.o \
dir.o \
dirtree.o \
+ dqiterate.o \
fscounters.o \
health.o \
ialloc.o \
listxattr.o \
nlinks.o \
parent.o \
+ quota.o \
+ quotacheck.o \
readdir.o \
refcount.o \
rmap.o \
xfs-$(CONFIG_XFS_ONLINE_SCRUB_STATS) += scrub/stats.o
-xfs-$(CONFIG_XFS_QUOTA) += $(addprefix scrub/, \
- dqiterate.o \
- quota.o \
- quotacheck.o \
- )
-
# online repair
ifeq ($(CONFIG_XFS_ONLINE_REPAIR),y)
xfs-y += $(addprefix scrub/, \
nlinks_repair.o \
orphanage.o \
parent_repair.o \
+ quota_repair.o \
+ quotacheck_repair.o \
rcbag_btree.o \
rcbag.o \
reap.o \
tempfile.o \
)
-xfs-$(CONFIG_XFS_QUOTA) += $(addprefix scrub/, \
- quota_repair.o \
- quotacheck_repair.o \
- )
endif
endif
return 0;
}
-#ifdef CONFIG_XFS_QUOTA
/* Log the actual updates to the quota accounting. */
static inline void
xfs_exchmaps_update_quota(
xfs_trans_mod_dquot_byino(tp, xmi->xmi_ip1, qflag, ip1_delta);
xfs_trans_mod_dquot_byino(tp, xmi->xmi_ip2, qflag, ip2_delta);
}
-#else
-# define xfs_exchmaps_update_quota(tp, xmi, irec1, irec2) ((void)0)
-#endif
/* Decide if we want to skip this mapping from file1. */
static inline bool
trace_xchk_block_error(sc, xfs_buf_daddr(bp), __return_address);
}
-#ifdef CONFIG_XFS_QUOTA
/* Record a corrupt quota counter. */
void
xchk_qcheck_set_corrupt(
sc->sm->sm_flags |= XFS_SCRUB_OFLAG_CORRUPT;
trace_xchk_qcheck_error(sc, dqtype, id, __return_address);
}
-#endif
/* Record a corruption while cross-referencing. */
void
return 0;
}
-#ifdef CONFIG_XFS_QUOTA
/*
* Try to attach dquots to this inode if we think we might want to repair it.
* Callers must not hold any ILOCKs. If the dquots are broken and cannot be
return xrep_ino_dqattach(sc);
}
-#endif
/* Install an inode that we opened by handle for scrubbing. */
int
void xchk_ino_set_corrupt(struct xfs_scrub *sc, xfs_ino_t ino);
void xchk_fblock_set_corrupt(struct xfs_scrub *sc, int whichfork,
xfs_fileoff_t offset);
-#ifdef CONFIG_XFS_QUOTA
void xchk_qcheck_set_corrupt(struct xfs_scrub *sc, unsigned int dqtype,
xfs_dqid_t id);
-#endif
void xchk_block_xref_set_corrupt(struct xfs_scrub *sc,
struct xfs_buf *bp);
int xchk_setup_dirtree(struct xfs_scrub *sc);
int xchk_setup_rtbitmap(struct xfs_scrub *sc);
int xchk_setup_rtsummary(struct xfs_scrub *sc);
-#ifdef CONFIG_XFS_QUOTA
int xchk_ino_dqattach(struct xfs_scrub *sc);
int xchk_setup_quota(struct xfs_scrub *sc);
int xchk_setup_quotacheck(struct xfs_scrub *sc);
-#else
-static inline int
-xchk_ino_dqattach(struct xfs_scrub *sc)
-{
- return 0;
-}
-# define xchk_setup_quota xchk_setup_nothing
-# define xchk_setup_quotacheck xchk_setup_nothing
-#endif
int xchk_setup_fscounters(struct xfs_scrub *sc);
int xchk_setup_nlinks(struct xfs_scrub *sc);
return error;
}
-#ifdef CONFIG_XFS_QUOTA
/* Update some quota flags in the superblock. */
void
xrep_update_qflags(
return error;
}
-#endif /* CONFIG_XFS_QUOTA */
/*
* Ensure that the inode being repaired is ready to handle a certain number of
int xrep_find_ag_btree_roots(struct xfs_scrub *sc, struct xfs_buf *agf_bp,
struct xrep_find_ag_btree *btree_info, struct xfs_buf *agfl_bp);
-#ifdef CONFIG_XFS_QUOTA
void xrep_update_qflags(struct xfs_scrub *sc, unsigned int clear_flags,
unsigned int set_flags);
void xrep_force_quotacheck(struct xfs_scrub *sc, xfs_dqtype_t type);
int xrep_ino_dqattach(struct xfs_scrub *sc);
-#else
-# define xrep_force_quotacheck(sc, type) ((void)0)
-# define xrep_ino_dqattach(sc) (0)
-#endif /* CONFIG_XFS_QUOTA */
int xrep_setup_xfbtree(struct xfs_scrub *sc, const char *descr);
int xrep_dirtree(struct xfs_scrub *sc);
int xrep_rtbitmap(struct xfs_scrub *sc);
int xrep_rtsummary(struct xfs_scrub *sc);
-
-#ifdef CONFIG_XFS_QUOTA
int xrep_quota(struct xfs_scrub *sc);
int xrep_quotacheck(struct xfs_scrub *sc);
-#else
-# define xrep_quota xrep_notsupported
-# define xrep_quotacheck xrep_notsupported
-#endif /* CONFIG_XFS_QUOTA */
int xrep_reinit_pagf(struct xfs_scrub *sc);
int xrep_reinit_pagi(struct xfs_scrub *sc);
int xchk_dirtree(struct xfs_scrub *sc);
int xchk_rtbitmap(struct xfs_scrub *sc);
int xchk_rtsummary(struct xfs_scrub *sc);
-#ifdef CONFIG_XFS_QUOTA
int xchk_quota(struct xfs_scrub *sc);
int xchk_quotacheck(struct xfs_scrub *sc);
-#else
-# define xchk_quota xchk_nothing
-# define xchk_quotacheck xchk_nothing
-#endif
int xchk_fscounters(struct xfs_scrub *sc);
int xchk_nlinks(struct xfs_scrub *sc);
DEFINE_SCRUB_FBLOCK_ERROR_EVENT(xchk_fblock_warning);
DEFINE_SCRUB_FBLOCK_ERROR_EVENT(xchk_fblock_preen);
-#ifdef CONFIG_XFS_QUOTA
DECLARE_EVENT_CLASS(xchk_dqiter_class,
TP_PROTO(struct xchk_dqiter *cursor, uint64_t id),
TP_ARGS(cursor, id),
__entry->id,
__entry->ret_ip)
);
-#endif /* CONFIG_XFS_QUOTA */
TRACE_EVENT(xchk_incomplete,
TP_PROTO(struct xfs_scrub *sc, void *ret_ip),
__entry->blockcount)
);
-#ifdef CONFIG_XFS_QUOTA
DECLARE_EVENT_CLASS(xrep_dquot_class,
TP_PROTO(struct xfs_mount *mp, uint8_t type, uint32_t id),
TP_ARGS(mp, type, id),
DEFINE_XREP_DQUOT_EVENT(xrep_disk_dquot);
DEFINE_XREP_DQUOT_EVENT(xrep_dquot_item_fill_bmap_hole);
DEFINE_XREP_DQUOT_EVENT(xrep_quotacheck_dquot);
-#endif /* CONFIG_XFS_QUOTA */
DEFINE_SCRUB_NLINKS_DIFF_EVENT(xrep_nlinks_update_inode);
DEFINE_SCRUB_NLINKS_DIFF_EVENT(xrep_nlinks_unfixable_inode);
bool xfs_buf_item_dirty_format(struct xfs_buf_log_item *);
void xfs_buf_inode_iodone(struct xfs_buf *);
void xfs_buf_inode_io_fail(struct xfs_buf *bp);
-#ifdef CONFIG_XFS_QUOTA
void xfs_buf_dquot_iodone(struct xfs_buf *);
void xfs_buf_dquot_io_fail(struct xfs_buf *bp);
-#else
-static inline void xfs_buf_dquot_iodone(struct xfs_buf *bp)
-{
-}
-static inline void xfs_buf_dquot_io_fail(struct xfs_buf *bp)
-{
-}
-#endif /* CONFIG_XFS_QUOTA */
void xfs_buf_iodone(struct xfs_buf *);
bool xfs_buf_log_check_iovec(struct xfs_log_iovec *iovec);
case XFS_BLFT_UDQUOT_BUF:
case XFS_BLFT_PDQUOT_BUF:
case XFS_BLFT_GDQUOT_BUF:
-#ifdef CONFIG_XFS_QUOTA
if (magic16 != XFS_DQUOT_MAGIC) {
warnmsg = "Bad DQUOT block magic!";
break;
}
bp->b_ops = &xfs_dquot_buf_ops;
-#else
- xfs_alert(mp,
- "Trying to recover dquots without QUOTA support built in!");
- ASSERT(0);
-#endif
break;
case XFS_BLFT_DINO_BUF:
if (magic16 != XFS_DINODE_MAGIC) {
__XFS_IS_OPSTATE(readonly, READONLY)
__XFS_IS_OPSTATE(inodegc_enabled, INODEGC_ENABLED)
__XFS_IS_OPSTATE(blockgc_enabled, BLOCKGC_ENABLED)
-#ifdef CONFIG_XFS_QUOTA
__XFS_IS_OPSTATE(quotacheck_running, QUOTACHECK_RUNNING)
-#else
-# define xfs_is_quotacheck_running(mp) (false)
-#endif
__XFS_IS_OPSTATE(done_with_log_incompat, UNSET_LOG_INCOMPAT)
__XFS_IS_OPSTATE(using_logged_xattrs, USE_LARP)
xfs_dqid_t q_id;
};
-#ifdef CONFIG_XFS_QUOTA
extern void xfs_trans_dup_dqinfo(struct xfs_trans *, struct xfs_trans *);
extern void xfs_trans_free_dqinfo(struct xfs_trans *);
extern void xfs_trans_mod_dquot_byino(struct xfs_trans *, struct xfs_inode *,
extern void xfs_qm_unmount_quotas(struct xfs_mount *);
bool xfs_inode_near_dquot_enforcement(struct xfs_inode *ip, xfs_dqtype_t type);
-# ifdef CONFIG_XFS_LIVE_HOOKS
+#ifdef CONFIG_XFS_LIVE_HOOKS
void xfs_trans_mod_ino_dquot(struct xfs_trans *tp, struct xfs_inode *ip,
struct xfs_dquot *dqp, unsigned int field, int64_t delta);
void xfs_dqtrx_hook_del(struct xfs_quotainfo *qi, struct xfs_dqtrx_hook *hook);
void xfs_dqtrx_hook_setup(struct xfs_dqtrx_hook *hook, notifier_fn_t mod_fn,
notifier_fn_t apply_fn);
-# else
-# define xfs_trans_mod_ino_dquot(tp, ip, dqp, field, delta) \
- xfs_trans_mod_dquot((tp), (dqp), (field), (delta))
-# endif /* CONFIG_XFS_LIVE_HOOKS */
-
#else
-static inline int
-xfs_qm_vop_dqalloc(struct xfs_inode *ip, kuid_t kuid, kgid_t kgid,
- prid_t prid, uint flags, struct xfs_dquot **udqp,
- struct xfs_dquot **gdqp, struct xfs_dquot **pdqp)
-{
- *udqp = NULL;
- *gdqp = NULL;
- *pdqp = NULL;
- return 0;
-}
-#define xfs_trans_dup_dqinfo(tp, tp2)
-#define xfs_trans_free_dqinfo(tp)
-static inline void xfs_trans_mod_dquot_byino(struct xfs_trans *tp,
- struct xfs_inode *ip, uint field, int64_t delta)
-{
-}
-#define xfs_trans_apply_dquot_deltas(tp)
-#define xfs_trans_unreserve_and_mod_dquots(tp)
-static inline int xfs_trans_reserve_quota_nblks(struct xfs_trans *tp,
- struct xfs_inode *ip, int64_t dblocks, int64_t rblocks,
- bool force)
-{
- return 0;
-}
-static inline int xfs_trans_reserve_quota_bydquots(struct xfs_trans *tp,
- struct xfs_mount *mp, struct xfs_dquot *udqp,
- struct xfs_dquot *gdqp, struct xfs_dquot *pdqp,
- int64_t nblks, long nions, uint flags)
-{
- return 0;
-}
-
-static inline int
-xfs_trans_reserve_quota_icreate(struct xfs_trans *tp, struct xfs_dquot *udqp,
- struct xfs_dquot *gdqp, struct xfs_dquot *pdqp, int64_t dblocks)
-{
- return 0;
-}
-
-#define xfs_qm_vop_create_dqattach(tp, ip, u, g, p)
-#define xfs_qm_vop_rename_dqattach(it) (0)
-#define xfs_qm_vop_chown(tp, ip, old, new) (NULL)
-#define xfs_qm_dqattach(ip) (0)
-#define xfs_qm_dqattach_locked(ip, fl) (0)
-#define xfs_qm_dqdetach(ip)
-#define xfs_qm_dqrele(d) do { (d) = (d); } while(0)
-#define xfs_qm_statvfs(ip, s) do { } while(0)
-#define xfs_qm_newmount(mp, a, b) (0)
-#define xfs_qm_mount_quotas(mp)
-#define xfs_qm_unmount(mp)
-#define xfs_qm_unmount_quotas(mp)
-#define xfs_inode_near_dquot_enforcement(ip, type) (false)
-
-# ifdef CONFIG_XFS_LIVE_HOOKS
-# define xfs_dqtrx_hook_enable() ((void)0)
-# define xfs_dqtrx_hook_disable() ((void)0)
-# endif /* CONFIG_XFS_LIVE_HOOKS */
-
-#endif /* CONFIG_XFS_QUOTA */
+# define xfs_trans_mod_ino_dquot(tp, ip, dqp, field, delta) \
+ xfs_trans_mod_dquot((tp), (dqp), (field), (delta))
+#endif /* CONFIG_XFS_LIVE_HOOKS */
static inline int
xfs_quota_reserve_blkres(struct xfs_inode *ip, int64_t blocks)
#ifdef CONFIG_PROC_FS
/* legacy quota interfaces */
-#ifdef CONFIG_XFS_QUOTA
#define XFSSTAT_START_XQMSTAT xfsstats_offset(xs_qm_dqreclaims)
#define XFSSTAT_END_XQMSTAT xfsstats_offset(xs_qm_dquot)
seq_putc(m, '\n');
return 0;
}
-#endif /* CONFIG_XFS_QUOTA */
int
xfs_init_procfs(void)
"/sys/fs/xfs/stats/stats"))
goto out;
-#ifdef CONFIG_XFS_QUOTA
if (!proc_create_single("fs/xfs/xqmstat", 0, NULL, xqmstat_proc_show))
goto out;
if (!proc_create_single("fs/xfs/xqm", 0, NULL, xqm_proc_show))
goto out;
-#endif
return 0;
out:
return -EINVAL;
}
- if (!IS_ENABLED(CONFIG_XFS_QUOTA) && mp->m_qflags != 0) {
- xfs_warn(mp, "quota support not available in this kernel.");
- return -EINVAL;
- }
-
if ((mp->m_dalign && !mp->m_swidth) ||
(!mp->m_dalign && mp->m_swidth)) {
xfs_warn(mp, "sunit and swidth must be specified together");
sb_min_blocksize(sb, BBSIZE);
sb->s_xattr = xfs_xattr_handlers;
sb->s_export_op = &xfs_export_operations;
-#ifdef CONFIG_XFS_QUOTA
sb->s_qcop = &xfs_quotactl_operations;
sb->s_quota_types = QTYPE_MASK_USR | QTYPE_MASK_GRP | QTYPE_MASK_PRJ;
-#endif
sb->s_op = &xfs_super_operations;
/*
#include <linux/exportfs.h>
-#ifdef CONFIG_XFS_QUOTA
extern int xfs_qm_init(void);
extern void xfs_qm_exit(void);
-# define XFS_QUOTA_STRING "quota, "
-#else
-# define xfs_qm_init() (0)
-# define xfs_qm_exit() do { } while (0)
-# define XFS_QUOTA_STRING
-#endif
+#define XFS_QUOTA_STRING "quota, "
#define XFS_ACL_STRING "ACLs, "