]> git.baikalelectronics.ru Git - uboot.git/commit
env: correct overflow check of env_has_init size
authorPatrick Delaunay <patrick.delaunay@st.com>
Wed, 24 Jun 2020 07:27:25 +0000 (09:27 +0200)
committerTom Rini <trini@konsulko.com>
Sun, 26 Jul 2020 18:35:30 +0000 (14:35 -0400)
commit17e52957d0505833a7cfe3a520e56a06cec41467
treeae22bc552c6f50dc54eb1893574f8d67f37adf30
parent68d85ee02ce4be1a10db3902124e38e628f209db
env: correct overflow check of env_has_init size

Correct the overflow check of the bit-field env_has_init with
the max value of env_location= ENVL_COUNT and no more with the
size of env_locations.

This bit-field is indexed by this enumerate and not by the position in
the env_locations (only used in env_get_location) and the
2 values are different, depending of thea ctivated CONFIG_ENV_IS_ options.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
env/env.c