#include <linux/fs.h>
#include <linux/capability.h>
#include <linux/time.h>
#include <linux/compat.h>
#include <linux/mount.h>
#include <linux/file.h>
#include <linux/quotaops.h>
#include <linux/random.h>
#include <linux/uaccess.h>
#include <linux/delay.h>
#include <linux/iversion.h>
#include <linux/fileattr.h>
#include <linux/uuid.h>
#include "ext4_jbd2.h"
#include "ext4.h"
#include <linux/fsmap.h>
#include "fsmap.h"
#include <trace/events/ext4.h>
ext4_update_sb_callback;
static void ext4_sb_setlabel(struct ext4_super_block *es, const void *arg)
{ … }
static void ext4_sb_setuuid(struct ext4_super_block *es, const void *arg)
{ … }
static
int ext4_update_primary_sb(struct super_block *sb, handle_t *handle,
ext4_update_sb_callback func,
const void *arg)
{ … }
static int ext4_update_backup_sb(struct super_block *sb,
handle_t *handle, ext4_group_t grp,
ext4_update_sb_callback func, const void *arg)
{ … }
static
int ext4_update_superblocks_fn(struct super_block *sb,
ext4_update_sb_callback func,
const void *arg)
{ … }
static void memswap(void *a, void *b, size_t len)
{ … }
static void swap_inode_data(struct inode *inode1, struct inode *inode2)
{ … }
void ext4_reset_inode_seed(struct inode *inode)
{ … }
static long swap_inode_boot_loader(struct super_block *sb,
struct mnt_idmap *idmap,
struct inode *inode)
{ … }
static int ext4_ioctl_check_immutable(struct inode *inode, __u32 new_projid,
unsigned int flags)
{ … }
static void ext4_dax_dontcache(struct inode *inode, unsigned int flags)
{ … }
static bool dax_compatible(struct inode *inode, unsigned int oldflags,
unsigned int flags)
{ … }
static int ext4_ioctl_setflags(struct inode *inode,
unsigned int flags)
{ … }
#ifdef CONFIG_QUOTA
static int ext4_ioctl_setproject(struct inode *inode, __u32 projid)
{ … }
#else
static int ext4_ioctl_setproject(struct inode *inode, __u32 projid)
{
if (projid != EXT4_DEF_PROJID)
return -EOPNOTSUPP;
return 0;
}
#endif
int ext4_force_shutdown(struct super_block *sb, u32 flags)
{ … }
static int ext4_ioctl_shutdown(struct super_block *sb, unsigned long arg)
{ … }
struct getfsmap_info { … };
static int ext4_getfsmap_format(struct ext4_fsmap *xfm, void *priv)
{ … }
static int ext4_ioc_getfsmap(struct super_block *sb,
struct fsmap_head __user *arg)
{ … }
static long ext4_ioctl_group_add(struct file *file,
struct ext4_new_group_data *input)
{ … }
int ext4_fileattr_get(struct dentry *dentry, struct fileattr *fa)
{ … }
int ext4_fileattr_set(struct mnt_idmap *idmap,
struct dentry *dentry, struct fileattr *fa)
{ … }
#define FIEMAP_MAX_EXTENTS …
static int ext4_ioctl_get_es_cache(struct file *filp, unsigned long arg)
{ … }
static int ext4_ioctl_checkpoint(struct file *filp, unsigned long arg)
{ … }
static int ext4_ioctl_setlabel(struct file *filp, const char __user *user_label)
{ … }
static int ext4_ioctl_getlabel(struct ext4_sb_info *sbi, char __user *user_label)
{ … }
static int ext4_ioctl_getuuid(struct ext4_sb_info *sbi,
struct fsuuid __user *ufsuuid)
{ … }
static int ext4_ioctl_setuuid(struct file *filp,
const struct fsuuid __user *ufsuuid)
{ … }
static long __ext4_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
{ … }
long ext4_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
{ … }
#ifdef CONFIG_COMPAT
long ext4_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
{ … }
#endif
static void set_overhead(struct ext4_super_block *es, const void *arg)
{ … }
int ext4_update_overhead(struct super_block *sb, bool force)
{ … }