aboutsummaryrefslogtreecommitdiff
path: root/common/env_nand.c
diff options
context:
space:
mode:
authorSteve Sakoman <steve@sakoman.com>2010-12-03 13:25:43 +0000
committerScott Wood <scottwood@freescale.com>2010-12-06 18:28:33 -0600
commit068a208b4a3e1e0dfc8dea6ebbd80b62ae280732 (patch)
tree91abd21ebe550f27e0a99ec0d91106db35347e02 /common/env_nand.c
parentf12af1f38dc59a6dfe0fed1359e1a05e700a435b (diff)
downloadu-boot-linaro-natty-068a208b4a3e1e0dfc8dea6ebbd80b62ae280732.tar.gz
env_nand: Use nand_read_skip_bad instead of nand_read
The nand-read function returns an error code if correctable errors have occurred. This is not desirable, since the errors have been corrected! This patch switches to the nand_read_skip_bad function which does not return an error code if the errors are correctable. Signed-off-by: Steve Sakoman <steve.sakoman@linaro.org> Acked-by: Scott Wood <scottwood@freescale.com>
Diffstat (limited to 'common/env_nand.c')
-rw-r--r--common/env_nand.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/env_nand.c b/common/env_nand.c
index 4e8307aa3..7f6c91751 100644
--- a/common/env_nand.c
+++ b/common/env_nand.c
@@ -297,7 +297,7 @@ int readenv(size_t offset, u_char * buf)
offset += blocksize;
} else {
char_ptr = &buf[amount_loaded];
- if (nand_read(&nand_info[0], offset, &len, char_ptr))
+ if (nand_read_skip_bad(&nand_info[0], offset, &len, char_ptr))
return 1;
offset += blocksize;
amount_loaded += len;