]> git.baikalelectronics.ru Git - uboot.git/commit
env: make env_import(_redund) return 0 on success, not 1
authorSimon Goldschmidt <sgoldschmidt@de.pepperl-fuchs.com>
Wed, 31 Jan 2018 13:47:10 +0000 (14:47 +0100)
committerTom Rini <trini@konsulko.com>
Wed, 31 Jan 2018 23:45:10 +0000 (18:45 -0500)
commit874b91e88d277f859510016447885876a035eb6c
tree5ad1234769e5fd1f4745399a544115b1d7d3130b
parenta627e6486d141cc80c52932f20af0f679afd49b5
env: make env_import(_redund) return 0 on success, not 1

env_import (and env_import_redund) currently return 1 on success
and 0 on error. However, they are only used from functions
returning 0 on success or a negative value on error.

Let's clean this up by making env_import and env_import_redund
return 0 on success and -EIO on error (as was the case for all
users before).

Users that cared for the return value are also updated. Funny
enough, this only affects onenand.c and sf.c

Signed-off-by: Simon Goldschmidt <sgoldschmidt@de.pepperl-fuchs.com>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
env/common.c
env/onenand.c
env/sf.c