1ec98c681SJan Engelhardtmenuconfig MTD 21da177e4SLinus Torvalds tristate "Memory Technology Device (MTD) support" 3c4dfa25aSAlban Bedel imply NVMEM 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 1580f53da0SMike Frysingerconfig MTD_TESTS 1648e546b7SWolfram Sang tristate "MTD tests support (DANGEROUS)" 1780f53da0SMike Frysinger depends on m 1880f53da0SMike Frysinger help 1980f53da0SMike Frysinger This option includes various MTD tests into compilation. The tests 2080f53da0SMike Frysinger should normally be compiled as kernel modules. The modules perform 2180f53da0SMike Frysinger various checks and verifications when loaded. 2280f53da0SMike Frysinger 2348e546b7SWolfram Sang WARNING: some of the tests will ERASE entire MTD device which they 2448e546b7SWolfram Sang test. Do not use these tests unless you really know what you do. 2548e546b7SWolfram Sang 261da177e4SLinus Torvaldsconfig MTD_CMDLINE_PARTS 27f5f172dcSLubomir Rintel tristate "Command line partition table parsing" 28f5f172dcSLubomir Rintel depends on MTD 29a8222a84SBoris Brezillon help 304992a9e8SEgry Gábor Allow generic configuration of the MTD partition tables via the kernel 311da177e4SLinus Torvalds command line. Multiple flash resources are supported for hardware where 321da177e4SLinus Torvalds different kinds of flash memory are available. 331da177e4SLinus Torvalds 341da177e4SLinus Torvalds You will still need the parsing functions to be called by the driver 351da177e4SLinus Torvalds for your particular device. It won't happen automatically. The 361da177e4SLinus Torvalds SA1100 map driver (CONFIG_MTD_SA1100) has an option for this, for 371da177e4SLinus Torvalds example. 381da177e4SLinus Torvalds 391da177e4SLinus Torvalds The format for the command line is as follows: 401da177e4SLinus Torvalds 411da177e4SLinus Torvalds mtdparts=<mtddef>[;<mtddef] 421da177e4SLinus Torvalds <mtddef> := <mtd-id>:<partdef>[,<partdef>] 431da177e4SLinus Torvalds <partdef> := <size>[@offset][<name>][ro] 441da177e4SLinus Torvalds <mtd-id> := unique id used in mapping driver/device 451da177e4SLinus Torvalds <size> := standard linux memsize OR "-" to denote all 461da177e4SLinus Torvalds remaining space 471da177e4SLinus Torvalds <name> := (NAME) 481da177e4SLinus Torvalds 491da177e4SLinus Torvalds Due to the way Linux handles the command line, no spaces are 501da177e4SLinus Torvalds allowed in the partition definition, including mtd id's and partition 511da177e4SLinus Torvalds names. 521da177e4SLinus Torvalds 531da177e4SLinus Torvalds Examples: 541da177e4SLinus Torvalds 551da177e4SLinus Torvalds 1 flash resource (mtd-id "sa1100"), with 1 single writable partition: 561da177e4SLinus Torvalds mtdparts=sa1100:- 571da177e4SLinus Torvalds 581da177e4SLinus Torvalds Same flash, but 2 named partitions, the first one being read-only: 591da177e4SLinus Torvalds mtdparts=sa1100:256k(ARMboot)ro,-(root) 601da177e4SLinus Torvalds 611da177e4SLinus Torvalds If unsure, say 'N'. 621da177e4SLinus Torvalds 639a310d21SScott Woodconfig MTD_OF_PARTS 64d6137badSDmitry Eremin-Solenikov tristate "OpenFirmware partitioning information support" 652e929d00SFrank Svendsboe default y 66b7b6e08fSGrant Likely depends on OF 679a310d21SScott Wood help 689a310d21SScott Wood This provides a partition parsing function which derives 699a310d21SScott Wood the partition map from the children of the flash node, 70e7606446SMichal Sojka as described in Documentation/devicetree/bindings/mtd/partition.txt. 719a310d21SScott Wood 72f0797881SMatteo Croceconfig MTD_AR7_PARTS 73f0797881SMatteo Croce tristate "TI AR7 partitioning support" 74a8222a84SBoris Brezillon help 75f0797881SMatteo Croce TI AR7 partitioning support 76f0797881SMatteo Croce 7770a3c167SJonas Gorskiconfig MTD_BCM63XX_PARTS 7870a3c167SJonas Gorski tristate "BCM63XX CFE partitioning support" 79436e94a6SSimon Arlott depends on BCM63XX || BMIPS_GENERIC || COMPILE_TEST 8070a3c167SJonas Gorski select CRC32 81*dd84cb02SJonas Gorski select MTD_PARSER_IMAGETAG 8270a3c167SJonas Gorski help 8381d9e98fSColin Ian King This provides partition parsing for BCM63xx devices with CFE 8470a3c167SJonas Gorski bootloaders. 8570a3c167SJonas Gorski 863cf7f131SRafał Miłeckiconfig MTD_BCM47XX_PARTS 873cf7f131SRafał Miłecki tristate "BCM47XX partitioning support" 889e3afa5fSRafał Miłecki depends on BCM47XX || ARCH_BCM_5301X 893cf7f131SRafał Miłecki help 903cf7f131SRafał Miłecki This provides partitions parser for devices based on BCM47xx 913cf7f131SRafał Miłecki boards. 923cf7f131SRafał Miłecki 9399352afeSRafał Miłeckimenu "Partition parsers" 9499352afeSRafał Miłeckisource "drivers/mtd/parsers/Kconfig" 9599352afeSRafał Miłeckiendmenu 9699352afeSRafał Miłecki 971da177e4SLinus Torvaldscomment "User Modules And Translation Layers" 981da177e4SLinus Torvalds 997f11b4d4SEzequiel Garcia# 1007f11b4d4SEzequiel Garcia# MTD block device support is select'ed if needed 1017f11b4d4SEzequiel Garcia# 102f6a7ecb1SJosh Boyerconfig MTD_BLKDEVS 1037f11b4d4SEzequiel Garcia tristate 104f6a7ecb1SJosh Boyer 1051da177e4SLinus Torvaldsconfig MTD_BLOCK 1061da177e4SLinus Torvalds tristate "Caching block device access to MTD devices" 107ec98c681SJan Engelhardt depends on BLOCK 108f6a7ecb1SJosh Boyer select MTD_BLKDEVS 109a8222a84SBoris Brezillon help 1101da177e4SLinus Torvalds Although most flash chips have an erase size too large to be useful 1111da177e4SLinus Torvalds as block devices, it is possible to use MTD devices which are based 1121da177e4SLinus Torvalds on RAM chips in this manner. This block device is a user of MTD 1131da177e4SLinus Torvalds devices performing that function. 1141da177e4SLinus Torvalds 1151da177e4SLinus Torvalds At the moment, it is also required for the Journalling Flash File 1161da177e4SLinus Torvalds System(s) to obtain a handle on the MTD device when it's mounted 1171da177e4SLinus Torvalds (although JFFS and JFFS2 don't actually use any of the functionality 1181da177e4SLinus Torvalds of the mtdblock device). 1191da177e4SLinus Torvalds 1201da177e4SLinus Torvalds Later, it may be extended to perform read/erase/modify/write cycles 1211da177e4SLinus Torvalds on flash chips to emulate a smaller block size. Needless to say, 1221da177e4SLinus Torvalds this is very unsafe, but could be useful for file systems which are 1231da177e4SLinus Torvalds almost never written to. 1241da177e4SLinus Torvalds 1251da177e4SLinus Torvalds You do not need this option for use with the DiskOnChip devices. For 1261da177e4SLinus Torvalds those, enable NFTL support (CONFIG_NFTL) instead. 1271da177e4SLinus Torvalds 1281da177e4SLinus Torvaldsconfig MTD_BLOCK_RO 1291da177e4SLinus Torvalds tristate "Readonly block device access to MTD devices" 130ec98c681SJan Engelhardt depends on MTD_BLOCK!=y && BLOCK 131f6a7ecb1SJosh Boyer select MTD_BLKDEVS 1321da177e4SLinus Torvalds help 1331da177e4SLinus Torvalds This allows you to mount read-only file systems (such as cramfs) 1341da177e4SLinus Torvalds from an MTD device, without the overhead (and danger) of the caching 1351da177e4SLinus Torvalds driver. 1361da177e4SLinus Torvalds 1371da177e4SLinus Torvalds You do not need this option for use with the DiskOnChip devices. For 1381da177e4SLinus Torvalds those, enable NFTL support (CONFIG_NFTL) instead. 1391da177e4SLinus Torvalds 1401da177e4SLinus Torvaldsconfig FTL 1411da177e4SLinus Torvalds tristate "FTL (Flash Translation Layer) support" 142ec98c681SJan Engelhardt depends on BLOCK 143f6a7ecb1SJosh Boyer select MTD_BLKDEVS 144a8222a84SBoris Brezillon help 1451da177e4SLinus Torvalds This provides support for the original Flash Translation Layer which 1461da177e4SLinus Torvalds is part of the PCMCIA specification. It uses a kind of pseudo- 1471da177e4SLinus Torvalds file system on a flash device to emulate a block device with 1481da177e4SLinus Torvalds 512-byte sectors, on top of which you put a 'normal' file system. 1491da177e4SLinus Torvalds 1501da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 1511da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 1521da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on PCMCIA 1531da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 1541da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 1551da177e4SLinus Torvalds not use it. 1561da177e4SLinus Torvalds 1571da177e4SLinus Torvaldsconfig NFTL 1581da177e4SLinus Torvalds tristate "NFTL (NAND Flash Translation Layer) support" 159ec98c681SJan Engelhardt depends on BLOCK 160f6a7ecb1SJosh Boyer select MTD_BLKDEVS 161a8222a84SBoris Brezillon help 1621da177e4SLinus Torvalds This provides support for the NAND Flash Translation Layer which is 1631da177e4SLinus Torvalds used on M-Systems' DiskOnChip devices. It uses a kind of pseudo- 1641da177e4SLinus Torvalds file system on a flash device to emulate a block device with 1651da177e4SLinus Torvalds 512-byte sectors, on top of which you put a 'normal' file system. 1661da177e4SLinus Torvalds 1671da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 1681da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 1691da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on DiskOnChip 1701da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 1711da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 1721da177e4SLinus Torvalds not use it. 1731da177e4SLinus Torvalds 1741da177e4SLinus Torvaldsconfig NFTL_RW 1751da177e4SLinus Torvalds bool "Write support for NFTL" 1761da177e4SLinus Torvalds depends on NFTL 1771da177e4SLinus Torvalds help 1781da177e4SLinus Torvalds Support for writing to the NAND Flash Translation Layer, as used 1791da177e4SLinus Torvalds on the DiskOnChip. 1801da177e4SLinus Torvalds 1811da177e4SLinus Torvaldsconfig INFTL 1821da177e4SLinus Torvalds tristate "INFTL (Inverse NAND Flash Translation Layer) support" 183ec98c681SJan Engelhardt depends on BLOCK 184f6a7ecb1SJosh Boyer select MTD_BLKDEVS 185a8222a84SBoris Brezillon help 1861da177e4SLinus Torvalds This provides support for the Inverse NAND Flash Translation 1871da177e4SLinus Torvalds Layer which is used on M-Systems' newer DiskOnChip devices. It 1881da177e4SLinus Torvalds uses a kind of pseudo-file system on a flash device to emulate 1891da177e4SLinus Torvalds a block device with 512-byte sectors, on top of which you put 1901da177e4SLinus Torvalds a 'normal' file system. 1911da177e4SLinus Torvalds 1921da177e4SLinus Torvalds You may find that the algorithms used in this code are patented 1931da177e4SLinus Torvalds unless you live in the Free World where software patents aren't 1941da177e4SLinus Torvalds legal - in the USA you are only permitted to use this on DiskOnChip 1951da177e4SLinus Torvalds hardware, although under the terms of the GPL you're obviously 1961da177e4SLinus Torvalds permitted to copy, modify and distribute the code as you wish. Just 1971da177e4SLinus Torvalds not use it. 1981da177e4SLinus Torvalds 199e27a9960SSean Youngconfig RFD_FTL 200e27a9960SSean Young tristate "Resident Flash Disk (Flash Translation Layer) support" 201ec98c681SJan Engelhardt depends on BLOCK 202f6a7ecb1SJosh Boyer select MTD_BLKDEVS 203a8222a84SBoris Brezillon help 204e27a9960SSean Young This provides support for the flash translation layer known 205e27a9960SSean Young as the Resident Flash Disk (RFD), as used by the Embedded BIOS 206cd5f6346SKyungmin Park of General Software. There is a blurb at: 207cd5f6346SKyungmin Park 208cd5f6346SKyungmin Park http://www.gensw.com/pages/prod/bios/rfd.htm 209e27a9960SSean Young 21051197abfSClaudio Lanconelliconfig SSFDC 211892e4fbaSDavid Woodhouse tristate "NAND SSFDC (SmartMedia) read only translation layer" 212ec98c681SJan Engelhardt depends on BLOCK 213f6a7ecb1SJosh Boyer select MTD_BLKDEVS 21451197abfSClaudio Lanconelli help 21551197abfSClaudio Lanconelli This enables read only access to SmartMedia formatted NAND 21651197abfSClaudio Lanconelli flash. You can mount it with FAT file system. 21751197abfSClaudio Lanconelli 2187d17c02aSMaxim Levitskyconfig SM_FTL 2197d17c02aSMaxim Levitsky tristate "SmartMedia/xD new translation layer" 2206372680cSKees Cook depends on BLOCK 2217d17c02aSMaxim Levitsky select MTD_BLKDEVS 2229bb94643SMiquel Raynal select MTD_NAND_ECC_SW_HAMMING 2237d17c02aSMaxim Levitsky help 2246f92355cSMaxim Levitsky This enables EXPERIMENTAL R/W support for SmartMedia/xD 2257de6f798SDavid Woodhouse FTL (Flash translation layer). 2266f92355cSMaxim Levitsky Write support is only lightly tested, therefore this driver 2276f92355cSMaxim Levitsky isn't recommended to use with valuable data (anyway if you have 2286f92355cSMaxim Levitsky valuable data, do backups regardless of software/hardware you 2296f92355cSMaxim Levitsky use, because you never know what will eat your data...) 2306f92355cSMaxim Levitsky If you only need R/O access, you can use older R/O driver 2316f92355cSMaxim Levitsky (CONFIG_SSFDC) 2327d17c02aSMaxim Levitsky 2334b23aff0SRichard Purdieconfig MTD_OOPS 2344b23aff0SRichard Purdie tristate "Log panic/oops to an MTD buffer" 2354b23aff0SRichard Purdie help 2364b23aff0SRichard Purdie This enables panic and oops messages to be logged to a circular 2374b23aff0SRichard Purdie buffer in a flash partition where it can be read back at some 2384b23aff0SRichard Purdie later point. 2394b23aff0SRichard Purdie 240a3215902SJarkko Lavinenconfig MTD_SWAP 241a3215902SJarkko Lavinen tristate "Swap on MTD device support" 242a3215902SJarkko Lavinen depends on MTD && SWAP 243a3215902SJarkko Lavinen select MTD_BLKDEVS 244a3215902SJarkko Lavinen help 245a3215902SJarkko Lavinen Provides volatile block device driver on top of mtd partition 246a3215902SJarkko Lavinen suitable for swapping. The mapping of written blocks is not saved. 247a3215902SJarkko Lavinen The driver provides wear leveling by storing erase counter into the 248a3215902SJarkko Lavinen OOB. 249a3215902SJarkko Lavinen 250727dc612SDan Ehrenbergconfig MTD_PARTITIONED_MASTER 251727dc612SDan Ehrenberg bool "Retain master device when partitioned" 252727dc612SDan Ehrenberg default n 253727dc612SDan Ehrenberg depends on MTD 254727dc612SDan Ehrenberg help 255727dc612SDan Ehrenberg For historical reasons, by default, either a master is present or 256727dc612SDan Ehrenberg several partitions are present, but not both. The concern was that 257727dc612SDan Ehrenberg data listed in multiple partitions was dangerous; however, SCSI does 258727dc612SDan Ehrenberg this and it is frequently useful for applications. This config option 259727dc612SDan Ehrenberg leaves the master in even if the device is partitioned. It also makes 260727dc612SDan Ehrenberg the parent of the partition device be the master device, rather than 261727dc612SDan Ehrenberg what lies behind the master. 262727dc612SDan Ehrenberg 2631da177e4SLinus Torvaldssource "drivers/mtd/chips/Kconfig" 2641da177e4SLinus Torvalds 2651da177e4SLinus Torvaldssource "drivers/mtd/maps/Kconfig" 2661da177e4SLinus Torvalds 2671da177e4SLinus Torvaldssource "drivers/mtd/devices/Kconfig" 2681da177e4SLinus Torvalds 2691da177e4SLinus Torvaldssource "drivers/mtd/nand/Kconfig" 2701da177e4SLinus Torvalds 27160f26520SAlexey Korolevsource "drivers/mtd/lpddr/Kconfig" 27260f26520SAlexey Korolev 273b199489dSHuang Shijiesource "drivers/mtd/spi-nor/Kconfig" 274b199489dSHuang Shijie 275801c135cSArtem B. Bityutskiysource "drivers/mtd/ubi/Kconfig" 276801c135cSArtem B. Bityutskiy 277ec98c681SJan Engelhardtendif # MTD 278