[U-Boot-Users] Excluding Env Variable section from the u-boot.bin
Wolfgang Denk
wd at denx.de
Fri Jan 13 11:10:02 CET 2006
In message <61124de70601122029v6f84d9fbya8a6c22a9f59afa8 at mail.gmail.com> you wrote:
>
> when i update my u-boot in the field (for some unavoidable reason),
> the update_uboot script erases all the u-boot flash sectors and over
> writes the new u-boot.bin - what if somethings goes wrong with the
> communication or power while copying u-boot.bin to flash?? i may loose
You shoudl always download theimage to ram *before* you start erasing
the flash, thus communication failures are not a problem.
If you have a power fail you are lost.
> important settings of my product in the field! u-boot.bin can always
> be updated using the BDI tool! But i cannot recover the environment
> variables.
You can make it more reliable for normal operation by using redundant
environment setors.
> i can make my update_uboot script in such a way that, before erasing
> the u-boot sectors, it will copy the env section to some free flash
> sector(as a backup) , update the u-boot.bin and then call 'saveenv'. i
> hope this is the better way to protect my environment variables.
Yes, you can additionally create a bacup copy for cases where you had
a power failure, but it is not as trivial as you (1) need to know
exactly where your environment is located (ok, not so difficult) and
(2) in case of redundand sectors you will have to test which one is
the active and which one the obsoleted sector.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
[Braddock:] Mr. Churchill, you are drunk.
[Churchill:] And you madam, are ugly. But I shall be sober tomorrow.
More information about the U-Boot
mailing list