selecting UBI boot partition on startup

Wolfgang Denk wd at denx.de
Thu Apr 15 02:18:54 EDT 2010


Dear "Deon Carr",

please jkeep the mailing list on Cc: - others might be interested in
the answers as well.

In message <0687C69BF96AF349833719247B11C1CE76ED80 at exchtxus2.HSTX.global.vpn> you wrote:
> 
> >> What is the best method of selecting UBI volume to boot from in
> >> uboot?
> 
> >Store the information in U-Boot environment variables.
> 
> This was my initial thought however I was put off by the chance of the
> environment variables getting corrupted due to power loss while writing
> to U-Boot. I guess its possible to mirror the environment variables to
> another part of flash and restore it if the crc32 check fails on
> start-up.

Redundant environment is a standard feature in U-Boot. It covers
exactly the issue you have in mind - if you have a reset or power loss
while writing the environment, U-Boot will automatically fall back to
the redudant copy and use the previously used settings.

All you have to do is to enable this feature in your board config
file.

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
They say a little knowledge is a dangerous thing,  but it is not  one
half so bad as a lot of ignorance.   - Terry Pratchett, _Equal Rites_



More information about the linux-mtd mailing list