env: mmc: Fix offset issue for env save
Fix the issue in commit 46c9016 ("env: mcc: Drop unnecessary #ifdefs")
If CONFIG_SYS_REDUNDAND_ENVIRONMENT is not defined, the offset value
becomes undetermined, so write env to unexpected offset.

[Backport of commit ccd0542ab260 ("env: mmc: Fix offset issue for env
 save")]

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
Change-Id: I295672256587b06ee79ca26ce52207e471e4c6aa
Reviewed-on: https://gerrit.st.com/c/mpu/oe/st/u-boot/+/294479
Tested-by: Patrick DELAUNAY <patrick.delaunay@foss.st.com>
Reviewed-by: Patrick DELAUNAY <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice CHOTARD <patrice.chotard@foss.st.com>
ACI: CIBUILD <MDG-smet-aci-builds@list.st.com>
Domain-Review: Patrice CHOTARD <patrice.chotard@foss.st.com>
1 parent a3ecc89 commit fa8916c59d1493da7c90473438967f6951b34fc3
@Ye Li Ye Li authored on 31 Jan 2023
Patrice Chotard committed on 29 May 2023
Showing 1 changed file
View
env/mmc.c