mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-01-10 03:01:27 +01:00
Add support for converting single-copy environment to redundant environment. In case CRC checks on both redundant environment copies fail, try one more CRC check on the primary environment copy and treat it as single environment. If that check does pass, rewrite the single-copy environment into redundant environment format, indicate the environment is valid, and import that as usual primary copy of redundant environment. Follow up 'env save' will then store two environment copies and the system will continue to operate as regular redundant environment system. Add test which validates this upgrade path. The test starts with spi.bin which is pre-populated as single-copy environment and then upgrades that environment to dual-copy environment. Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>