make creation of nand bad block table optional
Subsystems (2)
PATCH 1/1 make creation of nand bad block table optional
[PATCH] add new NAND_DONT_CRATE_BBT flag
This patch makes creation of the BBT optional.
It adds a new platform-independent NAND-wide flag NAND_DONT_CREATE_BBT
This flag can be used by the board_nand_init function of a board. It is used by the soon-to-be-submitted board support code for various openmoko products.
Signed-off-by Werner Almesberger <[email protected]>
Signed-off-by Harald Welte <[email protected]>
---
drivers/mtd/nand/nand_bbt.c +2 -1
@@ -678,7 +678,8 @@ static int check_create (struct mtd_info *mtd, uint8_t *buf, struct nand_bbt_des } create:/* Create the bad block table by scanning the device ? */ -if (!(td->options &NAND_BBT_CREATE )) +if (!(td->options &NAND_BBT_CREATE ) || + (this->options &NAND_DONT_CREATE_BBT ))continue ;/* Create the table in memory by scanning the chip(s) */
include/linux/mtd/nand.h +2 -1
@@ -187,7 +187,8 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_* This can only work if we have the ecc bytes directly behind the * data bytes. Applies for DOC and AG-AND Renesas HW Reed Solomon generators */ #define NAND_HWECC_SYNDROME 0x00020000 - +/* Do not create an BBT if none is found. Overrides NAND_BBT_CREATE. */ +#define NAND_DONT_CREATE_BBT 0x00040000/* Options set by nand scan */ /* Nand scan has allocated oob_buf */
Signature · 11 lines
- Harald Welte <[email protected]> http://laforge.gnumonks.org/ ============================================================================ "Privacy in residential applications is a desirable marketing option." (ETSI EN 300 175-7 Ch. A6) -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: Digital signature Url : http://lists.denx.de/pipermail/u-boot/attachments/20080706/3b23c75c/attachment.pgp
PATCH 1/1 make creation of nand bad block table optional
Quoted 5 lines · Harald Welte
[PATCH] add new
NAND_DONT_CRATE_BBTflagThis patch makes creation of the BBT optional.
It adds a new platform-independent NAND-wide flag
NAND_DONT_CREATE_BBT
The testing branch of u-boot-nand-flash already has NAND_SKIP_BBTSCAN.
Are the semantics of this any different?
-Scott