
With the new code to support multiple environment drivers and select an environment at runtime, to correctly implement fallback when one environment fails to load (e.g. crc error), the return value of env_import has to be propagated by all env driver's load function.
While cleaning this up, made some other cleanups, mainly to reduce duplicated code.
Changes from v1: - fixed duplicated commit message for patch 3/4 - removed german company email footer
Simon Goldschmidt (4): env: make env_import(_redund) return 0 on success, not 1 env: move more common code to env_import_redund env: make env drivers propagate env_import return value env: sf: use env_import_redund to simplify env_sf_load
env/common.c | 29 ++++++++++++++++++---- env/eeprom.c | 4 +-- env/ext4.c | 3 +-- env/fat.c | 3 +-- env/flash.c | 4 +-- env/mmc.c | 26 +++---------------- env/nand.c | 24 +++--------------- env/nvram.c | 4 +-- env/onenand.c | 4 +-- env/remote.c | 2 +- env/sata.c | 4 +-- env/sf.c | 69 +++++++-------------------------------------------- env/ubi.c | 22 ++++++++-------- include/environment.h | 3 ++- 14 files changed, 61 insertions(+), 140 deletions(-)