diff options
author | Wolfgang Denk <wd@denx.de> | 2009-03-18 00:39:10 +0100 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2009-03-18 00:39:10 +0100 |
commit | efa0215228a26a90c86ac03511da73cb519eb516 (patch) | |
tree | 91c320d284b5857406cce82fd0fb0c0b2df39407 | |
parent | 0b2f38fe3c4555dd2b81c69880403c13ad723153 (diff) | |
parent | 65d8bc94d8214812ccdf3372d3fef845cf4ec2e5 (diff) | |
download | u-boot-efa0215228a26a90c86ac03511da73cb519eb516.zip u-boot-efa0215228a26a90c86ac03511da73cb519eb516.tar.gz u-boot-efa0215228a26a90c86ac03511da73cb519eb516.tar.bz2 |
Merge branch 'master' of git://git.denx.de/u-boot-nand-flash
-rw-r--r-- | common/cmd_nand.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/common/cmd_nand.c b/common/cmd_nand.c index 11f9096..e6623ca 100644 --- a/common/cmd_nand.c +++ b/common/cmd_nand.c @@ -502,7 +502,7 @@ static int nand_load_image(cmd_tbl_t *cmdtp, nand_info_t *nand, s = strchr(cmd, '.'); if (s != NULL && - (strcmp(s, ".jffs2") && !strcmp(s, ".e") && !strcmp(s, ".i"))) { + (strcmp(s, ".jffs2") && strcmp(s, ".e") && strcmp(s, ".i"))) { printf("Unknown nand load suffix '%s'\n", s); show_boot_progress(-53); return 1; @@ -511,7 +511,7 @@ static int nand_load_image(cmd_tbl_t *cmdtp, nand_info_t *nand, printf("\nLoading from %s, offset 0x%lx\n", nand->name, offset); cnt = nand->writesize; - r = nand_read(nand, offset, &cnt, (u_char *) addr); + r = nand_read_skip_bad(nand, offset, &cnt, (u_char *) addr); if (r) { puts("** Read error\n"); show_boot_progress (-56); @@ -543,8 +543,7 @@ static int nand_load_image(cmd_tbl_t *cmdtp, nand_info_t *nand, } show_boot_progress (57); - /* FIXME: skip bad blocks */ - r = nand_read(nand, offset, &cnt, (u_char *) addr); + r = nand_read_skip_bad(nand, offset, &cnt, (u_char *) addr); if (r) { puts("** Read error\n"); show_boot_progress (-58); |