Linux – Print list of bad blocks in NAND flash from user space

badblocksflash-memorykernellinux

Is there any user space tool that can retrieve and dump the list of bad blocks in a NAND flash device? I've checked the mtdinfo command line utility, and also searched /proc and /sys, but couldn't find anything.

I am looking for something suitable for use from a shell script.

I could parse dmesg as the kernel prints bad block information on init, but I am hoping there will be a better way.

Best Answer

I have not been able to find any user space utility doing what I need. The closest I have found is the nanddump utility from mtd-utils, which can dump NAND contents, including bad blocks.

Related Question