github.com/google/syzkaller@v0.0.0-20251211124644-a066d2bc4b02/sys/linux/filesystem.txt (about)

     1  # Copyright 2018 syzkaller project authors. All rights reserved.
     2  # Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
     3  
     4  include <uapi/linux/mount.h>
     5  include <linux/fs.h>
     6  include <linux/fcntl.h>
     7  
     8  mount(src ptr[in, blockdev_filename], dst ptr[in, filename], type ptr[in, string[filesystem]], flags flags[mount_flags], data ptr[in, string, opt])
     9  umount2(path ptr[in, filename], flags flags[umount_flags])
    10  
    11  mount$bpf(src const[0], dst ptr[in, filename], type ptr[in, string["bpf"]], flags flags[mount_flags], opts ptr[in, fs_options[bpf_options]])
    12  mount$overlay(src const[0], dst ptr[in, filename], type ptr[in, string["overlay"]], flags flags[mount_flags], opts ptr[in, fs_options[overlay_options]])
    13  mount$binder(src const[0], dst ptr[in, filename], type ptr[in, string["binder"]], flags flags[mount_flags], opts ptr[in, fs_options[binder_options]])
    14  mount$tmpfs(src const[0], dst ptr[in, filename], type ptr[in, string["tmpfs"]], flags flags[mount_flags], opts ptr[in, fs_options[tmpfs_options]])
    15  mount$cgroup(src const[0], dst ptr[in, filename], type ptr[in, string["cgroup"]], flags flags[mount_flags], opts ptr[in, fs_options[cgroup_options]])
    16  mount$cgroup2(src const[0], dst ptr[in, filename], type ptr[in, string["cgroup2"]], flags flags[mount_flags], opts ptr[in, fs_options[cgroup2_options]])
    17  mount$afs(src ptr[in, afs_source], dst ptr[in, filename], type ptr[in, string["afs"]], flags flags[mount_flags], opts ptr[in, fs_options[afs_options]])
    18  
    19  # A bind mount ignores the filesystem type argument, but
    20  # pkg/host/syscalls_linux.go:isSupportedFilesystem() requires one in
    21  # /proc/filesystems.  Use a common and valid filesystem string ("pipefs") to
    22  # pass the check.
    23  mount$bind(src ptr[in, filename], dst ptr[in, filename], type ptr[in, string["pipefs"]], flags flags[mount_flags], data const[0])
    24  
    25  # esdfs is ChromeOS-specific:
    26  # https://chromium.googlesource.com/chromiumos/third_party/kernel/+/d2c1fb9fcdb53%5E%21/
    27  mount$esdfs(src ptr[in, filename], dst ptr[in, filename], type ptr[in, string["esdfs"]], flags flags[mount_flags], opts ptr[in, fs_options[esdfs_options]])
    28  
    29  # TODO: pvfs2 requires some device/source, but it looks unused:
    30  # https://elixir.bootlin.com/linux/v6.1-rc6/source/fs/orangefs/super.c#L488
    31  # Instead it sends requests to some pvfs2-req character device,
    32  # and somebody is supposed to answer these requests with ioctls.
    33  # But the deivce is not even created in /dev, somebody is supposed to mknod it.
    34  # And it's major number is unknown (printed to console in debug mode only):
    35  # https://elixir.bootlin.com/linux/v6.1-rc6/source/fs/orangefs/devorangefs-req.c#L803
    36  # It does not look usable.
    37  mount$pvfs2(src ptr[in, string["unused"]], dst ptr[in, filename], type ptr[in, string["pvfs2"]], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]])
    38  
    39  # TODO: nfs source is "hostname:export_path", but we also needs to setup port,
    40  # protocol and other options, and most importantly we need the server to reply to RPCs.
    41  # There is something called nfsd (fs/nfsd) which may help and which we need to test as well.
    42  mount$nfs(src ptr[in, string], dst ptr[in, filename], type ptr[in, string["nfs"]], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]])
    43  mount$nfs4(src ptr[in, string], dst ptr[in, filename], type ptr[in, string["nfs4"]], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]])
    44  
    45  resource fd_fscontext[fd]
    46  
    47  fsopen(type ptr[in, string[filesystem]], flags flags[fsopen_flags]) fd_fscontext
    48  fspick(dfd fd_dir[opt], path ptr[in, filename], flags flags[fspick_flags]) fd_fscontext
    49  fsconfig$FSCONFIG_SET_FLAG(fd fd_fscontext, cmd const[FSCONFIG_SET_FLAG], key ptr[in, string[fsconfig_flag_params]], value const[0], aux const[0])
    50  fsconfig$FSCONFIG_SET_STRING(fd fd_fscontext, cmd const[FSCONFIG_SET_STRING], key ptr[in, string], value ptr[in, string], aux const[0])
    51  fsconfig$FSCONFIG_SET_BINARY(fd fd_fscontext, cmd const[FSCONFIG_SET_BINARY], key ptr[in, string], value ptr[in, array[int8]], aux bytesize[value])
    52  fsconfig$FSCONFIG_SET_PATH(fd fd_fscontext, cmd const[FSCONFIG_SET_PATH], key ptr[in, string], value ptr[in, filename], aux fd_dir[opt])
    53  fsconfig$FSCONFIG_SET_PATH_EMPTY(fd fd_fscontext, cmd const[FSCONFIG_SET_PATH_EMPTY], key ptr[in, string], value ptr[in, filename], aux fd_dir[opt])
    54  fsconfig$FSCONFIG_SET_FD(fd fd_fscontext, cmd const[FSCONFIG_SET_FD], key ptr[in, string], value const[0], aux fd)
    55  fsconfig$FSCONFIG_CMD_CREATE(fd fd_fscontext, cmd const[FSCONFIG_CMD_CREATE], key const[0], value const[0], aux const[0])
    56  fsconfig$FSCONFIG_CMD_RECONFIGURE(fd fd_fscontext, cmd const[FSCONFIG_CMD_RECONFIGURE], key const[0], value const[0], aux const[0])
    57  fsmount(fs_fd fd_fscontext, flags flags[fsmount_flags], attr_flags flags[fsmount_attr_flags]) fd
    58  move_mount(from_dfd fd_dir[opt], from_pathname ptr[in, filename], to_dfd fd_dir[opt], to_pathname ptr[in, filename], flags flags[move_mount_flags])
    59  open_tree(dfd fd_dir[opt], filename ptr[in, filename], flags flags[open_tree_flags]) fd
    60  mount_setattr(dfd fd_dir[opt], filename ptr[in, filename], flags flags[mount_setattr_flags], args ptr[in, mount_attr], size bytesize[args])
    61  
    62  open_tree_flags = AT_EMPTY_PATH, AT_NO_AUTOMOUNT, AT_RECURSIVE, AT_SYMLINK_NOFOLLOW, OPEN_TREE_CLONE, OPEN_TREE_CLOEXEC
    63  
    64  mount_setattr_flags = AT_EMPTY_PATH, AT_NO_AUTOMOUNT, AT_RECURSIVE, AT_SYMLINK_NOFOLLOW
    65  
    66  mount_attr {
    67  	attr_set	flags[mount_attr_flags, int64]
    68  	attr_clr	flags[mount_attr_flags, int64]
    69  	propagation	flags[mount_attr_propagation_flags, int64]
    70  	userns_fd	align64[fd_userns]
    71  }
    72  
    73  mount_attr_flags = MOUNT_ATTR_IDMAP, fsmount_attr_flags
    74  mount_attr_propagation_flags = MS_UNBINDABLE, MS_PRIVATE, MS_SLAVE, MS_SHARED
    75  fsmount_flags = FSMOUNT_CLOEXEC
    76  fsopen_flags = FSOPEN_CLOEXEC
    77  fspick_flags = FSPICK_CLOEXEC
    78  fsmount_attr_flags = MOUNT_ATTR_RDONLY, MOUNT_ATTR_NOSUID, MOUNT_ATTR_NODEV, MOUNT_ATTR_NOEXEC, MOUNT_ATTR__ATIME, MOUNT_ATTR_NODIRATIME
    79  move_mount_flags = MOVE_MOUNT_F_SYMLINKS, MOVE_MOUNT_F_AUTOMOUNTS, MOVE_MOUNT_F_EMPTY_PATH, MOVE_MOUNT_T_SYMLINKS, MOVE_MOUNT_T_AUTOMOUNTS, MOVE_MOUNT_T_EMPTY_PATH, MOVE_MOUNT_SET_GROUP, MOVE_MOUNT_BENEATH
    80  fsconfig_flag_params = "dirsync", "lazytime", "mand", "posixacl", "ro", "sync", "async", "nolazytime", "nomand", "rw", "silent"
    81  
    82  filesystem = "sysfs", "rootfs", "ramfs", "tmpfs", "devtmpfs", "debugfs", "securityfs", "sockfs", "pipefs", "anon_inodefs", "devpts", "hugetlbfs", "vfat", "ecryptfs", "fuseblk", "fuse", "rpc_pipefs", "nfs", "nfs4", "nfsd", "binfmt_misc", "autofs", "xfs", "jfs", "msdos", "ntfs", "ntfs3", "minix", "hfs", "hfsplus", "qnx4", "ufs", "btrfs", "configfs", "ncpfs", "qnx6", "exofs", "befs", "vxfs", "gfs2", "gfs2meta", "fusectl", "bfs", "nsfs", "efs", "cifs", "efivarfs", "affs", "tracefs", "bdev", "ocfs2", "ocfs2_dlmfs", "hpfs", "proc", "afs", "reiserfs", "jffs2", "romfs", "aio", "sysv", "v7", "udf", "ceph", "pstore", "adfs", "9p", "hostfs", "squashfs", "cramfs", "iso9660", "coda", "nilfs2", "logfs", "overlay", "f2fs", "omfs", "ubifs", "openpromfs", "bpf", "cgroup", "cgroup2", "cpuset", "mqueue", "aufs", "selinuxfs", "dax", "erofs", "virtiofs", "exfat", "binder", "zonefs", "pvfs2", "incremental-fs", "esdfs", "smb3", "gadgetfs", ext4_types
    83  
    84  blockdev_filename [
    85  	filename	filename
    86  	nbd		nbd_filename
    87  	loop		loop_filename
    88  	nullb		string["/dev/nullb0"]
    89  	rnullb		string["/dev/rnullb0"]
    90  	md0		string["/dev/md0"]
    91  	sg0		string["/dev/sg0"]
    92  	sr0		string["/dev/sr0"]
    93  ] [varlen]
    94  
    95  nbd_filename {
    96  	prefix	stringnoz["/dev/nbd"]
    97  # NEED: this does not support formatting numbers larger than 9.
    98  	id	proc['0', 1, int8]
    99  	z	const[0, int8]
   100  } [packed]
   101  
   102  loop_filename {
   103  	prefix	stringnoz["/dev/loop"]
   104  # NEED: this does not support formatting numbers larger than 9.
   105  	id	proc['0', 1, int8]
   106  	z	const[0, int8]
   107  } [packed]
   108  
   109  syz_read_part_table(size len[img], img ptr[in, compressed_image]) (timeout[200], no_generate, no_minimize)
   110  
   111  define SYZ_MOUNT_IMAGE_TIMEOUT	4000
   112  
   113  syz_mount_image$vfat(fs ptr[in, string["vfat"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[vfat_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.vfat -n"])
   114  syz_mount_image$msdos(fs ptr[in, string["msdos"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[msdos_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.msdos -n"])
   115  syz_mount_image$bfs(fs ptr[in, string["bfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   116  syz_mount_image$xfs(fs ptr[in, string["xfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[xfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["xfs_repair -n"])
   117  syz_mount_image$minix(fs ptr[in, string["minix"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.minix"])
   118  syz_mount_image$reiserfs(fs ptr[in, string["reiserfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[reiserfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.reiserfs -n"])
   119  syz_mount_image$hfs(fs ptr[in, string["hfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[hfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   120  syz_mount_image$hfsplus(fs ptr[in, string["hfsplus"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[hfsplus_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   121  syz_mount_image$iso9660(fs ptr[in, string["iso9660"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[iso9660_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   122  syz_mount_image$gfs2(fs ptr[in, string["gfs2"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[gfs2_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.gfs2 -n"])
   123  syz_mount_image$jfs(fs ptr[in, string["jfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[jfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.jfs -n"])
   124  syz_mount_image$btrfs(fs ptr[in, string["btrfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[btrfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["btrfsck --readonly"])
   125  syz_mount_image$ntfs(fs ptr[in, string["ntfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ntfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   126  syz_mount_image$ntfs3(fs ptr[in, string["ntfs3"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ntfs3_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   127  syz_mount_image$ext4(fs ptr[in, string[ext4_types]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ext4_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.ext4 -n"])
   128  syz_mount_image$f2fs(fs ptr[in, string["f2fs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[f2fs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.f2fs"])
   129  syz_mount_image$ocfs2(fs ptr[in, string["ocfs2"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ocfs2_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.ocfs2 -n"])
   130  syz_mount_image$erofs(fs ptr[in, string["erofs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[erofs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.erofs"])
   131  syz_mount_image$exfat(fs ptr[in, string["exfat"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[exfat_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.exfat -n"])
   132  syz_mount_image$cramfs(fs ptr[in, string["cramfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize, fsck["fsck.cramfs"])
   133  syz_mount_image$romfs(fs ptr[in, string["romfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   134  syz_mount_image$efs(fs ptr[in, string["efs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   135  syz_mount_image$jffs2(fs ptr[in, string["jffs2"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[jffs2_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   136  syz_mount_image$nilfs2(fs ptr[in, string["nilfs2"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[nilfs2_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   137  syz_mount_image$squashfs(fs ptr[in, string["squashfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[squashfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   138  syz_mount_image$udf(fs ptr[in, string["udf"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[udf_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   139  syz_mount_image$bcachefs(fs ptr[in, string["bcachefs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[bcachefs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   140  
   141  # TODO: zonefs needs a zoned block device:
   142  # https://elixir.bootlin.com/linux/v6.1-rc6/source/fs/zonefs/super.c#L1768
   143  # So currnetly the mount always fails.
   144  # These docs say such devices can be emulated with nullb, but need special setup:
   145  # https://zonedstorage.io/docs/getting-started/zbd-emulation
   146  # https://btrfs.wiki.kernel.org/index.php/Zoned
   147  syz_mount_image$zonefs(fs ptr[in, string["zonefs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[zonefs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   148  
   149  # TODO: ubifs needs a special ubi device:
   150  # https://elixir.bootlin.com/linux/v6.1-rc6/source/fs/ubifs/super.c#L2063
   151  # So currnetly the mount always fails.
   152  syz_mount_image$ubifs(fs ptr[in, string["ubifs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ubifs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   153  
   154  # TODO: add mount options for the following file systems.
   155  syz_mount_image$adfs(fs ptr[in, string["adfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[adfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   156  syz_mount_image$affs(fs ptr[in, string["affs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[affs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   157  syz_mount_image$befs(fs ptr[in, string["befs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   158  syz_mount_image$vxfs(fs ptr[in, string["vxfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[vxfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   159  syz_mount_image$omfs(fs ptr[in, string["omfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[omfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   160  syz_mount_image$hpfs(fs ptr[in, string["hpfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[hpfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   161  syz_mount_image$qnx4(fs ptr[in, string["qnx4"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   162  syz_mount_image$qnx6(fs ptr[in, string["qnx6"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[qnx6_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   163  syz_mount_image$sysv(fs ptr[in, string["sysv"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   164  syz_mount_image$ufs(fs ptr[in, string["ufs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[ufs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   165  syz_mount_image$gfs2meta(fs ptr[in, string["gfs2meta"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   166  syz_mount_image$v7(fs ptr[in, string["v7"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[stringnoz]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   167  
   168  # Note: tmpfs does not need an image, but we use this in tests.
   169  syz_mount_image$tmpfs(fs ptr[in, string["tmpfs"]], dir ptr[in, filename], flags flags[mount_flags], opts ptr[in, fs_options[tmpfs_options]], chdir bool8, size len[img], img ptr[in, compressed_image]) fd_dir (timeout[SYZ_MOUNT_IMAGE_TIMEOUT], no_generate, no_minimize)
   170  
   171  type fs_options[ELEMS] {
   172  	elems	array[fs_opt_elem[ELEMS]]
   173  	common	array[fs_opt_elem[fs_options_common]]
   174  	null	const[0, int8]
   175  } [packed]
   176  
   177  type fs_opt_elem[ELEMS] {
   178  	elem	ELEMS
   179  	comma	const[',', int8]
   180  } [packed]
   181  
   182  type fs_opt[NAME, TYPE] {
   183  	name	stringnoz[NAME]
   184  	eq	const['=', int8]
   185  	val	TYPE
   186  } [packed]
   187  
   188  type fs_opt_nodelim[NAME, TYPE] {
   189  	name	stringnoz[NAME]
   190  	val	TYPE
   191  } [packed]
   192  
   193  type fs_opt_str[NAME] fs_opt[NAME, stringnoz]
   194  type fs_opt_dec[NAME, VAL] fs_opt[NAME, fmt[dec, VAL]]
   195  type fs_opt_hex[NAME, VAL] fs_opt[NAME, fmt[hex, VAL]]
   196  type fs_opt_oct[NAME, VAL] fs_opt[NAME, fmt[oct, VAL]]
   197  type fs_opt_dec_suffix[NAME] fs_opt[NAME, array[flags[fs_opt_digits_suffix, int8]]]
   198  type fs_opt_filename[NAME] fs_opt[NAME, stringnoz[filename]]
   199  type fs_opt_codepage[NAME] fs_opt[NAME, stringnoz[codepages_names]]
   200  type fs_opt_cp_num[NAME] fs_opt[NAME, stringnoz[codepage_nums]]
   201  
   202  fs_opt_digits_suffix = '-', 'x', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'k', 'm', 'g', 't', 'p', 'e', '%'
   203  
   204  fs_options_common [
   205  	flag			stringnoz[fsconfig_flag_params]
   206  
   207  # SELinux options:
   208  	context			fs_opt["context", stringnoz[selinux_user_context]]
   209  	fscontext		fs_opt["fscontext", stringnoz[selinux_user_context]]
   210  	rootcontext		fs_opt["rootcontext", stringnoz[selinux_user_context]]
   211  	defcontext		fs_opt["defcontext", stringnoz[selinux_user_context]]
   212  	seclabel		stringnoz["seclabel"]
   213  
   214  # Smack options:
   215  	smackfsdef		fs_opt_str["smackfsdef"]
   216  	smackfsfloor		fs_opt_str["smackfsfloor"]
   217  	smackfshat		fs_opt_str["smackfshat"]
   218  	smackfsroot		fs_opt_str["smackfsroot"]
   219  	smackfstransmute	fs_opt_str["smackfstransmute"]
   220  
   221  # IMA options:
   222  	measure			stringnoz["measure"]
   223  	dont_measure		stringnoz["dont_measure"]
   224  	appraise		stringnoz["appraise"]
   225  	dont_appraise		stringnoz["dont_appraise"]
   226  	audit			stringnoz["audit"]
   227  	hash			stringnoz["hash"]
   228  	dont_hash		stringnoz["dont_hash"]
   229  	permit_directio		stringnoz["permit_directio"]
   230  	obj_user		fs_opt_str["obj_user"]
   231  	obj_role		fs_opt_str["obj_role"]
   232  	obj_type		fs_opt_str["obj_type"]
   233  	subj_user		fs_opt_str["subj_user"]
   234  	subj_role		fs_opt_str["subj_role"]
   235  	subj_type		fs_opt_str["subj_type"]
   236  	func			fs_opt["func", stringnoz[ima_funcs]]
   237  	mask			fs_opt["mask", stringnoz[ima_masks]]
   238  	fsmagic			fs_opt_hex["fsmagic", intptr]
   239  	fsname			fs_opt_str["fsname"]
   240  	fsuuid			fs_opt["fsuuid", uuid_str]
   241  	uid_eq			fs_opt_dec["uid", uid]
   242  	euid_eq			fs_opt_dec["euid", uid]
   243  	fowner_eq		fs_opt_dec["fowner", uid]
   244  	uid_gt			fs_opt_nodelim["uid>", fmt[dec, uid]]
   245  	euid_gt			fs_opt_nodelim["euid>", fmt[dec, uid]]
   246  	fowner_gt		fs_opt_nodelim["fowner>", fmt[dec, uid]]
   247  	uid_lt			fs_opt_nodelim["uid<", fmt[dec, uid]]
   248  	euid_lt			fs_opt_nodelim["euid<", fmt[dec, uid]]
   249  	fowner_lt		fs_opt_nodelim["fowner<", fmt[dec, uid]]
   250  	appraise_type		stringnoz["appraise_type=imasig"]
   251  	pcr			fs_opt_dec["pcr", int64[0:64]]
   252  ] [varlen]
   253  
   254  uuid_str {
   255  	p0	array[flags[hex_chars, int8], 8]
   256  	d0	const['-', int8]
   257  	p1	array[flags[hex_chars, int8], 4]
   258  	d1	const['-', int8]
   259  	p2	array[flags[hex_chars, int8], 4]
   260  	d2	const['-', int8]
   261  	p3	array[flags[hex_chars, int8], 4]
   262  	d3	const['-', int8]
   263  	p4	array[flags[hex_chars, int8], 8]
   264  }
   265  
   266  hex_chars = '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f'
   267  
   268  ima_funcs = "FILE_CHECK", "PATH_CHECK", "MODULE_CHECK", "FIRMWARE_CHECK", "FILE_MMAP", "MMAP_CHECK", "BPRM_CHECK", "CREDS_CHECK", "KEXEC_KERNEL_CHECK", "KEXEC_INITRAMFS_CHECK", "POLICY_CHECK"
   269  ima_masks = "MAY_EXEC", "MAY_WRITE", "MAY_READ", "MAY_APPEND", "^MAY_EXEC", "^MAY_WRITE", "^MAY_READ", "^MAY_APPEND"
   270  
   271  msdos_options [
   272  	fat	fat_options
   273  	nodots	stringnoz["nodots"]
   274  	dots	stringnoz["dots"]
   275  ] [varlen]
   276  
   277  vfat_options [
   278  	fat		fat_options
   279  	iocharset	fs_opt_codepage["iocharset"]
   280  	rodir		stringnoz["rodir"]
   281  	utf8no		stringnoz["utf8=0"]
   282  	utf8		stringnoz["utf8=1"]
   283  	uni_xlateno	stringnoz["uni_xlate=0"]
   284  	uni_xlate	stringnoz["uni_xlate=1"]
   285  	numtail		stringnoz["nonumtail=0"]
   286  	nonumtail	stringnoz["nnonumtail=1"]
   287  	shortname_lower	stringnoz["shortname=lower"]
   288  	shortname_win95	stringnoz["shortname=win95"]
   289  	shortname_winnt	stringnoz["shortname=winnt"]
   290  	shortname_mixed	stringnoz["shortname=mixed"]
   291  ] [varlen]
   292  
   293  fat_options [
   294  	check_relaxed	stringnoz["check=relaxed"]
   295  	check_strict	stringnoz["check=strict"]
   296  	check_normal	stringnoz["check=normal"]
   297  	usefree		stringnoz["usefree"]
   298  	nocase		stringnoz["nocase"]
   299  	quiet		stringnoz["quiet"]
   300  	showexec	stringnoz["showexec"]
   301  	debug		stringnoz["debug"]
   302  	sys_immutable	stringnoz["sys_immutable"]
   303  	flush		stringnoz["flush"]
   304  	tz_utc		stringnoz["tz=UTC"]
   305  	errors_continue	stringnoz["errors=continue"]
   306  	errors_remount	stringnoz["errors=remount-ro"]
   307  	discard		stringnoz["discard"]
   308  	nfs		stringnoz["nfs"]
   309  	nfs_nostale_ro	stringnoz["nfs=nostale_ro"]
   310  	nfs_stale_rw	stringnoz["nfs=stale_rw"]
   311  	dos1xfloppy	stringnoz["dos1xfloppy"]
   312  	uid		fs_opt_hex["uid", uid]
   313  	gid		fs_opt_hex["gid", gid]
   314  	umask		fs_opt_oct["umask", int32]
   315  	dmask		fs_opt_oct["dmask", int32]
   316  	fmask		fs_opt_oct["fmask", int32]
   317  	allow_utime	fs_opt_oct["allow_utime", int32]
   318  	time_offset	fs_opt_hex["time_offset", int32[-1440:1440]]
   319  	codepage	fs_opt_cp_num["codepage"]
   320  ] [varlen]
   321  
   322  xfs_options [
   323  	wsync		stringnoz["wsync"]
   324  	noalign		stringnoz["noalign"]
   325  	swalloc		stringnoz["swalloc"]
   326  	nouuid		stringnoz["nouuid"]
   327  	mtpt		stringnoz["mtpt"]
   328  	grpid		stringnoz["grpid"]
   329  	nogrpid		stringnoz["nogrpid"]
   330  	bsdgroups	stringnoz["bsdgroups"]
   331  	sysvgroups	stringnoz["sysvgroups"]
   332  	norecovery	stringnoz["norecovery"]
   333  	inode64		stringnoz["inode64"]
   334  	inode32		stringnoz["inode32"]
   335  	ikeep		stringnoz["ikeep"]
   336  	noikeep		stringnoz["noikeep"]
   337  	largeio		stringnoz["largeio"]
   338  	nolargeio	stringnoz["nolargeio"]
   339  	attr2		stringnoz["attr2"]
   340  	noattr2		stringnoz["noattr2"]
   341  	filestreams	stringnoz["filestreams"]
   342  	quota		stringnoz["quota"]
   343  	noquota		stringnoz["noquota"]
   344  	lazytime	stringnoz["lazytime"]
   345  	nolazytime	stringnoz["nolazytime"]
   346  	usrquota	stringnoz["usrquota"]
   347  	grpquota	stringnoz["grpquota"]
   348  	prjquota	stringnoz["prjquota"]
   349  	uquota		stringnoz["uquota"]
   350  	gquota		stringnoz["gquota"]
   351  	pquota		stringnoz["pquota"]
   352  	uqnoenforce	stringnoz["uqnoenforce"]
   353  	gqnoenforce	stringnoz["gqnoenforce"]
   354  	pqnoenforce	stringnoz["pqnoenforce"]
   355  	qnoenforce	stringnoz["qnoenforce"]
   356  	discard		stringnoz["discard"]
   357  	nodiscard	stringnoz["nodiscard"]
   358  	dax		stringnoz["dax"]
   359  	dax_inode	stringnoz["dax=inode"]
   360  	dax_always	stringnoz["dax=always"]
   361  	dax_never	stringnoz["dax=never"]
   362  	barrier		stringnoz["barrier"]
   363  	nobarrier	stringnoz["nobarrier"]
   364  	logbufs		fs_opt_dec["logbufs", int32[-1:8]]
   365  	biosize		fs_opt_dec["biosize", int32]
   366  	sunit		fs_opt_hex["sunit", int32]
   367  	swidth		fs_opt_hex["swidth", int32]
   368  	logbsize	fs_opt_dec_suffix["logbsize"]
   369  	allocsize	fs_opt_dec_suffix["allocsize"]
   370  	logdev		fs_opt_filename["logdev"]
   371  	rtdev		fs_opt_filename["rtdev"]
   372  ] [varlen]
   373  
   374  reiserfs_options [
   375  	tails_on		stringnoz["tails=on"]
   376  	tails_off		stringnoz["tails=off"]
   377  	tails_small		stringnoz["tails=small"]
   378  	notail			stringnoz["notail"]
   379  	conv			stringnoz["conv"]
   380  	noattrs			stringnoz["noattrs"]
   381  	expose_privroot		stringnoz["expose_privroot"]
   382  	user_xattr		stringnoz["user_xattr"]
   383  	nouser_xattr		stringnoz["nouser_xattr"]
   384  	acl			stringnoz["acl"]
   385  	noacl			stringnoz["noacl"]
   386  	replayonly		stringnoz["replayonly"]
   387  	nolargeio		stringnoz["nolargeio"]
   388  	usrquota		stringnoz["usrquota"]
   389  	grpquota		stringnoz["grpquota"]
   390  	noquota			stringnoz["noquota"]
   391  	usrjquota		stringnoz["usrjquota"]
   392  	usrjquota_file		stringnoz["usrjquota=syz"]
   393  	grpjquota		stringnoz["grpjquota"]
   394  	commit			fs_opt_hex["commit", int32]
   395  	resize			fs_opt_hex["resize", int32]
   396  	resize_auto		stringnoz["resize=auto"]
   397  	jdev			fs_opt_filename["jdev"]
   398  	jqfmt_vfsold		stringnoz["jqfmt=vfsold"]
   399  	jqfmt_vfsv0		stringnoz["jqfmt=vfsv0"]
   400  	hash_tea		stringnoz["hash=tea"]
   401  	hash_rupasov		stringnoz["hash=rupasov"]
   402  	hash_r5			stringnoz["hash=r5"]
   403  	balloc_noborder		stringnoz["block-allocator=noborder"]
   404  	balloc_border		stringnoz["block-allocator=border"]
   405  	balloc_no_unhash_reloc	stringnoz["block-allocator=no_unhashed_relocation"]
   406  	balloc_hashed_reloc	stringnoz["block-allocator=hashed_relocation"]
   407  	balloc_test4		stringnoz["block-allocator=test4"]
   408  	balloc_notest4		stringnoz["block-allocator=notest4"]
   409  	barrier_none		stringnoz["barrier=none"]
   410  	barrier_flush		stringnoz["barrier=flush"]
   411  	data_ordered		stringnoz["data=ordered"]
   412  	data_journal		stringnoz["data=journal"]
   413  	data_writeback		stringnoz["data=writeback"]
   414  	errors_continue		stringnoz["errors=continue"]
   415  	errors_ro_remount	stringnoz["errors=ro-remount"]
   416  ] [varlen]
   417  
   418  hfs_options [
   419  	quiet		stringnoz["quiet"]
   420  	umask		fs_opt_oct["umask", int32]
   421  	file_umask	fs_opt_oct["file_umask", int32]
   422  	dir_umask	fs_opt_oct["dir_umask", int32]
   423  	uid		fs_opt_hex["uid", uid]
   424  	gid		fs_opt_hex["gid", gid]
   425  	part		fs_opt_hex["part", int32]
   426  	session		fs_opt_hex["session", int32]
   427  	type		fs_opt["type", array[int8, 4]]
   428  	creator		fs_opt["creator", array[int8, 4]]
   429  	codepage	fs_opt_codepage["codepage"]
   430  	iocharset	fs_opt_codepage["iocharset"]
   431  ] [varlen]
   432  
   433  hfsplus_options [
   434  	decompose	stringnoz["decompose"]
   435  	nodecompose	stringnoz["nodecompose"]
   436  	barrier		stringnoz["barrier"]
   437  	nobarrier	stringnoz["nobarrier"]
   438  	force		stringnoz["force"]
   439  	umask		fs_opt_oct["umask", int32]
   440  	type		fs_opt["type", array[int8, 4]]
   441  	creator		fs_opt["creator", array[int8, 4]]
   442  	uid		fs_opt_hex["uid", uid]
   443  	gid		fs_opt_hex["gid", gid]
   444  	part		fs_opt_hex["part", int32]
   445  	session		fs_opt_hex["session", int32]
   446  	nls		fs_opt_codepage["nls"]
   447  ] [varlen]
   448  
   449  iso9660_options [
   450  	norock		stringnoz["norock"]
   451  	nojoliet	stringnoz["nojoliet"]
   452  	unhide		stringnoz["unhide"]
   453  	hide		stringnoz["hide"]
   454  	showassoc	stringnoz["showassoc"]
   455  	cruft		stringnoz["cruft"]
   456  	utf8		stringnoz["utf8"]
   457  	map_acorn	stringnoz["map=acorn"]
   458  	map_normal	stringnoz["map=normal"]
   459  	map_off		stringnoz["map=off"]
   460  	check_relaxed	stringnoz["check=relaxed"]
   461  	check_strict	stringnoz["check=strict"]
   462  	overriderock	stringnoz["overriderockperm"]
   463  	nocompress	stringnoz["nocompress"]
   464  	session		fs_opt_hex["session", int32[0:98]]
   465  	sbsector	fs_opt_hex["sbsector", int32]
   466  	uid		fs_opt_hex["uid", uid]
   467  	gid		fs_opt_hex["gid", gid]
   468  	mode		fs_opt_hex["mode", int32]
   469  	dmode		fs_opt_hex["dmode", int32]
   470  	block		fs_opt_hex["block", flags[iso9660_blocks]]
   471  	iocharset	fs_opt_codepage["iocharset"]
   472  ] [varlen]
   473  
   474  iso9660_blocks = 512, 1024, 2048
   475  
   476  # Note that the "debug" option has been omitted since it's equivalent to "errors=panic".
   477  gfs2_options [
   478  	spectator		stringnoz["spectator"]
   479  	norecovery		stringnoz["norecovery"]
   480  	ignore_local_fs		stringnoz["ignore_local_fs"]
   481  	localflocks		stringnoz["localflocks"]
   482  	localcaching		stringnoz["localcaching"]
   483  	nodebug			stringnoz["nodebug"]
   484  	upgrade			stringnoz["upgrade"]
   485  	acl			stringnoz["acl"]
   486  	noacl			stringnoz["noacl"]
   487  	quota_off		stringnoz["quota=off"]
   488  	quota_account		stringnoz["quota=account"]
   489  	quota_on		stringnoz["quota=on"]
   490  	quota_quiet		stringnoz["quota=quiet"]
   491  	quota			stringnoz["quota"]
   492  	noquota			stringnoz["noquota"]
   493  	suiddir			stringnoz["suiddir"]
   494  	nosuiddir		stringnoz["nosuiddir"]
   495  	data_writeback		stringnoz["data=writeback"]
   496  	data_ordered		stringnoz["data=ordered"]
   497  	meta			stringnoz["meta"]
   498  	discard			stringnoz["discard"]
   499  	nodiscard		stringnoz["nodiscard"]
   500  	errors_withdraw		stringnoz["errors=withdraw"]
   501  	barrier			stringnoz["barrier"]
   502  	nobarrier		stringnoz["nobarrier"]
   503  	rgrplvb			stringnoz["rgrplvb"]
   504  	norgrplvb		stringnoz["norgrplvb"]
   505  	loccookie		stringnoz["loccookie"]
   506  	noloccookie		stringnoz["noloccookie"]
   507  	commit			fs_opt_hex["commit", int32]
   508  	statfs_quantum		fs_opt_hex["statfs_quantum", int32]
   509  	statfs_percent		fs_opt_hex["statfs_percent", int32]
   510  	quota_quantum		fs_opt_hex["quota_quantum", int32]
   511  	lockproto_dlm		stringnoz["lockproto=dlm"]
   512  	lockproto_nolock	stringnoz["lockproto=lock_nolock"]
   513  	locktable		fs_opt_str["locktable"]
   514  	hostdata		fs_opt_str["hostdata"]
   515  ] [varlen]
   516  
   517  jfs_options [
   518  	integrity	stringnoz["integrity"]
   519  	nointegrity	stringnoz["nointegrity"]
   520  	resize		stringnoz["resize"]
   521  	noquota		stringnoz["noquota"]
   522  	quota		stringnoz["quota"]
   523  	usrquota	stringnoz["usrquota"]
   524  	grpquota	stringnoz["grpquota"]
   525  	discard		stringnoz["discard"]
   526  	nodiscard	stringnoz["nodiscard"]
   527  	iocharset	fs_opt_codepage["iocharset"]
   528  	errors_continue	stringnoz["errors=continue"]
   529  	errors_remount	stringnoz["errors=remount-ro"]
   530  	resize_size	fs_opt_hex["resize", int32]
   531  	uid		fs_opt_hex["uid", uid]
   532  	gid		fs_opt_hex["gid", gid]
   533  	umask		fs_opt_hex["umask", int32]
   534  	discard_size	fs_opt_hex["discard", int32]
   535  ] [varlen]
   536  
   537  btrfs_options [
   538  	degraded		stringnoz["degraded"]
   539  	nodatasum		stringnoz["nodatasum"]
   540  	datasum			stringnoz["datasum"]
   541  	nodatacow		stringnoz["nodatacow"]
   542  	datacow			stringnoz["datacow"]
   543  	nobarrier		stringnoz["nobarrier"]
   544  	barrier			stringnoz["barrier"]
   545  	compress		stringnoz["compress"]
   546  	compress_force		stringnoz["compress-force"]
   547  	ssd			stringnoz["ssd"]
   548  	ssd_spread		stringnoz["ssd_spread"]
   549  	nossd_spread		stringnoz["nossd_spread"]
   550  	nossd			stringnoz["nossd"]
   551  	acl			stringnoz["acl"]
   552  	noacl			stringnoz["noacl"]
   553  	notreelog		stringnoz["notreelog"]
   554  	treelog			stringnoz["treelog"]
   555  	flushoncommit		stringnoz["flushoncommit"]
   556  	noflushoncommit		stringnoz["noflushoncommit"]
   557  	discard			stringnoz["discard"]
   558  	nodiscard		stringnoz["nodiscard"]
   559  	discard_sync		stringnoz["discard=sync"]
   560  	discard_async		stringnoz["discard=async"]
   561  	fatal_errors_bug	stringnoz["fatal_errors=bug"]
   562  	space_cache		stringnoz["space_cache"]
   563  	clear_cache		stringnoz["clear_cache"]
   564  	user_subvol_rm		stringnoz["user_subvol_rm_allowed"]
   565  	enospc_debug		stringnoz["enospc_debug"]
   566  	noenospc_debug		stringnoz["noenospc_debug"]
   567  	autodefrag		stringnoz["autodefrag"]
   568  	noautodefrag		stringnoz["noautodefrag"]
   569  	inode_cache		stringnoz["inode_cache"]
   570  	noinode_cache		stringnoz["noinode_cache"]
   571  	nospace_cache		stringnoz["nospace_cache"]
   572  	usebackuproot		stringnoz["usebackuproot"]
   573  	skip_balance		stringnoz["skip_balance"]
   574  	check_int		stringnoz["check_int"]
   575  	check_int_data		stringnoz["check_int_data"]
   576  	rescan_uuid_tree	stringnoz["rescan_uuid_tree"]
   577  	fragment_data		stringnoz["fragment=data"]
   578  	fragment_metadata	stringnoz["fragment=metadata"]
   579  	fragment_all		stringnoz["fragment=all"]
   580  	ref_verify		stringnoz["ref_verify"]
   581  	metadata_ratio		fs_opt_hex["metadata_ratio", int32]
   582  	check_int_print_mask	fs_opt_hex["check_int_print_mask", int32]
   583  	commit			fs_opt_hex["commit", int32]
   584  	thread_pool		fs_opt_hex["thread_pool", int32]
   585  	device			fs_opt_filename["device"]
   586  	subvolid		fs_opt_hex["subvolid", int64]
   587  	subvol			fs_opt_str["subvol"]
   588  	max_inline		fs_opt_dec_suffix["max_inline"]
   589  	compress_algo		fs_opt["compress", stringnoz[btrfs_compress_algos]]
   590  	compress_force_algo	fs_opt["compress-force", stringnoz[btrfs_compress_algos]]
   591  	space_cache_v1		stringnoz["space_cache=v1"]
   592  	space_cache_v2		stringnoz["space_cache=v2"]
   593  	rescue			fs_opt["rescue", stringnoz[btrfs_rescue_opts]]
   594  ] [varlen]
   595  
   596  btrfs_compress_algos = "zlib", "lzo", "zstd", "no"
   597  btrfs_rescue_opts = "usebackuproot", "nologreplay", "ignorebadroots", "ibadroots", "ignoredatacsums", "ignoremetacsums", "ignoresuperflags", "idatacsums", "imetacsums", "isuperflags", "all"
   598  
   599  ntfs_options [
   600  	uid			fs_opt_hex["uid", uid]
   601  	gid			fs_opt_hex["gid", gid]
   602  	umask			fs_opt_oct["umask", int32]
   603  	fmask			fs_opt_oct["fmask", int32]
   604  	dmask			fs_opt_oct["dmask", int32]
   605  	mft_zone_multiplier	fs_opt_hex["mft_zone_multiplier", int32[-1:4]]
   606  	show_sys_files_no	stringnoz["show_sys_files=no"]
   607  	show_sys_files_yes	stringnoz["show_sys_files=yes"]
   608  	case_sensitive_no	stringnoz["case_sensitive=no"]
   609  	case_sensitive_yes	stringnoz["case_sensitive=yes"]
   610  	disable_sparse_no	stringnoz["disable_sparse=no"]
   611  	disable_sparse_yes	stringnoz["disable_sparse=yes"]
   612  	errors_remount		stringnoz["errors=remount-ro"]
   613  	errors_continue		stringnoz["errors=continue"]
   614  	errors_recover		stringnoz["errors=recover"]
   615  	nls			fs_opt_codepage["nls"]
   616  	utf8			stringnoz["utf8"]
   617  ] [varlen]
   618  
   619  ntfs3_options [
   620  	uid			fs_opt_hex["uid", uid]
   621  	gid			fs_opt_hex["gid", gid]
   622  	umask			fs_opt_oct["umask", int32]
   623  	fmask			fs_opt_oct["fmask", int32]
   624  	dmask			fs_opt_oct["dmask", int32]
   625  	noacsrules		stringnoz["noacsrules"]
   626  	hidden			stringnoz["hidden"]
   627  	nohidden		stringnoz["nohidden"]
   628  	sys_immutable		stringnoz["sys_immutable"]
   629  	nosys_immutable		stringnoz["nosys_immutable"]
   630  	discard			stringnoz["discard"]
   631  	nodiscard		stringnoz["discard"]
   632  	force			stringnoz["force"]
   633  	noforce			stringnoz["noforce"]
   634  	sparse			stringnoz["sparse"]
   635  	nosparse		stringnoz["nosparse"]
   636  	hide_dot_files		stringnoz["hide_dot_files"]
   637  	nohide_dot_files	stringnoz["nohide_dot_files"]
   638  	windows_names		stringnoz["windows_names"]
   639  	nowindows_names		stringnoz["windows_names"]
   640  	showmeta		stringnoz["showmeta"]
   641  	noshowmeta		stringnoz["noshowmeta"]
   642  	prealloc		stringnoz["prealloc"]
   643  	noprealloc		stringnoz["noprealloc"]
   644  	acl			stringnoz["acl"]
   645  	noacl			stringnoz["noacl"]
   646  	iocharset		fs_opt_codepage["iocharset"]
   647  	case			stringnoz["case"]
   648  	nocase			stringnoz["nocase"]
   649  ] [varlen]
   650  
   651  ext4_options [
   652  	bsddf				stringnoz["bsddf"]
   653  	minixdf				stringnoz["minixdf"]
   654  	grpid				stringnoz["grpid"]
   655  	bsdgroups			stringnoz["bsdgroups"]
   656  	nogrpid				stringnoz["nogrpid"]
   657  	sysvgroups			stringnoz["sysvgroups"]
   658  	errors_continue			stringnoz["errors=continue"]
   659  	errors_remount			stringnoz["errors=remount-ro"]
   660  	nouid32				stringnoz["nouid32"]
   661  	debug				stringnoz["debug"]
   662  	oldalloc			stringnoz["oldalloc"]
   663  	orlov				stringnoz["orlov"]
   664  	user_xattr			stringnoz["user_xattr"]
   665  	nouser_xattr			stringnoz["nouser_xattr"]
   666  	acl				stringnoz["acl"]
   667  	noacl				stringnoz["noacl"]
   668  	norecovery			stringnoz["norecovery"]
   669  	noload				stringnoz["noload"]
   670  	nobh				stringnoz["nobh"]
   671  	bh				stringnoz["bh"]
   672  	journal_checksum		stringnoz["journal_checksum"]
   673  	nojournal_checksum		stringnoz["nojournal_checksum"]
   674  	journal_async_commit		stringnoz["journal_async_commit"]
   675  	abort				stringnoz["abort"]
   676  	data_journal			stringnoz["data=journal"]
   677  	data_ordered			stringnoz["data=ordered"]
   678  	data_writeback			stringnoz["data=writeback"]
   679  	data_err_abort			stringnoz["data_err=abort"]
   680  	data_err_ignore			stringnoz["data_err=ignore"]
   681  	usrjquota			stringnoz["usrjquota="]
   682  	grpjquota			stringnoz["grpjquota="]
   683  	jqfmt_vfsold			stringnoz["jqfmt=vfsold"]
   684  	jqfmt_vfsv0			stringnoz["jqfmt=vfsv0"]
   685  	jqfmt_vfsv1			stringnoz["jqfmt=vfsv1"]
   686  	grpquota			stringnoz["grpquota"]
   687  	noquota				stringnoz["noquota"]
   688  	quota				stringnoz["quota"]
   689  	usrquota			stringnoz["usrquota"]
   690  	prjquota			stringnoz["prjquota"]
   691  	barrier				stringnoz["barrier"]
   692  	nobarrier			stringnoz["nobarrier"]
   693  	i_version			stringnoz["i_version"]
   694  	dax				stringnoz["dax"]
   695  	dax_always			stringnoz["dax=always"]
   696  	dax_inode			stringnoz["dax=inode"]
   697  	dax_never			stringnoz["dax=never"]
   698  	delalloc			stringnoz["delalloc"]
   699  	lazytime			stringnoz["lazytime"]
   700  	nolazytime			stringnoz["nolazytime"]
   701  	nodelalloc			stringnoz["nodelalloc"]
   702  	mblk_io_submit			stringnoz["mblk_io_submit"]
   703  	nomblk_io_submit		stringnoz["nomblk_io_submit"]
   704  	block_validity			stringnoz["block_validity"]
   705  	noblock_validity		stringnoz["noblock_validity"]
   706  	auto_da_alloc			stringnoz["auto_da_alloc"]
   707  	noauto_da_alloc			stringnoz["noauto_da_alloc"]
   708  	dioread_nolock			stringnoz["dioread_nolock"]
   709  	nodioread_nolock		stringnoz["nodioread_nolock"]
   710  	dioread_lock			stringnoz["dioread_lock"]
   711  	discard				stringnoz["discard"]
   712  	nodiscard			stringnoz["nodiscard"]
   713  	init_itable			stringnoz["init_itable"]
   714  	noinit_itable			stringnoz["noinit_itable"]
   715  	test_dummy_encryption		stringnoz["test_dummy_encryption"]
   716  	test_dummy_encryption_v1	stringnoz["test_dummy_encryption=v1"]
   717  	nombcache			stringnoz["nombcache"]
   718  	inlinecrypt			stringnoz["inlinecrypt"]
   719  	mb_optimize_scan		fs_opt_hex["mb_optimize_scan", int32[0:1]]
   720  	resgid				fs_opt_hex["resgid", gid]
   721  	resuid				fs_opt_hex["resuid", uid]
   722  	sb				fs_opt_hex["sb", int32]
   723  	commit				fs_opt_hex["commit", int32]
   724  	min_batch_time			fs_opt_hex["min_batch_time", int32]
   725  	max_batch_time			fs_opt_hex["max_batch_time", int32]
   726  	journal_dev			fs_opt_hex["journal_dev", int32]
   727  	barrier_val			fs_opt_hex["barrier", int32]
   728  	stripe				fs_opt_hex["stripe", int32]
   729  	debug_want_extra_isize		fs_opt_hex["debug_want_extra_isize", int32]
   730  	inode_readahead_blks		fs_opt_hex["inode_readahead_blks", flags[ext4_inode_readahead_blks]]
   731  	journal_ioprio			fs_opt_hex["journal_ioprio", int32[0:7]]
   732  	auto_da_alloc_val		fs_opt_hex["auto_da_alloc", int32]
   733  	init_itable_val			fs_opt_hex["init_itable", int32]
   734  	max_dir_size_kb			fs_opt_hex["max_dir_size_kb", int32]
   735  	journal_path			fs_opt_filename["journal_path"]
   736  	grpjquota_path			fs_opt_filename["grpjquota"]
   737  	usrjquota_path			fs_opt_filename["usrjquota"]
   738  ] [varlen]
   739  
   740  ext4_types = "ext4", "ext3", "ext2"
   741  ext4_inode_readahead_blks = 0, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000, 0x40000, 0x80000, 0x100000, 0x200000, 0x400000, 0x800000, 0x1000000, 0x2000000, 0x4000000, 0x8000000
   742  
   743  f2fs_options [
   744  	background_gc_sync		stringnoz["background_gc=sync"]
   745  	background_gc_off		stringnoz["background_gc=off"]
   746  	background_gc_on		stringnoz["background_gc=on"]
   747  	disable_roll_forward		stringnoz["disable_roll_forward"]
   748  	norecovery			stringnoz["norecovery"]
   749  	discard				stringnoz["discard"]
   750  	nodiscard			stringnoz["nodiscard"]
   751  	noheap				stringnoz["no_heap"]
   752  	heap				stringnoz["heap"]
   753  	user_xattr			stringnoz["user_xattr"]
   754  	nouser_xattr			stringnoz["nouser_xattr"]
   755  	acl				stringnoz["acl"]
   756  	noacl				stringnoz["noacl"]
   757  	six_active_logs			stringnoz["active_logs=6"]
   758  	four_active_logs		stringnoz["active_logs=4"]
   759  	two_active_logs			stringnoz["active_logs=2"]
   760  	disable_ext_identify		stringnoz["disable_ext_identify"]
   761  	inline_xattr			stringnoz["inline_xattr"]
   762  	noinline_xattr			stringnoz["noinline_xattr"]
   763  	inline_xattr_size		fs_opt_hex["inline_xattr_size", int32]
   764  	inline_data			stringnoz["inline_data"]
   765  	noinline_data			stringnoz["noinline_data"]
   766  	inline_dentry			stringnoz["inline_dentry"]
   767  	noinline_dentry			stringnoz["noinline_dentry"]
   768  	flush_merge			stringnoz["flush_merge"]
   769  	noflush_merge			stringnoz["noflush_merge"]
   770  	barrier				stringnoz["barrier"]
   771  	nobarrier			stringnoz["nobarrier"]
   772  	fastboot			stringnoz["fastboot"]
   773  	extent_cache			stringnoz["extent_cache"]
   774  	noextent_cache			stringnoz["noextent_cache"]
   775  	data_flush			stringnoz["data_flush"]
   776  	reserve_root			fs_opt_dec["reserver_root", int32]
   777  	adaptive_mode			stringnoz["mode=adaptive"]
   778  	lfs_mode			stringnoz["mode=lfs"]
   779  	segment_mode			stringnoz["mode=fragment:segment"]
   780  	block_mode			stringnoz["mode=fragment:block"]
   781  	io_bits				fs_opt_dec["io_bits", int32[0:256]]
   782  	fault_injection			fs_opt_dec["fault_injection", int32]
   783  	fault_type			fs_opt_dec["fault_type", int32]
   784  	resgid				fs_opt_hex["resgid", gid]
   785  	resuid				fs_opt_hex["resuid", uid]
   786  	lazytime			stringnoz["lazytime"]
   787  	nolazytime			stringnoz["nolazytime"]
   788  	quota				stringnoz["quota"]
   789  	noquota				stringnoz["noquota"]
   790  	usrquota			fs_opt_str["usrquota"]
   791  	grpquota			fs_opt_str["grpquota"]
   792  	prjquota			fs_opt_str["prjquota"]
   793  	usrjquota			fs_opt_str["usrjquota"]
   794  	grpjquota			fs_opt_str["grpjquota"]
   795  	prjjquota			fs_opt_str["prjjquota"]
   796  	jqfmt_vfsold			stringnoz["jqfmt=vfsold"]
   797  	jqfmt_vfsv0			stringnoz["jqfmt=vfsv0"]
   798  	jqfmt_vfsv1			stringnoz["jqfmt=vfsv1"]
   799  	whint_mode_user			stringnoz["whint_mode=user-based"]
   800  	whint_mode_off			stringnoz["whint_mode=off"]
   801  	whint_mode_fs			stringnoz["whint_mode=fs-based"]
   802  	alloc_mode_def			stringnoz["alloc_mode=default"]
   803  	alloc_mode_reuse		stringnoz["alloc_mode=reuse"]
   804  	fsync_mode_posix		stringnoz["fsync_mode=posix"]
   805  	fsync_mode_strict		stringnoz["fsync_mode=strict"]
   806  	test_dummy_encryption		stringnoz["test_dummy_encryption"]
   807  	test_dummy_encryption_v1	stringnoz["test_dummy_encryption=v1"]
   808  	errors_continue			stringnoz["errors=continue"]
   809  	errors_remount			stringnoz["errors=remount-ro"]
   810  	inlinecrypt			stringnoz["inlinecrypt"]
   811  	checkpoint_diasble		stringnoz["checkpoint=disable"]
   812  	checkpoint_enable		stringnoz["checkpoint=enable"]
   813  	checkpoint_merge		stringnoz["checkpoint=merge"]
   814  	nocheckpoint_merge		stringnoz["nocheckpoint_merge"]
   815  	compress_chksum			stringnoz["compress_chksum"]
   816  	compress_cache			stringnoz["compress_cache"]
   817  	atgc				stringnoz["atgc"]
   818  	gc_merge			stringnoz["gc_merge"]
   819  	nogc_merge			stringnoz["nogc_merge"]
   820  	discard_unit_block		stringnoz["discard_unit=block"]
   821  	discard_unit_segment		stringnoz["discard_unit=segment"]
   822  	discard_unit_section		stringnoz["discard_unit=section"]
   823  	memory_normal			stringnoz["memory=normal"]
   824  	memory_low			stringnoz["memory=low"]
   825  	age_extent_cache		stringnoz["age_extent_cache"]
   826  ] [varlen]
   827  
   828  ocfs2_options [
   829  	barrier			fs_opt_dec["barrier", int32]
   830  	err_ro			stringnoz["errors=remount-ro"]
   831  	intr			stringnoz["intr"]
   832  	nointr			stringnoz["nointr"]
   833  	heartbeat_none		stringnoz["heartbeat=none"]
   834  	heartbeat_local		stringnoz["heartbeat=local"]
   835  	heartbeat_global	stringnoz["heartbeat=global"]
   836  	data_ordered		stringnoz["data=ordered"]
   837  	data_writeback		stringnoz["data=writeback"]
   838  	atime_quantum		fs_opt_dec["atime_quantum", int32]
   839  	preferred_slot		fs_opt_dec["preferred_slot", int32]
   840  	commit			fs_opt_dec["commit", int32]
   841  	localalloc		fs_opt_dec["localalloc", int32]
   842  	localflocks		stringnoz["localflocks"]
   843  	cluster_stack		stringnoz["cluster_stack=o2cb"]
   844  	user_xattr		stringnoz["user_xattr"]
   845  	nouser_xattr		stringnoz["nouser_xattr"]
   846  	inode64			stringnoz["inode64"]
   847  	acl			stringnoz["acl"]
   848  	noacl			stringnoz["noacl"]
   849  	usrquota		stringnoz["usrquota"]
   850  	grpquota		stringnoz["grpquota"]
   851  	coherency_buffered	stringnoz["coherency=buffered"]
   852  	coherency_full		stringnoz["coherency=full"]
   853  	resv_level		fs_opt_dec["resv_level", int32[0:9]]
   854  	dir_resv_level		fs_opt_dec["dir_resv_level", int32[0:9]]
   855  	journal_async_commit	stringnoz["journal_async_commit"]
   856  	err_cont		stringnoz["errors=continue"]
   857  ] [varlen]
   858  
   859  bpf_options [
   860  	uid	fs_opt_hex["uid", uid]
   861  	gid	fs_opt_hex["gid", gid]
   862  	mode	fs_opt_oct["mode", int32]
   863  ] [varlen]
   864  
   865  overlay_options [
   866  	lowerdir		fs_opt_filename["lowerdir"]
   867  	upperdir		fs_opt_filename["upperdir"]
   868  	workdir			fs_opt_filename["workdir"]
   869  	redirect_dir_on		stringnoz["redirect_dir=on"]
   870  	redirect_dir_off	stringnoz["redirect_dir=off"]
   871  	redirect_dir_follow	stringnoz["redirect_dir=follow"]
   872  	redirect_dir_nofollow	stringnoz["redirect_dir=nofollow"]
   873  	default_permissions	stringnoz["default_permissions"]
   874  	index_on		stringnoz["index=on"]
   875  	index_off		stringnoz["index=off"]
   876  	uuid_on			stringnoz["uuid=on"]
   877  	uuid_off		stringnoz["uuid=off"]
   878  	uuid_auto		stringnoz["uuid=auto"]
   879  	uuid_null		stringnoz["uuid=null"]
   880  	nfs_export_on		stringnoz["nfs_export=on"]
   881  	nfs_export_off		stringnoz["nfs_export=off"]
   882  	userxattr		stringnoz["userxattr"]
   883  	xino_on			stringnoz["xino=on"]
   884  	xino_off		stringnoz["xino=off"]
   885  	xino_auto		stringnoz["xino=auto"]
   886  	metacopy_on		stringnoz["metacopy=on"]
   887  	metacopy_off		stringnoz["metacopy=off"]
   888  	verity_on		stringnoz["verity=on"]
   889  	verity_off		stringnoz["verity=off"]
   890  	verity_require		stringnoz["verity=require"]
   891  	volatile		stringnoz["volatile"]
   892  ] [varlen]
   893  
   894  binder_options [
   895  	max	fs_opt_dec["max", int32[0:4]]
   896  	stats	stringnoz["stats=global"]
   897  ] [varlen]
   898  
   899  erofs_options [
   900  	user_xattr			stringnoz["user_xattr"]
   901  	nouser_xattr			stringnoz["nouser_xattr"]
   902  	acl				stringnoz["acl"]
   903  	noacl				stringnoz["noacl"]
   904  	fault_injection			fs_opt_hex["fault_injection", int32]
   905  	cache_strategy_disabled		stringnoz["cache_strategy=disabled"]
   906  	cache_strategy_readahead	stringnoz["cache_strategy=readahead"]
   907  	cache_strategy_readaround	stringnoz["cache_strategy=readaround"]
   908  	dax				stringnoz["dax"]
   909  	dax_always			stringnoz["dax=always"]
   910  	dax_never			stringnoz["dax=never"]
   911  ] [varlen]
   912  
   913  exfat_options [
   914  	uid		fs_opt_hex["uid", uid]
   915  	gid		fs_opt_hex["gid", gid]
   916  	umask		fs_opt_oct["umask", int32]
   917  	dmask		fs_opt_oct["dmask", int32]
   918  	fmask		fs_opt_oct["fmask", int32]
   919  	allow_utime	fs_opt_oct["allow_utime", int32]
   920  	codepage	fs_opt_codepage["codepage"]
   921  	iocharset	fs_opt_codepage["iocharset"]
   922  	namecase	stringnoz["namecase=1"]
   923  	errors_remount	stringnoz["errors=remount-ro"]
   924  	errors_continue	stringnoz["errors=continue"]
   925  	utf8		stringnoz["utf8"]
   926  	discard		stringnoz["discard"]
   927  	keep_last_dots	stringnoz["keep_last_dots"]
   928  	sys_tz		stringnoz["sys_tz"]
   929  	time_offset	fs_opt_hex["time_offset", int32]
   930  	zero_size_dir	stringnoz["zero_size_dir"]
   931  ] [varlen]
   932  
   933  # TODO: afs should be configured via /proc/fs/afs/{cells,servers} (see fs/afs/proc.c).
   934  # Without that mounting of afs will fail.
   935  afs_source [
   936  	none	string["none"]
   937  	cell	afs_cell_source
   938  ] [varlen]
   939  
   940  afs_cell_source {
   941  	prefix	flags[afs_cell_prefix, int8]
   942  	cell	stringnoz[afs_cells]
   943  	volname	stringnoz[afs_volnames]
   944  	suffix	stringnoz[afs_suffixes]
   945  	z	const[0, int8]
   946  } [packed]
   947  
   948  afs_cell_prefix = '%', '#'
   949  afs_cells = "", "syz0:", "syz1:"
   950  afs_volnames = "syz0", "syz1"
   951  afs_suffixes = "", ".readonly", ".backup"
   952  
   953  afs_options [
   954  	autocell	stringnoz["autocell"]
   955  	dyn		stringnoz["dyn"]
   956  	flock_local	stringnoz["flock=local"]
   957  	flock_openafs	stringnoz["flock=openafs"]
   958  	flock_strict	stringnoz["flock=strict"]
   959  	flock_write	stringnoz["flock=write"]
   960  ] [varlen]
   961  
   962  tmpfs_options [
   963  	uid				fs_opt_hex["uid", uid]
   964  	gid				fs_opt_hex["gid", gid]
   965  	mode				fs_opt_oct["mode", int32]
   966  	nr_blocks			fs_opt_dec_suffix["nr_blocks"]
   967  	nr_inodes			fs_opt_dec_suffix["nr_inodes"]
   968  	size				fs_opt_dec_suffix["size"]
   969  	huge_never			stringnoz["huge=never"]
   970  	huge_always			stringnoz["huge=always"]
   971  	huge_within_size		stringnoz["huge=within_size"]
   972  	huge_advise			stringnoz["huge=advise"]
   973  	mpol				fs_opt["mpol", tmpfs_mpol]
   974  	inode32				stringnoz["inode32"]
   975  	inode64				stringnoz["indo64"]
   976  	noswap				stringnoz["noswap"]
   977  	quota				stringnoz["quota"]
   978  	usrquota			stringnoz["usrquota"]
   979  	grpquota			stringnoz["grpquota"]
   980  	usrquota_block_hardlimit	fs_opt_dec_suffix["usrquota_block_hardlimit"]
   981  	usrquota_inode_hardlimit	fs_opt_dec_suffix["usrquota_inode_hardlimit"]
   982  	grpquota_block_hardlimit	fs_opt_dec_suffix["grpquota_block_hardlimit"]
   983  	grpquota_inode_hardlimit	fs_opt_dec_suffix["grpquota_inode_hardlimit"]
   984  ] [varlen]
   985  
   986  tmpfs_mpol {
   987  	policy	stringnoz[tmpfs_mpol_policy]
   988  	flags	stringnoz[tmpfs_mpol_flags]
   989  	nodes	optional[tmpfs_mpol_nodes]
   990  } [packed]
   991  
   992  tmpfs_mpol_nodes {
   993  	colon	const[':', int8]
   994  	nodes	array[flags[tmpfs_mpol_node_chars, int8]]
   995  }
   996  
   997  tmpfs_mpol_policy = "default", "prefer", "bind", "interleave", "local"
   998  tmpfs_mpol_flags = "", "=static", "=relative"
   999  tmpfs_mpol_node_chars = '-', ':', '/', ',', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'
  1000  
  1001  zonefs_options [
  1002  	errors_remount_ro	stringnoz["errors=remount-ro"]
  1003  	errors_zone_ro		stringnoz["errors=zone-ro"]
  1004  	errors_zone_offline	stringnoz["errors=zone-offline"]
  1005  	errors_repair		stringnoz["errors=repair"]
  1006  	explicit_open		stringnoz["explicit-open"]
  1007  ] [varlen]
  1008  
  1009  jffs2_options [
  1010  	compr_none	stringnoz["compr=none"]
  1011  	compr_lzo	stringnoz["compr=lzo"]
  1012  	compr_zlib	stringnoz["compr=zlib"]
  1013  	rp_size		fs_opt_dec["rp_size", int32]
  1014  ] [varlen]
  1015  
  1016  nilfs2_options [
  1017  	barrier			stringnoz["barrier"]
  1018  	nobarrier		stringnoz["nobarrier"]
  1019  	norecovery		stringnoz["norecovery"]
  1020  	discard			stringnoz["discard"]
  1021  	nodiscard		stringnoz["nodiscard"]
  1022  	snapshot		fs_opt_hex["cp", int32[0:3]]
  1023  	order_relaxed		stringnoz["order=relaxed"]
  1024  	order_strict		stringnoz["order=strict"]
  1025  	errors_continue		stringnoz["errors=continue"]
  1026  	errors_remount_ro	stringnoz["errors=remount-ro"]
  1027  ] [varlen]
  1028  
  1029  squashfs_options [
  1030  	errors		stringnoz["errors=continue"]
  1031  	threads_str	fs_opt["threads", stringnoz[squashfs_thread]]
  1032  	threads_num	fs_opt_dec["threads", int32]
  1033  ] [varlen]
  1034  
  1035  squashfs_thread = "single", "multi", "percpu"
  1036  
  1037  ubifs_options [
  1038  	fast_unmount	stringnoz["fast_unmount"]
  1039  	norm_unmount	stringnoz["norm_unmount"]
  1040  	bulk_read	stringnoz["bulk_read"]
  1041  	no_bulk_read	stringnoz["no_bulk_read"]
  1042  	chk_data_crc	stringnoz["chk_data_crc"]
  1043  	no_chk_data_crc	stringnoz["no_chk_data_crc"]
  1044  	compr_none	stringnoz["compr=none"]
  1045  	compr_lzo	stringnoz["compr=lzo"]
  1046  	compr_zlib	stringnoz["compr=zlib"]
  1047  	compr_zstd	stringnoz["compr=zstd"]
  1048  	auth_key	fs_opt_str["auth_key"]
  1049  	auth_hash_name	fs_opt["auth_hash_name", stringnoz[ubifs_auth_hash_name]]
  1050  ] [varlen]
  1051  
  1052  adfs_options [
  1053  	uid		fs_opt_hex["uid", uid]
  1054  	gid		fs_opt_hex["gid", gid]
  1055  	ownmask		fs_opt_oct["ownmask", int32]
  1056  	othmask		fs_opt_oct["othmask", int32]
  1057  	ftsuffix	fs_opt_dec["ftsuffix", int32]
  1058  ] [varlen]
  1059  
  1060  affs_options [
  1061  	bs		fs_opt_hex["bs", flags[affs_bs]]
  1062  	mode		fs_opt_oct["mode", int32]
  1063  	mufs		stringnoz["mufs"]
  1064  	notruncate	stringnoz["nofilenametruncate"]
  1065  	protect		stringnoz["protect"]
  1066  	reserved	fs_opt_dec["reserved", int32]
  1067  	root		fs_opt_dec["root", int32]
  1068  	setuid		fs_opt_hex["setuid", uid]
  1069  	setgid		fs_opt_hex["setgid", gid]
  1070  	verbose		stringnoz["verbose"]
  1071  ] [varlen]
  1072  
  1073  affs_bs = 512, 1024, 2048, 4096
  1074  
  1075  vxfs_options [
  1076  	uid		fs_opt_hex["uid", uid]
  1077  	gid		fs_opt_hex["gid", gid]
  1078  	iocharset	fs_opt_codepage["iocharset"]
  1079  	debug		stringnoz["debug"]
  1080  ] [varlen]
  1081  
  1082  omfs_options [
  1083  	uid	fs_opt_hex["uid", uid]
  1084  	gid	fs_opt_hex["gid", gid]
  1085  	umask	fs_opt_oct["umask", int32]
  1086  	dmask	fs_opt_oct["dmask", int32]
  1087  	fmask	fs_opt_oct["fmask", int32]
  1088  ] [varlen]
  1089  
  1090  hpfs_options [
  1091  	help		stringnoz["help"]
  1092  	uid		fs_opt_hex["uid", uid]
  1093  	gid		fs_opt_hex["gid", gid]
  1094  	umask		fs_opt_oct["umask", int32]
  1095  	case_lower	stringnoz["case=lower"]
  1096  	case_asis	stringnoz["case=asis"]
  1097  	check_none	stringnoz["check=none"]
  1098  	check_normal	stringnoz["check=normal"]
  1099  	check_strict	stringnoz["check=strict"]
  1100  	err_cont	stringnoz["errors=continue"]
  1101  	err_ro		stringnoz["errors=remount-ro"]
  1102  	eas_no		stringnoz["eas=no"]
  1103  	eas_ro		stringnoz["ear=ro"]
  1104  	eas_rw		stringnoz["eas=rw"]
  1105  	chkdsk_no	stringnoz["chkdsk=no"]
  1106  	chkdsk_errors	stringnoz["chkdsk=errors"]
  1107  	chkdsk_always	stringnoz["chkdsk=always"]
  1108  	timeshift	fs_opt_dec["timeshift", int32]
  1109  ] [varlen]
  1110  
  1111  qnx6_options [
  1112  	mmi_fs	stringnoz["mmi_fs"]
  1113  ] [varlen]
  1114  
  1115  # We could use more hash names, but the problem is that alg_hash_name is 0-terminated.
  1116  ubifs_auth_hash_name = "crc32", "ghash", "md5", "sha1"
  1117  
  1118  udf_options [
  1119  	novrs		stringnoz["novrs"]
  1120  	nostrict	stringnoz["nostrict"]
  1121  	unhide		stringnoz["unhide"]
  1122  	undelete	stringnoz["undelete"]
  1123  	noadinicb	stringnoz["noadinicb"]
  1124  	adinicb		stringnoz["adinicb"]
  1125  	shortad		stringnoz["shortad"]
  1126  	longad		stringnoz["longad"]
  1127  	utf8		stringnoz["utf8"]
  1128  	iocharset	fs_opt_codepage["iocharset"]
  1129  	uid_forget	stringnoz["uid=forget"]
  1130  	uid_ignore	stringnoz["uid=ignore"]
  1131  	gid_forget	stringnoz["gid=forget"]
  1132  	gid_ignore	stringnoz["gid=ignore"]
  1133  	gid		fs_opt_dec["gid", gid]
  1134  	uid		fs_opt_dec["uid", uid]
  1135  	umask		fs_opt_oct["umask", int32]
  1136  	mode		fs_opt_oct["mode", int32]
  1137  	dmode		fs_opt_oct["dmode", int32]
  1138  	bs		fs_opt_dec["bs", int32]
  1139  	session		fs_opt_dec["session", int32]
  1140  	lastblock	fs_opt_dec["lastblock", int32]
  1141  	anchor		fs_opt_dec["anchor", int32]
  1142  	volume		fs_opt_dec["volume", int32]
  1143  	partition	fs_opt_dec["partition", int32]
  1144  	fileset		fs_opt_dec["fileset", int32]
  1145  	rootdir		fs_opt_dec["rootdir", int32]
  1146  ] [varlen]
  1147  
  1148  esdfs_options [
  1149  	lower		fs_opt_str["lower"]
  1150  	upper		fs_opt_str["upper"]
  1151  	derive		fs_opt["derive", stringnoz[esdfs_derive]]
  1152  	confine		stringnoz["confine"]
  1153  	noconfine	stringnoz["noconfine"]
  1154  	derive_gid	stringnoz["derive_gid"]
  1155  	default_normal	stringnoz["default_normal"]
  1156  	dl_loc		fs_opt_str["dl_loc"]
  1157  	dl_uid		fs_opt_oct["dl_uid", uid]
  1158  	dl_gid		fs_opt_oct["dl_gid", gid]
  1159  	ns_fd		fs_opt_oct["ns_fd", fd_namespace]
  1160  	fsuid		fs_opt_oct["fsuid", uid]
  1161  	fsgid		fs_opt_oct["fsgid", gid]
  1162  	gid		fs_opt_oct["gid", gid]
  1163  	mask		fs_opt_oct["mask", int32]
  1164  	userid		fs_opt_oct["userid", uid]
  1165  	multiuser	stringnoz["multiuser"]
  1166  ] [varlen]
  1167  
  1168  esdfs_derive = "none", "legacy", "unified", "multi", "public"
  1169  
  1170  bcachefs_options [
  1171  	metadata_checksum		fs_opt["metadata_checksum", stringnoz[bcachefs_checksum]]
  1172  	data_checksum			fs_opt["data_checksum", stringnoz[bcachefs_checksum]]
  1173  	compression			fs_opt["compression", stringnoz[bcachefs_compression]]
  1174  	background_compression		fs_opt["background_compression", stringnoz[bcachefs_compression]]
  1175  	str_hash			fs_opt["str_hash", stringnoz[bcachefs_str_hash]]
  1176  	nocow				stringnoz["nocow"]
  1177  	errors_continue			stringnoz["errors=continue"]
  1178  	errors_fix_safe			stringnoz["errors=fix_safe"]
  1179  	errors_ro			stringnoz["error=ro"]
  1180  	metadata_replicas		fs_opt_hex["metadata_replicas", int32[1:4]]
  1181  	data_replicas			fs_opt_hex["data_replicas", int32[1:4]]
  1182  	metadata_replicas_required	fs_opt_hex["metadata_replicas_required", int32[1:4]]
  1183  	data_replicas_required		fs_opt_hex["data_replicas_required", int32[1:4]]
  1184  	erasure_code			stringnoz["erasure_code"]
  1185  	inodes_32bit			stringnoz["inodes_32bit"]
  1186  	shared_inode_numbers		stringnoz["shard_inode_numbers"]
  1187  	inodes_use_key_cache		stringnoz["inodes_use_key_cache"]
  1188  	btree_node_mem_ptr_optimization	stringnoz["btree_node_mem_ptr_optimization"]
  1189  	gc_reserve_percent		fs_opt_hex["gc_reserve_percent", int32[5:21]]
  1190  	gc_reserve_bytes		fs_opt_hex["gc_reserve_bytes", int32]
  1191  	root_reserve_percent		fs_opt_hex["root_reserve_percent", int32[0:100]]
  1192  	wide_macs			stringnoz["wide_macs"]
  1193  	inline_data			stringnoz["inline_data"]
  1194  	acl				stringnoz["acl"]
  1195  	usrquota			stringnoz["usrquota"]
  1196  	grpquota			stringnoz["grpquota"]
  1197  	prjquota			stringnoz["prjquota"]
  1198  	degraded			stringnoz["degraded"]
  1199  	very_degraded			stringnoz["very_degraded"]
  1200  	no_splitbrain_check		stringnoz["no_splitbrain_check"]
  1201  	discard				stringnoz["discard"]
  1202  	verbose				stringnoz["verbose"]
  1203  	journal_flush_delay		fs_opt_hex["journal_flush_delay", int32]
  1204  	journal_flush_disabled		stringnoz["journal_flush_disabled"]
  1205  	journal_reclaim_delay		fs_opt_hex["journal_reclaim_delay", int32]
  1206  	move_bytes_in_flight		fs_opt_hex["move_bytes_in_flight", int32]
  1207  	move_ios_in_flight		fs_opt_hex["move_ios_in_flight", int32[1:1024]]
  1208  	fsck				stringnoz["fsck"]
  1209  	fsck_memory_usage_percent	fs_opt_hex["fsck_memory_usage_percent", int32[20:70]]
  1210  	fix_errors			fs_opt["fix_errors", stringnoz[bcachefs_fix_errors]]
  1211  	ratelimit_errors		stringnoz["ratelimit_errors"]
  1212  	nochanges			stringnoz["nochanges"]
  1213  	norecovery			stringnoz["norecovery"]
  1214  	recovery_pass_last		fs_opt["recovery_pass_last", stringnoz[bcachefs_recovery_pass_last]]
  1215  	journal_transaction_names	stringnoz["journal_transaction_names"]
  1216  	allocator_stuck_timeout		fs_opt_hex["allocator_stuck_timeout", int16]
  1217  	noexcl				stringnoz["noexcl"]
  1218  	direct_io			stringnoz["direct_io"]
  1219  	sb				fs_opt_hex["sb", int32]
  1220  	read_only			stringnoz["read_only"]
  1221  	reconstruct_alloc		stringnoz["reconstruct_alloc"]
  1222  	version_upgrade			fs_opt["version_upgrade", stringnoz[bcachefs_version_upgrade]]
  1223  	nocow_enabled			stringnoz["nocow_enabled"]
  1224  	no_data_io			stringnoz["no_data_io"]
  1225  	btree_node_prefetch		stringnoz["btree_node_prefetch"]
  1226  ] [varlen]
  1227  
  1228  bcachefs_checksum = "none", "crc32c", "crc64", "xxhash"
  1229  bcachefs_compression = "none", "lz4", "gzip", "zstd"
  1230  bcachefs_str_hash = "crc32c", "crc64", "siphash"
  1231  bcachefs_fix_errors = "exit", "yes", "no", "ask"
  1232  bcachefs_version_upgrade = "compatible", "incompatible", "none"
  1233  bcachefs_recovery_pass_last = "scan_for_btree_nodes", "check_topology", "accounting_read", "alloc_read", "stripes_read", "initialize_subvolumes", "snapshots_read", "check_allocations", "trans_mark_dev_sbs", "fs_journal_alloc", "set_may_go_rw", "journal_replay", "check_alloc_info", "check_lrus", "check_btree_backpointers", "check_backpointers_to_extents", "check_extents_to_backpointers", "check_alloc_to_lru_refs", "fs_freespace_init", "bucket_gens_init", "reconstruct_snapshots", "check_snapshot_trees", "check_snapshots", "check_subvols", "check_subvol_children", "delete_dead_snapshots", "fs_upgrade_for_subvolumes", "check_inodes", "check_extents", "check_indirect_extents", "check_dirents", "check_xattrs", "check_root", "check_subvolume_structure", "check_directory_structure", "check_nlinks", "resume_logged_ops", "delete_dead_inodes", "fix_reflink_p", "set_fs_needs_rebalance"
  1234  
  1235  cgroup_options [
  1236  	all		stringnoz["all"]
  1237  	clone_children	stringnoz["clone_children"]
  1238  	cpuset_v2_mode	stringnoz["cpuset_v2_mode"]
  1239  	name		fs_opt_str["name"]
  1240  	none		stringnoz["none"]
  1241  	noprefix	stringnoz["noprefix"]
  1242  	release_agent	fs_opt_filename["release_agent"]
  1243  	xattr		stringnoz["xattr"]
  1244  	favordynmods	stringnoz["favordynmods"]
  1245  	nofavordynmods	stringnoz["nofavordynmods"]
  1246  	subsystem	stringnoz[cgroup_subsystems]
  1247  ] [varlen]
  1248  
  1249  cgroup2_options [
  1250  	nsdelegate			stringnoz["nsdelegate"]
  1251  	favordynmods			stringnoz["favordynmods"]
  1252  	memory_localevents		stringnoz["memory_localevents"]
  1253  	memory_recursiveprot		stringnoz["memory_recursiveprot"]
  1254  	memory_hugetlb_accounting	stringnoz["memory_hugetlb_accounting"]
  1255  	pids_localevents		stringnoz["pids_localevents"]
  1256  	subsystem			stringnoz[cgroup_subsystems]
  1257  ] [varlen]
  1258  
  1259  ufs_options [
  1260  	type	fs_opt["type", stringnoz[ufs_type]]
  1261  	onerror	fs_opt["onerror", stringnoz[ufs_onerror]]
  1262  ] [varlen]
  1263  
  1264  ufs_type = "old", "sunx86", "sun", "sunos", "44bsd", "ufs2", "5xbsd", "hp", "nextstep-cd", "nextstep", "openstep"
  1265  ufs_onerror = "lock", "umount", "repair"
  1266  
  1267  codepage_nums = "1250", "1251", "1255", "437", "737", "775", "850", "852", "855", "857", "860", "861", "862", "863", "864", "865", "866", "869", "874", "932", "936", "949", "950"
  1268  codepages_names = "macceltic", "maccenteuro", "maccroatian", "maccyrillic", "macgaelic", "macgreek", "maciceland", "macinuit", "macroman", "macromanian", "macturkish", "ascii", "default", "cp1250", "cp1251", "cp1255", "cp437", "cp737", "cp775", "cp850", "cp852", "cp855", "cp857", "cp860", "cp861", "cp862", "cp863", "cp864", "cp865", "cp866", "cp869", "cp874", "cp932", "cp936", "cp949", "cp950", "euc-jp", "iso8859-13", "iso8859-14", "iso8859-15", "iso8859-1", "iso8859-2", "iso8859-3", "iso8859-4", "iso8859-5", "iso8859-6", "iso8859-7", "iso8859-9", "koi8-r", "koi8-ru", "koi8-u", "utf8", "none"
  1269  mount_flags = MS_BIND, MS_DIRSYNC, MS_MANDLOCK, MS_MOVE, MS_NOATIME, MS_NODEV, MS_NODIRATIME, MS_NOEXEC, MS_NOSUID, MS_RDONLY, MS_RELATIME, MS_REMOUNT, MS_SILENT, MS_STRICTATIME, MS_SYNCHRONOUS, MS_REC, MS_POSIXACL, MS_UNBINDABLE, MS_PRIVATE, MS_SLAVE, MS_SHARED, MS_I_VERSION, MS_LAZYTIME
  1270  umount_flags = MNT_FORCE, MNT_DETACH, MNT_EXPIRE, UMOUNT_NOFOLLOW