1ec8f24b7SThomas Gleixner# SPDX-License-Identifier: GPL-2.0-only 21c6ace01SAlexey Dobriyanconfig FAT_FS 31c6ace01SAlexey Dobriyan tristate 4*925c86a1SChristoph Hellwig select BUFFER_HEAD 51c6ace01SAlexey Dobriyan select NLS 69636e650SChristoph Hellwig select LEGACY_DIRECT_IO 71c6ace01SAlexey Dobriyan help 81c6ace01SAlexey Dobriyan If you want to use one of the FAT-based file systems (the MS-DOS and 91c6ace01SAlexey Dobriyan VFAT (Windows 95) file systems), then you must say Y or M here 101c6ace01SAlexey Dobriyan to include FAT support. You will then be able to mount partitions or 111c6ace01SAlexey Dobriyan diskettes with FAT-based file systems and transparently access the 121c6ace01SAlexey Dobriyan files on them, i.e. MSDOS files will look and behave just like all 131c6ace01SAlexey Dobriyan other Unix files. 141c6ace01SAlexey Dobriyan 151c6ace01SAlexey Dobriyan This FAT support is not a file system in itself, it only provides 161c6ace01SAlexey Dobriyan the foundation for the other file systems. You will have to say Y or 171c6ace01SAlexey Dobriyan M to at least one of "MSDOS fs support" or "VFAT fs support" in 181c6ace01SAlexey Dobriyan order to make use of it. 191c6ace01SAlexey Dobriyan 201c6ace01SAlexey Dobriyan Another way to read and write MSDOS floppies and hard drive 211c6ace01SAlexey Dobriyan partitions from within Linux (but not transparently) is with the 221c6ace01SAlexey Dobriyan mtools ("man mtools") program suite. You don't need to say Y here in 231c6ace01SAlexey Dobriyan order to do that. 241c6ace01SAlexey Dobriyan 251c6ace01SAlexey Dobriyan If you need to move large files on floppies between a DOS and a 261c6ace01SAlexey Dobriyan Linux box, say Y here, mount the floppy under Linux with an MSDOS 271c6ace01SAlexey Dobriyan file system and use GNU tar's M option. GNU tar is a program 281c6ace01SAlexey Dobriyan available for Unix and DOS ("man tar" or "info tar"). 291c6ace01SAlexey Dobriyan 301c6ace01SAlexey Dobriyan The FAT support will enlarge your kernel by about 37 KB. If unsure, 311c6ace01SAlexey Dobriyan say Y. 321c6ace01SAlexey Dobriyan 331c6ace01SAlexey Dobriyan To compile this as a module, choose M here: the module will be called 341c6ace01SAlexey Dobriyan fat. Note that if you compile the FAT support as a module, you 351c6ace01SAlexey Dobriyan cannot compile any of the FAT-based file systems into the kernel 361c6ace01SAlexey Dobriyan -- they will have to be modules as well. 371c6ace01SAlexey Dobriyan 381c6ace01SAlexey Dobriyanconfig MSDOS_FS 391c6ace01SAlexey Dobriyan tristate "MSDOS fs support" 401c6ace01SAlexey Dobriyan select FAT_FS 411c6ace01SAlexey Dobriyan help 421c6ace01SAlexey Dobriyan This allows you to mount MSDOS partitions of your hard drive (unless 431c6ace01SAlexey Dobriyan they are compressed; to access compressed MSDOS partitions under 441c6ace01SAlexey Dobriyan Linux, you can either use the DOS emulator DOSEMU, described in the 451c6ace01SAlexey Dobriyan DOSEMU-HOWTO, available from 464ecfed61SAlexander A. Klimov <https://www.tldp.org/docs.html#howto>, or try dmsdosfs in 471c6ace01SAlexey Dobriyan <ftp://ibiblio.org/pub/Linux/system/filesystems/dosfs/>. If you 481c6ace01SAlexey Dobriyan intend to use dosemu with a non-compressed MSDOS partition, say Y 491c6ace01SAlexey Dobriyan here) and MSDOS floppies. This means that file access becomes 501c6ace01SAlexey Dobriyan transparent, i.e. the MSDOS files look and behave just like all 511c6ace01SAlexey Dobriyan other Unix files. 521c6ace01SAlexey Dobriyan 531c6ace01SAlexey Dobriyan If you have Windows 95 or Windows NT installed on your MSDOS 541c6ace01SAlexey Dobriyan partitions, you should use the VFAT file system (say Y to "VFAT fs 551c6ace01SAlexey Dobriyan support" below), or you will not be able to see the long filenames 561c6ace01SAlexey Dobriyan generated by Windows 95 / Windows NT. 571c6ace01SAlexey Dobriyan 581c6ace01SAlexey Dobriyan This option will enlarge your kernel by about 7 KB. If unsure, 591c6ace01SAlexey Dobriyan answer Y. This will only work if you said Y to "DOS FAT fs support" 601c6ace01SAlexey Dobriyan as well. To compile this as a module, choose M here: the module will 611c6ace01SAlexey Dobriyan be called msdos. 621c6ace01SAlexey Dobriyan 631c6ace01SAlexey Dobriyanconfig VFAT_FS 641c6ace01SAlexey Dobriyan tristate "VFAT (Windows-95) fs support" 651c6ace01SAlexey Dobriyan select FAT_FS 661c6ace01SAlexey Dobriyan help 671c6ace01SAlexey Dobriyan This option provides support for normal Windows file systems with 681c6ace01SAlexey Dobriyan long filenames. That includes non-compressed FAT-based file systems 691c6ace01SAlexey Dobriyan used by Windows 95, Windows 98, Windows NT 4.0, and the Unix 701c6ace01SAlexey Dobriyan programs from the mtools package. 711c6ace01SAlexey Dobriyan 721c6ace01SAlexey Dobriyan The VFAT support enlarges your kernel by about 10 KB and it only 731c6ace01SAlexey Dobriyan works if you said Y to the "DOS FAT fs support" above. Please read 7472ef5e52SMauro Carvalho Chehab the file <file:Documentation/filesystems/vfat.rst> for details. If 751c6ace01SAlexey Dobriyan unsure, say Y. 761c6ace01SAlexey Dobriyan 771c6ace01SAlexey Dobriyan To compile this as a module, choose M here: the module will be called 781c6ace01SAlexey Dobriyan vfat. 791c6ace01SAlexey Dobriyan 801c6ace01SAlexey Dobriyanconfig FAT_DEFAULT_CODEPAGE 811c6ace01SAlexey Dobriyan int "Default codepage for FAT" 82b0d4adafSDavid Gow depends on FAT_FS 831c6ace01SAlexey Dobriyan default 437 841c6ace01SAlexey Dobriyan help 851c6ace01SAlexey Dobriyan This option should be set to the codepage of your FAT filesystems. 861c6ace01SAlexey Dobriyan It can be overridden with the "codepage" mount option. 8772ef5e52SMauro Carvalho Chehab See <file:Documentation/filesystems/vfat.rst> for more information. 881c6ace01SAlexey Dobriyan 891c6ace01SAlexey Dobriyanconfig FAT_DEFAULT_IOCHARSET 901c6ace01SAlexey Dobriyan string "Default iocharset for FAT" 911c6ace01SAlexey Dobriyan depends on VFAT_FS 921c6ace01SAlexey Dobriyan default "iso8859-1" 931c6ace01SAlexey Dobriyan help 941c6ace01SAlexey Dobriyan Set this to the default input/output character set you'd 951c6ace01SAlexey Dobriyan like FAT to use. It should probably match the character set 961c6ace01SAlexey Dobriyan that most of your FAT filesystems use, and can be overridden 971c6ace01SAlexey Dobriyan with the "iocharset" mount option for FAT filesystems. 981c6ace01SAlexey Dobriyan Note that "utf8" is not recommended for FAT filesystems. 9938739380SMaciej S. Szmigiero If unsure, you shouldn't set "utf8" here - select the next option 10038739380SMaciej S. Szmigiero instead if you would like to use UTF-8 encoded file names by default. 10172ef5e52SMauro Carvalho Chehab See <file:Documentation/filesystems/vfat.rst> for more information. 102d29a2e94SAlan Cox 103d29a2e94SAlan Cox Enable any character sets you need in File Systems/Native Language 104d29a2e94SAlan Cox Support. 10538739380SMaciej S. Szmigiero 10638739380SMaciej S. Szmigieroconfig FAT_DEFAULT_UTF8 10738739380SMaciej S. Szmigiero bool "Enable FAT UTF-8 option by default" 10838739380SMaciej S. Szmigiero depends on VFAT_FS 10938739380SMaciej S. Szmigiero default n 11038739380SMaciej S. Szmigiero help 11138739380SMaciej S. Szmigiero Set this if you would like to have "utf8" mount option set 11238739380SMaciej S. Szmigiero by default when mounting FAT filesystems. 11338739380SMaciej S. Szmigiero 11438739380SMaciej S. Szmigiero Even if you say Y here can always disable UTF-8 for 11538739380SMaciej S. Szmigiero particular mount by adding "utf8=0" to mount options. 11638739380SMaciej S. Szmigiero 11738739380SMaciej S. Szmigiero Say Y if you use UTF-8 encoding for file names, N otherwise. 11838739380SMaciej S. Szmigiero 11972ef5e52SMauro Carvalho Chehab See <file:Documentation/filesystems/vfat.rst> for more information. 120b0d4adafSDavid Gow 121b0d4adafSDavid Gowconfig FAT_KUNIT_TEST 122b0d4adafSDavid Gow tristate "Unit Tests for FAT filesystems" if !KUNIT_ALL_TESTS 123b0d4adafSDavid Gow depends on KUNIT && FAT_FS 124b0d4adafSDavid Gow default KUNIT_ALL_TESTS 125b0d4adafSDavid Gow help 126b0d4adafSDavid Gow This builds the FAT KUnit tests 127b0d4adafSDavid Gow 128b0d4adafSDavid Gow For more information on KUnit and unit tests in general, please refer 129b0d4adafSDavid Gow to the KUnit documentation in Documentation/dev-tools/kunit 130b0d4adafSDavid Gow 131b0d4adafSDavid Gow If unsure, say N 132