summaryrefslogtreecommitdiff
path: root/packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch
diff options
context:
space:
mode:
authorPaul Sokolovsky <pmiscml@gmail.com>2007-06-14 04:51:44 +0000
committerPaul Sokolovsky <pmiscml@gmail.com>2007-06-14 04:51:44 +0000
commit998f6f792ea953caf0ca7ab8b7fbe858d68a510f (patch)
tree90754e0b123fbf58fc099648a68eae3dda0f8004 /packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch
parent60dfd703b4c5180533ec14102c276fc4fb70a5a3 (diff)
parent1d4ca5c243ec65cf27ec1d4d908163da029e6fcc (diff)
merge of '443650a5c3bfafa4e922391b71d87087c6b6f355'
and 'a59cc92c385b66015a1eb53d505bf4f139187778'
Diffstat (limited to 'packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch')
-rw-r--r--packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch b/packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch
new file mode 100644
index 0000000000..d630889e3c
--- /dev/null
+++ b/packages/uboot/u-boot-mkimage-gta01-native/uboot-nand-markbad-reallybad.patch
@@ -0,0 +1,20 @@
+This patch makes sure that the 'nand markbad' command does not only mark a block
+'bad' in the bad-block table, but _also_ marks it bad in the OOB area.
+
+we need this to preserve the bad block status when re-creating the bad block table
+at some later point.
+
+Signed-off-by: Harald Welte <laforge@openmoko.org>
+Index: u-boot/drivers/nand/nand_base.c
+===================================================================
+--- u-boot.orig/drivers/nand/nand_base.c 2007-03-01 12:47:31.000000000 +0100
++++ u-boot/drivers/nand/nand_base.c 2007-03-01 12:48:08.000000000 +0100
+@@ -481,7 +481,7 @@
+
+ /* Do we have a flash based bad block table ? */
+ if (this->options & NAND_USE_FLASH_BBT)
+- return nand_update_bbt (mtd, ofs);
++ nand_update_bbt (mtd, ofs);
+
+ /* We write two bytes, so we dont have to mess with 16 bit access */
+ ofs += mtd->oobsize + (this->badblockpos & ~0x01);