1ec98c681SJan Engelhardtmenuconfig MTD 21da177e4SLinus Torvalds tristate "Memory Technology Device (MTD) support" 3e25df120SMartin Schwidefsky depends on HAS_IOMEM 41da177e4SLinus Torvalds help 51da177e4SLinus Torvalds Memory Technology Devices are flash, RAM and similar chips, often 61da177e4SLinus Torvalds used for solid state file systems on embedded devices. This option 71da177e4SLinus Torvalds will provide the generic support for MTD drivers to register 81da177e4SLinus Torvalds themselves with the kernel and for potential users of MTD devices 91da177e4SLinus Torvalds to enumerate the devices which are present and obtain a handle on 101da177e4SLinus Torvalds them. It will also allow you to select individual drivers for 111da177e4SLinus Torvalds particular hardware and users of MTD devices. If unsure, say N. 121da177e4SLinus Torvalds 13ec98c681SJan Engelhardtif MTD 14ec98c681SJan Engelhardt 151da177e4SLinus Torvaldsconfig MTD_DEBUG 161da177e4SLinus Torvalds bool "Debugging" 171da177e4SLinus Torvalds help 181da177e4SLinus Torvalds This turns on low-level debugging for the entire MTD sub-system. 191da177e4SLinus Torvalds Normally, you should say 'N'. 201da177e4SLinus Torvalds 211da177e4SLinus Torvaldsconfig MTD_DEBUG_VERBOSE 221da177e4SLinus Torvalds int "Debugging verbosity (0 = quiet, 3 = noisy)" 231da177e4SLinus Torvalds depends on MTD_DEBUG 241da177e4SLinus Torvalds default "0" 251da177e4SLinus Torvalds help 261da177e4SLinus Torvalds Determines the verbosity level of the MTD debugging messages. 271da177e4SLinus Torvalds 28*80f53da0SMike Frysingerconfig MTD_TESTS 29*80f53da0SMike Frysinger tristate "MTD tests support" 30*80f53da0SMike Frysinger depends on m 31*80f53da0SMike Frysinger help 32*80f53da0SMike Frysinger This option includes various MTD tests into compilation. The tests 33*80f53da0SMike Frysinger should normally be compiled as kernel modules. The modules perform 34*80f53da0SMike Frysinger various checks and verifications when loaded. 35*80f53da0SMike Frysinger 361da177e4SLinus Torvaldsconfig MTD_CONCAT 371da177e4SLinus Torvalds tristate "MTD concatenating support" 381da177e4SLinus Torvalds help 391da177e4SLinus Torvalds Support for concatenating several MTD devices into a single 401da177e4SLinus Torvalds (virtual) one. This allows you to have -for example- a JFFS(2) 411da177e4SLinus Torvalds file system spanning multiple physical flash chips. If unsure, 421da177e4SLinus Torvalds say 'Y'. 431da177e4SLinus Torvalds 441da177e4SLinus Torvaldsconfig MTD_PARTITIONS 451da177e4SLinus Torvalds bool "MTD partitioning support" 461da177e4SLinus Torvalds help 471da177e4SLinus Torvalds If you have a device which needs to divide its flash chip(s) up 481da177e4SLinus Torvalds into multiple 'partitions', each of which appears to the user as 491da177e4SLinus Torvalds a separate MTD device, you require this option to be enabled. If 501da177e4SLinus Torvalds unsure, say 'Y'. 511da177e4SLinus Torvalds 521da177e4SLinus Torvalds Note, however, that you don't need this option for the DiskOnChip 531da177e4SLinus Torvalds devices. Partitioning on NFTL 'devices' is a different - that's the 541da177e4SLinus Torvalds 'normal' form of partitioning used on a block device. 551da177e4SLinus Torvalds 561da177e4SLinus Torvaldsconfig MTD_REDBOOT_PARTS 571da177e4SLinus Torvalds tristate "RedBoot partition table parsing" 581da177e4SLinus Torvalds depends on MTD_PARTITIONS 591da177e4SLinus Torvalds ---help--- 601da177e4SLinus Torvalds RedBoot is a ROM monitor and bootloader which deals with multiple 611da177e4SLinus Torvalds 'images' in flash devices by putting a table one of the erase 621da177e4SLinus Torvalds blocks on the device, similar to a partition table, which gives 631da177e4SLinus Torvalds the offsets, lengths and names of all the images stored in the 641da177e4SLinus Torvalds flash. 651da177e4SLinus Torvalds 661da177e4SLinus Torvalds If you need code which can detect and parse this table, and register 671da177e4SLinus Torvalds MTD 'partitions' corresponding to each image in the table, enable 681da177e4SLinus Torvalds this option. 691da177e4SLinus Torvalds 701da177e4SLinus Torvalds You will still need the parsing functions to be called by the driver 711da177e4SLinus Torvalds for your particular device. It won't happen automatically. The 721da177e4SLinus Torvalds SA1100 map driver (CONFIG_MTD_SA1100) has an option for this, for 731da177e4SLinus Torvalds example. 741da177e4SLinus Torvalds 751da177e4SLinus Torvaldsconfig MTD_REDBOOT_DIRECTORY_BLOCK 761da177e4SLinus Torvalds int "Location of RedBoot partition table" 771da177e4SLinus Torvalds depends on MTD_REDBOOT_PARTS 781da177e4SLinus Torvalds default "-1" 791da177e4SLinus Torvalds ---help--- 801da177e4SLinus Torvalds This option is the Linux counterpart to the 811da177e4SLinus Torvalds CYGNUM_REDBOOT_FIS_DIRECTORY_BLOCK RedBoot compile time 821da177e4SLinus Torvalds option. 831da177e4SLinus Torvalds 841da177e4SLinus Torvalds The option specifies which Flash sectors holds the RedBoot 854992a9e8SEgry Gábor partition table. A zero or positive value gives an absolute 861da177e4SLinus Torvalds erase block number. A negative value specifies a number of 871da177e4SLinus Torvalds sectors before the end of the device. 881da177e4SLinus Torvalds 891da177e4SLinus Torvalds For example "2" means block number 2, "-1" means the last 901da177e4SLinus Torvalds block and "-2" means the penultimate block. 911da177e4SLinus Torvalds 921da177e4SLinus Torvaldsconfig MTD_REDBOOT_PARTS_UNALLOCATED 931da177e4SLinus Torvalds bool "Include unallocated flash regions" 941da177e4SLinus Torvalds depends on MTD_REDBOOT_PARTS 951da177e4SLinus Torvalds help 961da177e4SLinus Torvalds If you need to register each unallocated flash region as a MTD 971da177e4SLinus Torvalds 'partition', enable this option. 981da177e4SLinus Torvalds 991da177e4SLinus Torvaldsconfig MTD_REDBOOT_PARTS_READONLY 1001da177e4SLinus Torvalds bool "Force read-only for RedBoot system images" 1011da177e4SLinus Torvalds depends on MTD_REDBOOT_PARTS 1021da177e4SLinus Torvalds help 1031da177e4SLinus Torvalds If you need to force read-only for 'RedBoot', 'RedBoot Config' and 1041da177e4SLinus Torvalds 'FIS directory' images, enable this option. 1051da177e4SLinus Torvalds 1061da177e4SLinus Torvaldsconfig MTD_CMDLINE_PARTS 1071da177e4SLinus Torvalds bool "Command line partition table parsing" 108892e4fbaSDavid Woodhouse depends on MTD_PARTITIONS = "y" && MTD = "y" 1091da177e4SLinus Torvalds ---help--- 1104992a9e8SEgry Gábor Allow generic configuration of the MTD partition tables via the kernel 1111da177e4SLinus Torvalds command line. Multiple flash resources are supported for hardware where 1121da177e4SLinus Torvalds different kinds of flash memory are available. 1131da177e4SLinus Torvalds 1141da177e4SLinus Torvalds You will still need the parsing functions to be called by the driver 1151da177e4SLinus Torvalds for your particular device. It won't happen automatically. The 1161da177e4SLinus Torvalds SA1100 map driver (CONFIG_MTD_SA1100) has an option for this, for 1171da177e4SLinus Torvalds example. 1181da177e4SLinus Torvalds 1191da177e4SLinus Torvalds The format for the command line is as follows: 1201da177e4SLinus Torvalds 1211da177e4SLinus Torvalds mtdparts=<mtddef>[;<mtddef] 1221da177e4SLinus Torvalds <mtddef> := <mtd-id>:<partdef>[,<partdef>] 1231da177e4SLinus Torvalds <partdef> := <size>[@offset][<name>][ro] 1241da177e4SLinus Torvalds <mtd-id> := unique id used in mapping driver/device 1251da177e4SLinus Torvalds <size> := standard linux memsize OR "-" to denote all 1261da177e4SLinus Torvalds remaining space 1271da177e4SLinus Torvalds <name> := (NAME) 1281da177e4SLinus Torvalds 1291da177e4SLinus Torvalds Due to the way Linux handles the command line, no spaces are 1301da177e4SLinus Torvalds allowed in the partition definition, including mtd id's and partition 1311da177e4SLinus Torvalds names. 1321da177e4SLinus Torvalds 1331da177e4SLinus Torvalds Examples: 1341da177e4SLinus Torvalds 1351da177e4SLinus Torvalds 1 flash resource (mtd-id "sa1100"), with 1 single writable partition: 1361da177e4SLinus Torvalds mtdparts=sa1100:- 1371da177e4SLinus Torvalds 1381da177e4SLinus Torvalds Same flash, but 2 named partitions, the first one being read-only: 1391da177e4SLinus Torvalds mtdparts=sa1100:256k(ARMboot)ro,-(root) 1401da177e4SLinus Torvalds 1411da177e4SLinus Torvalds If unsure, say 'N'. 1421da177e4SLinus Torvalds 1431da177e4SLinus Torvaldsconfig MTD_AFS_PARTS 1441da177e4SLinus Torvalds tristate "ARM Firmware Suite partition parsing" 1451da177e4SLinus Torvalds depends on ARM && MTD_PARTITIONS 1461da177e4SLinus Torvalds ---help--- 1471da177e4SLinus Torvalds The ARM Firmware Suite allows the user to divide flash devices into 1481da177e4SLinus Torvalds multiple 'images'. Each such image has a header containing its name 1491da177e4SLinus Torvalds and offset/size etc. 1501da177e4SLinus Torvalds 1511da177e4SLinus Torvalds If you need code which can detect and parse these tables, and 1521da177e4SLinus Torvalds register MTD 'partitions' corresponding to each image detected, 1531da177e4SLinus Torvalds enable this option. 1541da177e4SLinus Torvalds 1551da177e4SLinus Torvalds You will still need the parsing functions to be called by the driver 1561da177e4SLinus Torvalds for your particular device. It won't happen automatically. The 1570b1b51f5SPaulius Zaleckas 'armflash' map driver (CONFIG_MTD_ARM_INTEGRATOR) does this, for 1580b1b51f5SPaulius Zaleckas example. 1591da177e4SLinus Torvalds 1609a310d21SScott Woodconfig MTD_OF_PARTS 1619a310d21SScott Wood tristate "Flash partition map based on OF description" 1629a310d21SScott Wood depends on PPC_OF && MTD_PARTITIONS 1639a310d21SScott Wood help 1649a310d21SScott Wood This provides a partition parsing function which derives 1659a310d21SScott Wood the partition map from the children of the flash node, 1669a310d21SScott Wood as described in Documentation/powerpc/booting-without-of.txt. 1679a310d21SScott Wood 168f0797881SMatteo Croceconfig MTD_AR7_PARTS 169f0797881SMatteo Croce tristate "TI AR7 partitioning support" 170f0797881SMatteo Croce depends on MTD_PARTITIONS 171f0797881SMatteo Croce ---help--- 172f0797881SMatteo Croce TI AR7 partitioning support 173f0797881SMatteo Croce 1741da177e4SLinus Torvaldscomment "User Modules And Translation Layers" 1751da177e4SLinus Torvalds 1761da177e4SLinus Torvaldsconfig MTD_CHAR 1771da177e4SLinus Torvalds tristate "Direct char device access to MTD devices" 1781da177e4SLinus Torvalds help 1791da177e4SLinus Torvalds This provides a character device for each MTD device present in 1801da177e4SLinus Torvalds the system, allowing the user to read and write directly to the 1811da177e4SLinus Torvalds memory chips, and also use ioctl() to obtain information about 1821da177e4SLinus Torvalds the device, or to erase parts of it. 1831da177e4SLinus Torvalds 18434a82443SDavid Brownellconfig HAVE_MTD_OTP 18534a82443SDavid Brownell bool 18634a82443SDavid Brownell help 18734a82443SDavid Brownell Enable access to OTP regions using MTD_CHAR. 18834a82443SDavid Brownell 189f6a7ecb1SJosh Boyerconfig MTD_BLKDEVS 190f6a7ecb1SJosh Boyer tristate "Common interface to block layer for MTD 'translation layers'" 191ec98c681SJan Engelhardt depends on BLOCK 192f6a7ecb1SJosh Boyer default n 193f6a7ecb1SJosh Boyer 1941da177e4SLinus Torvaldsconfig MTD_BLOCK 1951da177e4SLinus Torvalds tristate "Caching block device access to MTD devices" 196ec98c681SJan Engelhardt depends on BLOCK 197f6a7ecb1SJosh Boyer select MTD_BLKDEVS 1981da177e4SLinus Torvalds ---help--- 1991da177e4SLinus Torvalds Although most flash chips have an erase size too large to be useful 2001da177e4SLinus Torvalds as block devices, it is possible to use MTD devices which are based 2011da177e4SLinus Torvalds on RAM chips in this manner. This block device is a user of MTD 2021da177e4SLinus Torvalds devices performing that function. 2031da177e4SLinus Torvalds 2041da177e4SLinus Torvalds At the moment, it is also required for the Journalling Flash File 2051da177e4SLinus Torvalds System(s) to obtain a handle on the MTD device when it's mounted 2061da177e4SLinus Torvalds (although JFFS and JFFS2 don't actually use any of the functionality 2071da177e4SLinus Torvalds of the mtdblock device). 2081da177e4SLinus Torvalds 2091da177e4SLinus Torvalds Later, it may be extended to perform read/erase/modify/write cycles 2101da177e4SLinus Torvalds on flash chips to emulate a smaller block size. Needless to say, 2111da177e4SLinus Torvalds this is very unsafe, but could be useful for file systems which are 2121da177e4SLinus Torvalds almost never written to. 2131da177e4SLinus Torvalds 2141da177e4SLinus Torvalds You do not need this option for use with the DiskOnChip devices. For 2151da177e4SLinus Torvalds those, enable NFTL support (CONFIG_NFTL) instead. 2161da177e4SLinus Torvalds 2171da177e4SLinus Torvaldsconfig MTD_BLOCK_RO 2181da177e4SLinus Torvalds tristate "Readonly block device access to MTD devices" 219ec98c681SJan Engelhardt depends on MTD_BLOCK!=y && BLOCK 220f6a7ecb1SJosh Boyer select MTD_BLKDEVS 2211da177e4SLinus Torvalds help 2221da177e4SLinus Torvalds This allows you to mount read-only file systems (such as cramfs) 2231da177e4SLinus Torvalds from an MTD device, without the overhead (and danger) of the caching 2241da177e4SLinus Torvalds driver. 2251da177e4SLinus Torvalds 2261da177e4SLinus Torvalds You do not need this option for use with the DiskOnChip devices. For 2271da177e4SLinus Torvalds those, enable NFTL support (CONFIG_NFTL) instead. 2281da177e4SLinus Torvalds 2291da177e4SLinus Torvaldsconfig FTL 2301da177e4SLinus Torvalds tristate "FTL (Flash Translation Layer) support" 231ec98c681SJan Engelhardt depends on BLOCK 232f6a7ecb1SJosh Boyer select MTD_BLKDEVS 2331da177e4SLinus Torvalds ---help--- 2341da177e4SLinus Torvalds This provides support for the original Flash Translation Layer which 2351da177e4SLinus Torvalds is part of the PCMCIA specification. It uses a kind of pseudo- 2361da177e4SLinus Torvalds file system on a flash device to emulate a block device with 2371da177e4SLinus Torvalds 512-byte sectors, on top of which you put a 'normal' file system. 2381da177e4SLinus Torvalds 2391da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 2401da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 2411da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on PCMCIA 2421da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 2431da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 2441da177e4SLinus Torvalds not use it. 2451da177e4SLinus Torvalds 2461da177e4SLinus Torvaldsconfig NFTL 2471da177e4SLinus Torvalds tristate "NFTL (NAND Flash Translation Layer) support" 248ec98c681SJan Engelhardt depends on BLOCK 249f6a7ecb1SJosh Boyer select MTD_BLKDEVS 2501da177e4SLinus Torvalds ---help--- 2511da177e4SLinus Torvalds This provides support for the NAND Flash Translation Layer which is 2521da177e4SLinus Torvalds used on M-Systems' DiskOnChip devices. It uses a kind of pseudo- 2531da177e4SLinus Torvalds file system on a flash device to emulate a block device with 2541da177e4SLinus Torvalds 512-byte sectors, on top of which you put a 'normal' file system. 2551da177e4SLinus Torvalds 2561da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 2571da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 2581da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on DiskOnChip 2591da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 2601da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 2611da177e4SLinus Torvalds not use it. 2621da177e4SLinus Torvalds 2631da177e4SLinus Torvaldsconfig NFTL_RW 2641da177e4SLinus Torvalds bool "Write support for NFTL" 2651da177e4SLinus Torvalds depends on NFTL 2661da177e4SLinus Torvalds help 2671da177e4SLinus Torvalds Support for writing to the NAND Flash Translation Layer, as used 2681da177e4SLinus Torvalds on the DiskOnChip. 2691da177e4SLinus Torvalds 2701da177e4SLinus Torvaldsconfig INFTL 2711da177e4SLinus Torvalds tristate "INFTL (Inverse NAND Flash Translation Layer) support" 272ec98c681SJan Engelhardt depends on BLOCK 273f6a7ecb1SJosh Boyer select MTD_BLKDEVS 2741da177e4SLinus Torvalds ---help--- 2751da177e4SLinus Torvalds This provides support for the Inverse NAND Flash Translation 2761da177e4SLinus Torvalds Layer which is used on M-Systems' newer DiskOnChip devices. It 2771da177e4SLinus Torvalds uses a kind of pseudo-file system on a flash device to emulate 2781da177e4SLinus Torvalds a block device with 512-byte sectors, on top of which you put 2791da177e4SLinus Torvalds a 'normal' file system. 2801da177e4SLinus Torvalds 2811da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 2821da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 2831da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on DiskOnChip 2841da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 2851da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 2861da177e4SLinus Torvalds not use it. 2871da177e4SLinus Torvalds 288e27a9960SSean Youngconfig RFD_FTL 289e27a9960SSean Young tristate "Resident Flash Disk (Flash Translation Layer) support" 290ec98c681SJan Engelhardt depends on BLOCK 291f6a7ecb1SJosh Boyer select MTD_BLKDEVS 292e27a9960SSean Young ---help--- 293e27a9960SSean Young This provides support for the flash translation layer known 294e27a9960SSean Young as the Resident Flash Disk (RFD), as used by the Embedded BIOS 295cd5f6346SKyungmin Park of General Software. There is a blurb at: 296cd5f6346SKyungmin Park 297cd5f6346SKyungmin Park http://www.gensw.com/pages/prod/bios/rfd.htm 298e27a9960SSean Young 29951197abfSClaudio Lanconelliconfig SSFDC 300892e4fbaSDavid Woodhouse tristate "NAND SSFDC (SmartMedia) read only translation layer" 301ec98c681SJan Engelhardt depends on BLOCK 302f6a7ecb1SJosh Boyer select MTD_BLKDEVS 30351197abfSClaudio Lanconelli help 30451197abfSClaudio Lanconelli This enables read only access to SmartMedia formatted NAND 30551197abfSClaudio Lanconelli flash. You can mount it with FAT file system. 30651197abfSClaudio Lanconelli 3074b23aff0SRichard Purdieconfig MTD_OOPS 3084b23aff0SRichard Purdie tristate "Log panic/oops to an MTD buffer" 3094b23aff0SRichard Purdie depends on MTD 3104b23aff0SRichard Purdie help 3114b23aff0SRichard Purdie This enables panic and oops messages to be logged to a circular 3124b23aff0SRichard Purdie buffer in a flash partition where it can be read back at some 3134b23aff0SRichard Purdie later point. 3144b23aff0SRichard Purdie 315256331d5SPeter Korsgaard To use, add console=ttyMTDx to the kernel command line, 316256331d5SPeter Korsgaard where x is the MTD device number to use. 317256331d5SPeter Korsgaard 3181da177e4SLinus Torvaldssource "drivers/mtd/chips/Kconfig" 3191da177e4SLinus Torvalds 3201da177e4SLinus Torvaldssource "drivers/mtd/maps/Kconfig" 3211da177e4SLinus Torvalds 3221da177e4SLinus Torvaldssource "drivers/mtd/devices/Kconfig" 3231da177e4SLinus Torvalds 3241da177e4SLinus Torvaldssource "drivers/mtd/nand/Kconfig" 3251da177e4SLinus Torvalds 326cd5f6346SKyungmin Parksource "drivers/mtd/onenand/Kconfig" 327cd5f6346SKyungmin Park 32860f26520SAlexey Korolevsource "drivers/mtd/lpddr/Kconfig" 32960f26520SAlexey Korolev 330801c135cSArtem B. Bityutskiysource "drivers/mtd/ubi/Kconfig" 331801c135cSArtem B. Bityutskiy 332ec98c681SJan Engelhardtendif # MTD 333