[PATCH v4 1/3] env: split env_import_redund() into 2 functions

Simon Glass sjg at chromium.org
Mon Oct 12 05:35:02 CEST 2020


On Sat, 10 Oct 2020 at 02:28, Heiko Schocher <hs at denx.de> wrote:
>
> split from env_import_redund() the part which checks
> which Environment is valid into a separate function
> called env_check_redund() and call it from env_import_redund().
>
> So env_check_redund() can be used from places which also
> need to do this checks.
>
> Signed-off-by: Heiko Schocher <hs at denx.de>
>
> ---
> The return values from env_check_redund() for the cases
> only one read buffer is OK are not perfect, may we should
> find better return codes?
>
> (no changes since v2)
>
> Changes in v2:
> - patch "env: split env_import_redund into 2 functions"
>   is new in version 2. Idea is to not duplicate too much
>   code as Simon suggested.
>
>  env/common.c  | 42 ++++++++++++++++++++++++++++++++----------
>  include/env.h | 18 ++++++++++++++++++
>  2 files changed, 50 insertions(+), 10 deletions(-)

Reviewed-by: Simon Glass <sjg at chromium.org>


More information about the U-Boot mailing list