]> git.dujemihanovic.xyz Git - u-boot.git/commit
env_nand.c: support falling back to redundant env when writing
authorPhil Sutter <phil.sutter@viprinet.com>
Fri, 19 Jul 2013 10:20:26 +0000 (12:20 +0200)
committerScott Wood <scottwood@freescale.com>
Thu, 22 Aug 2013 22:49:47 +0000 (17:49 -0500)
commit2b26201a2aef0b310b7c04702b0dba5dea493f77
tree1c251e0d0ae78df6b5f51cbd4470e783a4cb4c12
parent47b6dad319af3b0d059d1d16003f8ac73e98cdb0
env_nand.c: support falling back to redundant env when writing

Without this patch, when the currently chosen environment to be written
has bad blocks, saveenv fails completely. Instead, when there is
redundant environment fall back to the other copy. Environment reading
needs no adjustment, as the fallback logic for incomplete writes applies
to this case as well.

Signed-off-by: Phil Sutter <phil.sutter@viprinet.com>
common/env_nand.c