Why would chip bad block?

Kind of bad blocks:
The first is at the factory have bad blocks, that is, you buy new, not used in the Nand Flash, it may contain a bad block. Such bad blocks have the factory, is referred to as factory (masked) bad block or initial bad / invalid block, prior to shipment, it will do the corresponding mark, marked as a bad block.
The second is the bad blocks during use, due to the long time use, when the wiper addition, wrong, a description of this block is bad, but also the program is running, it is found and marked as bad block. The position of the specific mark, same as above. Such a block is called worn-out bad block. I.e. worn out blocks

坏块标记:
NAND Flash坏块标记的位置三种情况:每个块的第1页、第1页和第2页、最后1页。对于小页(512Bytes大小),坏块标记是在OOB区域的第6个字节。对于大页(如2K大小),坏块标记是在OOB区域的第1个字节。如果坏块标记字节是0xff,则说明这个块是好块,否则就是坏块。
坏块管理:
在linux系统中会使用坏块表(BBT)对坏块进行管理。在加载NAND驱动时,如果你没有加入参数主动要求跳过坏块扫描,那么系统都会扫描坏块,并建立BBT。使用中可以通过BBT来查询某个块是否是坏块。使用过程中如果发现坏块,也需要更新BBT。坏块表有两种存放方式:第一种是存放在内存中,这就要求在每次系统上电后都要重新扫描一次NAND Flash,建立bbt。缺点是使系统启动速度变慢,优点是不需要占用NAND Flash空间。第二种是存放在NAND Flash中,这种方式就不需要在系统上电后重新扫描NAND Flash,只需要去读取就可以了

Guess you like

Origin blog.51cto.com/14601104/2449213