The mtdblock driver is little used. Its purpose is to present flash memory as a block device you can use to format and mount as a filesystem. However, it has severe limitations because it does not handle bad blocks in NAND flash, it does not do wear leveling, and it does not handle the mismatch in size between filesystem blocks and flash erase blocks. In other words, it does not have a flash translation layer, which is essential for reliable file storage. The only case where the mtdblock device is useful is to mount read-only file systems such as Squashfs on top of reliable flash memory such as NOR.
The MTD block device, mtdblock
If you want a read-only filesystem on NAND flash, you should use the UBI driver, as described later in this chapter. ...
Get Mastering Embedded Linux Programming - Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.