xref: /openbmc/linux/fs/jffs2/Kconfig (revision ec8f24b7)
1ec8f24b7SThomas Gleixner# SPDX-License-Identifier: GPL-2.0-only
231db6e9eSAlexey Dobriyanconfig JFFS2_FS
331db6e9eSAlexey Dobriyan	tristate "Journalling Flash File System v2 (JFFS2) support"
431db6e9eSAlexey Dobriyan	select CRC32
531db6e9eSAlexey Dobriyan	depends on MTD
631db6e9eSAlexey Dobriyan	help
731db6e9eSAlexey Dobriyan	  JFFS2 is the second generation of the Journalling Flash File System
831db6e9eSAlexey Dobriyan	  for use on diskless embedded devices. It provides improved wear
931db6e9eSAlexey Dobriyan	  levelling, compression and support for hard links. You cannot use
1031db6e9eSAlexey Dobriyan	  this on normal block devices, only on 'MTD' devices.
1131db6e9eSAlexey Dobriyan
1231db6e9eSAlexey Dobriyan	  Further information on the design and implementation of JFFS2 is
1331db6e9eSAlexey Dobriyan	  available at <http://sources.redhat.com/jffs2/>.
1431db6e9eSAlexey Dobriyan
1531db6e9eSAlexey Dobriyanconfig JFFS2_FS_DEBUG
1631db6e9eSAlexey Dobriyan	int "JFFS2 debugging verbosity (0 = quiet, 2 = noisy)"
1731db6e9eSAlexey Dobriyan	depends on JFFS2_FS
1831db6e9eSAlexey Dobriyan	default "0"
1931db6e9eSAlexey Dobriyan	help
2031db6e9eSAlexey Dobriyan	  This controls the amount of debugging messages produced by the JFFS2
2131db6e9eSAlexey Dobriyan	  code. Set it to zero for use in production systems. For evaluation,
2231db6e9eSAlexey Dobriyan	  testing and debugging, it's advisable to set it to one. This will
2331db6e9eSAlexey Dobriyan	  enable a few assertions and will print debugging messages at the
2431db6e9eSAlexey Dobriyan	  KERN_DEBUG loglevel, where they won't normally be visible. Level 2
2531db6e9eSAlexey Dobriyan	  is unlikely to be useful - it enables extra debugging in certain
2631db6e9eSAlexey Dobriyan	  areas which at one point needed debugging, but when the bugs were
2731db6e9eSAlexey Dobriyan	  located and fixed, the detailed messages were relegated to level 2.
2831db6e9eSAlexey Dobriyan
2931db6e9eSAlexey Dobriyan	  If reporting bugs, please try to have available a full dump of the
3031db6e9eSAlexey Dobriyan	  messages at debug level 1 while the misbehaviour was occurring.
3131db6e9eSAlexey Dobriyan
3231db6e9eSAlexey Dobriyanconfig JFFS2_FS_WRITEBUFFER
3331db6e9eSAlexey Dobriyan	bool "JFFS2 write-buffering support"
3431db6e9eSAlexey Dobriyan	depends on JFFS2_FS
3531db6e9eSAlexey Dobriyan	default y
3631db6e9eSAlexey Dobriyan	help
3731db6e9eSAlexey Dobriyan	  This enables the write-buffering support in JFFS2.
3831db6e9eSAlexey Dobriyan
3931db6e9eSAlexey Dobriyan	  This functionality is required to support JFFS2 on the following
4031db6e9eSAlexey Dobriyan	  types of flash devices:
4131db6e9eSAlexey Dobriyan	    - NAND flash
4231db6e9eSAlexey Dobriyan	    - NOR flash with transparent ECC
4331db6e9eSAlexey Dobriyan	    - DataFlash
4431db6e9eSAlexey Dobriyan
4531db6e9eSAlexey Dobriyanconfig JFFS2_FS_WBUF_VERIFY
4631db6e9eSAlexey Dobriyan	bool "Verify JFFS2 write-buffer reads"
4731db6e9eSAlexey Dobriyan	depends on JFFS2_FS_WRITEBUFFER
4831db6e9eSAlexey Dobriyan	default n
4931db6e9eSAlexey Dobriyan	help
5031db6e9eSAlexey Dobriyan	  This causes JFFS2 to read back every page written through the
5131db6e9eSAlexey Dobriyan	  write-buffer, and check for errors.
5231db6e9eSAlexey Dobriyan
5331db6e9eSAlexey Dobriyanconfig JFFS2_SUMMARY
54cf98c5e5SKees Cook	bool "JFFS2 summary support"
55cf98c5e5SKees Cook	depends on JFFS2_FS
5631db6e9eSAlexey Dobriyan	default n
5731db6e9eSAlexey Dobriyan	help
5831db6e9eSAlexey Dobriyan	  This feature makes it possible to use summary information
5931db6e9eSAlexey Dobriyan	  for faster filesystem mount.
6031db6e9eSAlexey Dobriyan
6131db6e9eSAlexey Dobriyan	  The summary information can be inserted into a filesystem image
6231db6e9eSAlexey Dobriyan	  by the utility 'sumtool'.
6331db6e9eSAlexey Dobriyan
6431db6e9eSAlexey Dobriyan	  If unsure, say 'N'.
6531db6e9eSAlexey Dobriyan
6631db6e9eSAlexey Dobriyanconfig JFFS2_FS_XATTR
67cf98c5e5SKees Cook	bool "JFFS2 XATTR support"
68cf98c5e5SKees Cook	depends on JFFS2_FS
6931db6e9eSAlexey Dobriyan	default n
7031db6e9eSAlexey Dobriyan	help
7131db6e9eSAlexey Dobriyan	  Extended attributes are name:value pairs associated with inodes by
7291581e4cSAdam Borowski	  the kernel or by users (see the attr(5) manual page for details).
7331db6e9eSAlexey Dobriyan
7431db6e9eSAlexey Dobriyan	  If unsure, say N.
7531db6e9eSAlexey Dobriyan
7631db6e9eSAlexey Dobriyanconfig JFFS2_FS_POSIX_ACL
7731db6e9eSAlexey Dobriyan	bool "JFFS2 POSIX Access Control Lists"
7831db6e9eSAlexey Dobriyan	depends on JFFS2_FS_XATTR
7931db6e9eSAlexey Dobriyan	default y
8031db6e9eSAlexey Dobriyan	select FS_POSIX_ACL
8131db6e9eSAlexey Dobriyan	help
8231db6e9eSAlexey Dobriyan	  Posix Access Control Lists (ACLs) support permissions for users and
8331db6e9eSAlexey Dobriyan	  groups beyond the owner/group/world scheme.
8431db6e9eSAlexey Dobriyan
8531db6e9eSAlexey Dobriyan	  If you don't know what Access Control Lists are, say N
8631db6e9eSAlexey Dobriyan
8731db6e9eSAlexey Dobriyanconfig JFFS2_FS_SECURITY
8831db6e9eSAlexey Dobriyan	bool "JFFS2 Security Labels"
8931db6e9eSAlexey Dobriyan	depends on JFFS2_FS_XATTR
9031db6e9eSAlexey Dobriyan	default y
9131db6e9eSAlexey Dobriyan	help
9231db6e9eSAlexey Dobriyan	  Security labels support alternative access control models
9331db6e9eSAlexey Dobriyan	  implemented by security modules like SELinux.  This option
9431db6e9eSAlexey Dobriyan	  enables an extended attribute handler for file security
9531db6e9eSAlexey Dobriyan	  labels in the jffs2 filesystem.
9631db6e9eSAlexey Dobriyan
9731db6e9eSAlexey Dobriyan	  If you are not using a security module that requires using
9831db6e9eSAlexey Dobriyan	  extended attributes for file security labels, say N.
9931db6e9eSAlexey Dobriyan
10031db6e9eSAlexey Dobriyanconfig JFFS2_COMPRESSION_OPTIONS
10131db6e9eSAlexey Dobriyan	bool "Advanced compression options for JFFS2"
10231db6e9eSAlexey Dobriyan	depends on JFFS2_FS
10331db6e9eSAlexey Dobriyan	default n
10431db6e9eSAlexey Dobriyan	help
10531db6e9eSAlexey Dobriyan	  Enabling this option allows you to explicitly choose which
10631db6e9eSAlexey Dobriyan	  compression modules, if any, are enabled in JFFS2. Removing
10731db6e9eSAlexey Dobriyan	  compressors can mean you cannot read existing file systems,
10831db6e9eSAlexey Dobriyan	  and enabling experimental compressors can mean that you
10931db6e9eSAlexey Dobriyan	  write a file system which cannot be read by a standard kernel.
11031db6e9eSAlexey Dobriyan
11131db6e9eSAlexey Dobriyan	  If unsure, you should _definitely_ say 'N'.
11231db6e9eSAlexey Dobriyan
11331db6e9eSAlexey Dobriyanconfig JFFS2_ZLIB
11431db6e9eSAlexey Dobriyan	bool "JFFS2 ZLIB compression support" if JFFS2_COMPRESSION_OPTIONS
11531db6e9eSAlexey Dobriyan	select ZLIB_INFLATE
11631db6e9eSAlexey Dobriyan	select ZLIB_DEFLATE
11731db6e9eSAlexey Dobriyan	depends on JFFS2_FS
11831db6e9eSAlexey Dobriyan	default y
11931db6e9eSAlexey Dobriyan	help
12031db6e9eSAlexey Dobriyan	  Zlib is designed to be a free, general-purpose, legally unencumbered,
12131db6e9eSAlexey Dobriyan	  lossless data-compression library for use on virtually any computer
12231db6e9eSAlexey Dobriyan	  hardware and operating system. See <http://www.gzip.org/zlib/> for
12331db6e9eSAlexey Dobriyan	  further information.
12431db6e9eSAlexey Dobriyan
12531db6e9eSAlexey Dobriyan	  Say 'Y' if unsure.
12631db6e9eSAlexey Dobriyan
12731db6e9eSAlexey Dobriyanconfig JFFS2_LZO
12831db6e9eSAlexey Dobriyan	bool "JFFS2 LZO compression support" if JFFS2_COMPRESSION_OPTIONS
12931db6e9eSAlexey Dobriyan	select LZO_COMPRESS
13031db6e9eSAlexey Dobriyan	select LZO_DECOMPRESS
13131db6e9eSAlexey Dobriyan	depends on JFFS2_FS
13231db6e9eSAlexey Dobriyan	default n
13331db6e9eSAlexey Dobriyan	help
13431db6e9eSAlexey Dobriyan	  minilzo-based compression. Generally works better than Zlib.
13531db6e9eSAlexey Dobriyan
13631db6e9eSAlexey Dobriyan	  This feature was added in July, 2007. Say 'N' if you need
13731db6e9eSAlexey Dobriyan	  compatibility with older bootloaders or kernels.
13831db6e9eSAlexey Dobriyan
13931db6e9eSAlexey Dobriyanconfig JFFS2_RTIME
14031db6e9eSAlexey Dobriyan	bool "JFFS2 RTIME compression support" if JFFS2_COMPRESSION_OPTIONS
14131db6e9eSAlexey Dobriyan	depends on JFFS2_FS
14231db6e9eSAlexey Dobriyan	default y
14331db6e9eSAlexey Dobriyan	help
14431db6e9eSAlexey Dobriyan	  Rtime does manage to recompress already-compressed data. Say 'Y' if unsure.
14531db6e9eSAlexey Dobriyan
14631db6e9eSAlexey Dobriyanconfig JFFS2_RUBIN
14731db6e9eSAlexey Dobriyan	bool "JFFS2 RUBIN compression support" if JFFS2_COMPRESSION_OPTIONS
14831db6e9eSAlexey Dobriyan	depends on JFFS2_FS
14931db6e9eSAlexey Dobriyan	default n
15031db6e9eSAlexey Dobriyan	help
15131db6e9eSAlexey Dobriyan	  RUBINMIPS and DYNRUBIN compressors. Say 'N' if unsure.
15231db6e9eSAlexey Dobriyan
15331db6e9eSAlexey Dobriyanchoice
15431db6e9eSAlexey Dobriyan	prompt "JFFS2 default compression mode" if JFFS2_COMPRESSION_OPTIONS
15531db6e9eSAlexey Dobriyan	default JFFS2_CMODE_PRIORITY
15631db6e9eSAlexey Dobriyan	depends on JFFS2_FS
15731db6e9eSAlexey Dobriyan	help
15831db6e9eSAlexey Dobriyan	  You can set here the default compression mode of JFFS2 from
15931db6e9eSAlexey Dobriyan	  the available compression modes. Don't touch if unsure.
16031db6e9eSAlexey Dobriyan
16131db6e9eSAlexey Dobriyanconfig JFFS2_CMODE_NONE
16231db6e9eSAlexey Dobriyan	bool "no compression"
16331db6e9eSAlexey Dobriyan	help
16431db6e9eSAlexey Dobriyan	  Uses no compression.
16531db6e9eSAlexey Dobriyan
16631db6e9eSAlexey Dobriyanconfig JFFS2_CMODE_PRIORITY
16731db6e9eSAlexey Dobriyan	bool "priority"
16831db6e9eSAlexey Dobriyan	help
16931db6e9eSAlexey Dobriyan	  Tries the compressors in a predefined order and chooses the first
17031db6e9eSAlexey Dobriyan	  successful one.
17131db6e9eSAlexey Dobriyan
17231db6e9eSAlexey Dobriyanconfig JFFS2_CMODE_SIZE
173cf98c5e5SKees Cook	bool "size"
17431db6e9eSAlexey Dobriyan	help
17531db6e9eSAlexey Dobriyan	  Tries all compressors and chooses the one which has the smallest
17631db6e9eSAlexey Dobriyan	  result.
17731db6e9eSAlexey Dobriyan
17831db6e9eSAlexey Dobriyanconfig JFFS2_CMODE_FAVOURLZO
17931db6e9eSAlexey Dobriyan	bool "Favour LZO"
18031db6e9eSAlexey Dobriyan	help
18131db6e9eSAlexey Dobriyan	  Tries all compressors and chooses the one which has the smallest
18231db6e9eSAlexey Dobriyan	  result but gives some preference to LZO (which has faster
18331db6e9eSAlexey Dobriyan	  decompression) at the expense of size.
18431db6e9eSAlexey Dobriyan
18531db6e9eSAlexey Dobriyanendchoice
186