Lines Matching full:bbt
11 * depending on the options in the BBT descriptor(s). If no flash based BBT
13 * marked good / bad blocks. This information is used to create a memory BBT.
16 * If a flash based BBT is specified then the function first tries to find the
17 * BBT on flash. If a BBT is found then the contents are read and the memory
18 * based BBT is created. If a mirrored BBT is selected then the mirror is
20 * version number, then the mirror BBT is used to build the memory based BBT.
23 * If no BBT exists at all then the device is scanned for factory marked
27 * the BBT is searched and read but never created
46 * 10b: block is reserved (to protect the bbt area)
53 * - the space necessary for a bbt in FLASH does not exceed a block boundary
78 uint8_t entry = chip->bbt[block >> BBT_ENTRY_SHIFT]; in bbt_get_entry()
87 chip->bbt[block >> BBT_ENTRY_SHIFT] |= msk; in bbt_mark_entry()
138 * @td: BBT descriptor used for computation
160 * @num: the number of bbt descriptors to read
161 * @td: the bbt describtion table
186 * In case the BBT marker is not in the OOB area it in read_bbt()
196 pr_info("nand_bbt: ECC error in BBT at 0x%012llx\n", in read_bbt()
200 pr_info("nand_bbt: corrected error in BBT at 0x%012llx\n", in read_bbt()
204 pr_info("nand_bbt: error reading BBT\n"); in read_bbt()
257 * that the bbt bits are in consecutive order.
286 /* BBT marker is in the first page, no OOB */
387 * assume that the bbt bits are in consecutive order.
450 /* Check if a potential BBT block is marked as bad */
457 * No need to check for a bad BBT block if the BBM area overlaps with in bbt_block_checkbad()
546 * NAND_BBT_PERCHIP is given, each chip is searched for a bbt, which contains
550 * The bbt ident pattern resides in the oob area of the first page in a block.
572 /* Do we have a bbt per chip? */ in search_bbt()
609 /* Check, if we found a bbt for each requested chip */ in search_bbt()
642 * get_bbt_block - Get the first valid eraseblock suitable to store a BBT
644 * @td: the BBT description
645 * @md: the mirror BBT descriptor
649 * suitable to store a BBT (i.e. in the range reserved for BBT), or -ENOSPC if
706 * mark_bbt_block_bad - Mark one of the block reserved for BBT bad
708 * @td: the BBT description
710 * @block: the BBT block to mark
712 * Blocks reserved for BBT can become bad. This functions is an helper to mark
713 * such blocks as bad. It takes care of updating the in-memory BBT, marking the
844 /* Preset the bbt area with 0xff */ in write_bbt()
885 /* Do not store the reserved bbt blocks! */ in write_bbt()
894 pr_warn("nand_bbt: error while erasing BBT block %d\n", in write_bbt()
904 pr_warn("nand_bbt: error while writing BBT block %d\n", in write_bbt()
928 * The function creates a memory based bbt by scanning the device for
940 * check_create - [GENERIC] create and write bbt(s) if necessary
946 * / updates the bbt(s) if necessary. Creation is necessary if no bbt was found
958 /* Do we have a bbt per chip? */ in check_create()
1083 if (!this->bbt || !td) in nand_update_bbt()
1093 /* Do we have a bbt per chip? */ in nand_update_bbt()
1137 /* Do we have a bbt per chip? */ in mark_bbt_region()
1257 this->bbt = kzalloc(len, GFP_KERNEL); in nand_scan_bbt()
1258 if (!this->bbt) in nand_scan_bbt()
1267 pr_err("nand_bbt: can't scan flash and build the RAM-based BBT\n"); in nand_scan_bbt()
1284 /* Is the bbt at a given page? */ in nand_scan_bbt()
1296 /* Prevent the bbt regions from erasing / writing */ in nand_scan_bbt()
1307 kfree(this->bbt); in nand_scan_bbt()
1308 this->bbt = NULL; in nand_scan_bbt()
1318 /* Generic flash bbt descriptors */
1364 * nand_create_badblock_pattern - [INTERN] Creates a BBT descriptor structure
1455 pr_debug("nand_isbad_bbt(): bbt info for offs 0x%08x: (block %d) 0x%02x\n", in nand_isbad_bbt()
1473 * nand_markbad_bbt - [NAND Interface] Mark a block bad in the BBT