[U-Boot] [PATCH] env_sf: support embedded environments

Wolfgang Denk wd at denx.de
Tue Dec 16 00:47:25 CET 2008


Dear Mike Frysinger,

In message <1228994617-11732-1-git-send-email-vapier at gentoo.org> you wrote:
> If both CONFIG_ENV_SECT_SIZE and CONFIG_ENV_SIZE are defined, and the sect
> size is larger than the env size, then it means the env is embedded in a
> block.  So we have to save/restore the part of the sector which is not the
> environment.  Previously, saving the environment in SPI flash in this
> setup would probably brick the board as the rest of the sector tends to
> contain actual U-Boot data/code.
> 
> Signed-off-by: Mike Frysinger <vapier at gentoo.org>
> ---
>  common/env_sf.c |   41 ++++++++++++++++++++++++++++++++++++-----
>  1 files changed, 36 insertions(+), 5 deletions(-)

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"There are three principal ways to lose money: wine, women,  and  en-
gineers.  While  the first two are more pleasant, the third is by far
the more certain."                      -- Baron Rothschild, ca. 1800


More information about the U-Boot mailing list