18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only
28c2ecf20Sopenharmony_ciconfig F2FS_FS
38c2ecf20Sopenharmony_ci	tristate "F2FS filesystem support"
48c2ecf20Sopenharmony_ci	depends on BLOCK
58c2ecf20Sopenharmony_ci	select NLS
68c2ecf20Sopenharmony_ci	select CRYPTO
78c2ecf20Sopenharmony_ci	select CRYPTO_CRC32
88c2ecf20Sopenharmony_ci	select F2FS_FS_XATTR if FS_ENCRYPTION
98c2ecf20Sopenharmony_ci	select FS_ENCRYPTION_ALGS if FS_ENCRYPTION
108c2ecf20Sopenharmony_ci	help
118c2ecf20Sopenharmony_ci	  F2FS is based on Log-structured File System (LFS), which supports
128c2ecf20Sopenharmony_ci	  versatile "flash-friendly" features. The design has been focused on
138c2ecf20Sopenharmony_ci	  addressing the fundamental issues in LFS, which are snowball effect
148c2ecf20Sopenharmony_ci	  of wandering tree and high cleaning overhead.
158c2ecf20Sopenharmony_ci
168c2ecf20Sopenharmony_ci	  Since flash-based storages show different characteristics according to
178c2ecf20Sopenharmony_ci	  the internal geometry or flash memory management schemes aka FTL, F2FS
188c2ecf20Sopenharmony_ci	  and tools support various parameters not only for configuring on-disk
198c2ecf20Sopenharmony_ci	  layout, but also for selecting allocation and cleaning algorithms.
208c2ecf20Sopenharmony_ci
218c2ecf20Sopenharmony_ci	  If unsure, say N.
228c2ecf20Sopenharmony_ci
238c2ecf20Sopenharmony_ciconfig F2FS_STAT_FS
248c2ecf20Sopenharmony_ci	bool "F2FS Status Information"
258c2ecf20Sopenharmony_ci	depends on F2FS_FS
268c2ecf20Sopenharmony_ci	default y
278c2ecf20Sopenharmony_ci	help
288c2ecf20Sopenharmony_ci	  /sys/kernel/debug/f2fs/ contains information about all the partitions
298c2ecf20Sopenharmony_ci	  mounted as f2fs. Each file shows the whole f2fs information.
308c2ecf20Sopenharmony_ci
318c2ecf20Sopenharmony_ci	  /sys/kernel/debug/f2fs/status includes:
328c2ecf20Sopenharmony_ci	    - major filesystem information managed by f2fs currently
338c2ecf20Sopenharmony_ci	    - average SIT information about whole segments
348c2ecf20Sopenharmony_ci	    - current memory footprint consumed by f2fs.
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ciconfig F2FS_FS_XATTR
378c2ecf20Sopenharmony_ci	bool "F2FS extended attributes"
388c2ecf20Sopenharmony_ci	depends on F2FS_FS
398c2ecf20Sopenharmony_ci	default y
408c2ecf20Sopenharmony_ci	help
418c2ecf20Sopenharmony_ci	  Extended attributes are name:value pairs associated with inodes by
428c2ecf20Sopenharmony_ci	  the kernel or by users (see the attr(5) manual page for details).
438c2ecf20Sopenharmony_ci
448c2ecf20Sopenharmony_ci	  If unsure, say N.
458c2ecf20Sopenharmony_ci
468c2ecf20Sopenharmony_ciconfig F2FS_FS_POSIX_ACL
478c2ecf20Sopenharmony_ci	bool "F2FS Access Control Lists"
488c2ecf20Sopenharmony_ci	depends on F2FS_FS_XATTR
498c2ecf20Sopenharmony_ci	select FS_POSIX_ACL
508c2ecf20Sopenharmony_ci	default y
518c2ecf20Sopenharmony_ci	help
528c2ecf20Sopenharmony_ci	  Posix Access Control Lists (ACLs) support permissions for users and
538c2ecf20Sopenharmony_ci	  groups beyond the owner/group/world scheme.
548c2ecf20Sopenharmony_ci
558c2ecf20Sopenharmony_ci	  If you don't know what Access Control Lists are, say N
568c2ecf20Sopenharmony_ci
578c2ecf20Sopenharmony_ciconfig F2FS_FS_SECURITY
588c2ecf20Sopenharmony_ci	bool "F2FS Security Labels"
598c2ecf20Sopenharmony_ci	depends on F2FS_FS_XATTR
608c2ecf20Sopenharmony_ci	help
618c2ecf20Sopenharmony_ci	  Security labels provide an access control facility to support Linux
628c2ecf20Sopenharmony_ci	  Security Models (LSMs) accepted by AppArmor, SELinux, Smack and TOMOYO
638c2ecf20Sopenharmony_ci	  Linux. This option enables an extended attribute handler for file
648c2ecf20Sopenharmony_ci	  security labels in the f2fs filesystem, so that it requires enabling
658c2ecf20Sopenharmony_ci	  the extended attribute support in advance. In particular you need this
668c2ecf20Sopenharmony_ci	  option if you use the setcap command to assign initial process capabi-
678c2ecf20Sopenharmony_ci	  lities to executables (the security.* extended attributes).
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci	  If you are not using a security module, say N.
708c2ecf20Sopenharmony_ci
718c2ecf20Sopenharmony_ciconfig F2FS_CHECK_FS
728c2ecf20Sopenharmony_ci	bool "F2FS consistency checking feature"
738c2ecf20Sopenharmony_ci	depends on F2FS_FS
748c2ecf20Sopenharmony_ci	help
758c2ecf20Sopenharmony_ci	  Enables BUG_ONs which check the filesystem consistency in runtime.
768c2ecf20Sopenharmony_ci
778c2ecf20Sopenharmony_ci	  If you want to improve the performance, say N.
788c2ecf20Sopenharmony_ci
798c2ecf20Sopenharmony_ciconfig F2FS_IO_TRACE
808c2ecf20Sopenharmony_ci	bool "F2FS IO tracer"
818c2ecf20Sopenharmony_ci	depends on F2FS_FS
828c2ecf20Sopenharmony_ci	depends on FUNCTION_TRACER
838c2ecf20Sopenharmony_ci	help
848c2ecf20Sopenharmony_ci	  F2FS IO trace is based on a function trace, which gathers process
858c2ecf20Sopenharmony_ci	  information and block IO patterns in the filesystem level.
868c2ecf20Sopenharmony_ci
878c2ecf20Sopenharmony_ci	  If unsure, say N.
888c2ecf20Sopenharmony_ci
898c2ecf20Sopenharmony_ciconfig F2FS_FAULT_INJECTION
908c2ecf20Sopenharmony_ci	bool "F2FS fault injection facility"
918c2ecf20Sopenharmony_ci	depends on F2FS_FS
928c2ecf20Sopenharmony_ci	help
938c2ecf20Sopenharmony_ci	  Test F2FS to inject faults such as ENOMEM, ENOSPC, and so on.
948c2ecf20Sopenharmony_ci
958c2ecf20Sopenharmony_ci	  If unsure, say N.
968c2ecf20Sopenharmony_ci
978c2ecf20Sopenharmony_ciconfig F2FS_FS_COMPRESSION
988c2ecf20Sopenharmony_ci	bool "F2FS compression feature"
998c2ecf20Sopenharmony_ci	depends on F2FS_FS
1008c2ecf20Sopenharmony_ci	help
1018c2ecf20Sopenharmony_ci	  Enable filesystem-level compression on f2fs regular files,
1028c2ecf20Sopenharmony_ci	  multiple back-end compression algorithms are supported.
1038c2ecf20Sopenharmony_ci
1048c2ecf20Sopenharmony_ciconfig F2FS_FS_LZO
1058c2ecf20Sopenharmony_ci	bool "LZO compression support"
1068c2ecf20Sopenharmony_ci	depends on F2FS_FS_COMPRESSION
1078c2ecf20Sopenharmony_ci	select LZO_COMPRESS
1088c2ecf20Sopenharmony_ci	select LZO_DECOMPRESS
1098c2ecf20Sopenharmony_ci	default y
1108c2ecf20Sopenharmony_ci	help
1118c2ecf20Sopenharmony_ci	  Support LZO compress algorithm, if unsure, say Y.
1128c2ecf20Sopenharmony_ci
1138c2ecf20Sopenharmony_ciconfig F2FS_FS_LZ4
1148c2ecf20Sopenharmony_ci	bool "LZ4 compression support"
1158c2ecf20Sopenharmony_ci	depends on F2FS_FS_COMPRESSION
1168c2ecf20Sopenharmony_ci	select LZ4_COMPRESS
1178c2ecf20Sopenharmony_ci	select LZ4_DECOMPRESS
1188c2ecf20Sopenharmony_ci	default y
1198c2ecf20Sopenharmony_ci	help
1208c2ecf20Sopenharmony_ci	  Support LZ4 compress algorithm, if unsure, say Y.
1218c2ecf20Sopenharmony_ci
1228c2ecf20Sopenharmony_ciconfig F2FS_FS_ZSTD
1238c2ecf20Sopenharmony_ci	bool "ZSTD compression support"
1248c2ecf20Sopenharmony_ci	depends on F2FS_FS_COMPRESSION
1258c2ecf20Sopenharmony_ci	select ZSTD_COMPRESS
1268c2ecf20Sopenharmony_ci	select ZSTD_DECOMPRESS
1278c2ecf20Sopenharmony_ci	default y
1288c2ecf20Sopenharmony_ci	help
1298c2ecf20Sopenharmony_ci	  Support ZSTD compress algorithm, if unsure, say Y.
1308c2ecf20Sopenharmony_ci
1318c2ecf20Sopenharmony_ciconfig F2FS_FS_LZORLE
1328c2ecf20Sopenharmony_ci	bool "LZO-RLE compression support"
1338c2ecf20Sopenharmony_ci	depends on F2FS_FS_COMPRESSION
1348c2ecf20Sopenharmony_ci	depends on F2FS_FS_LZO
1358c2ecf20Sopenharmony_ci	select LZO_COMPRESS
1368c2ecf20Sopenharmony_ci	select LZO_DECOMPRESS
1378c2ecf20Sopenharmony_ci	default y
1388c2ecf20Sopenharmony_ci	help
1398c2ecf20Sopenharmony_ci	  Support LZO-RLE compress algorithm, if unsure, say Y.
1408c2ecf20Sopenharmony_ci
1418c2ecf20Sopenharmony_ciconfig F2FS_GRADING_SSR
1428c2ecf20Sopenharmony_ci	bool "F2FS grading ssr"
1438c2ecf20Sopenharmony_ci	depends on F2FS_FS
1448c2ecf20Sopenharmony_ci	default y
1458c2ecf20Sopenharmony_ci	help
1468c2ecf20Sopenharmony_ci	  use grading ssr to improve the end performance
147