Skip to content
Snippets Groups Projects
Commit 068a208b authored by Steve Sakoman's avatar Steve Sakoman Committed by Scott Wood
Browse files

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: default avatarSteve Sakoman <steve.sakoman@linaro.org>
Acked-by: default avatarScott Wood <scottwood@freescale.com>
parent f12af1f3
No related branches found
No related tags found
No related merge requests found
...@@ -297,7 +297,7 @@ int readenv(size_t offset, u_char * buf) ...@@ -297,7 +297,7 @@ int readenv(size_t offset, u_char * buf)
offset += blocksize; offset += blocksize;
} else { } else {
char_ptr = &buf[amount_loaded]; 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; return 1;
offset += blocksize; offset += blocksize;
amount_loaded += len; amount_loaded += len;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment