[U-Boot] Updating YAFFS2 RootFS

Wolfgang Denk wd at denx.de
Mon Jun 28 09:32:04 CEST 2010


Dear "David Andrey",

Please do not top post / full qoute. Read
http://www.netmeister.org/news/learn2quote.html


In message <1OT8ED-000558-1r at wolf.netmodule.com> you wrote:
> 
> he NAND is formatted as follow:
> * U-Boot Partition
> * Images Partition (YAFFS2) (Kernel, RootFS as tgz, FPGA / DSP
> Firmwares).
> * Linux RootFS (YAFFS2)
> 
> To update "Linux", the way we imagine is this one:
> 1. write a new kernel and rootFS in the "Images" partition (get the
> files through TFTP)
> 2. u-boot erase the old rootFS and "install" the newer
> 3. Boot Linux with the newer kernel

If you have a network connection an can download the images through
TFTP, then why do you need the "Images Partition" at all? You
coulinstall the downloaded images directly.

> But why from U-Boot ? :-)
> -> To provide a robust update mechanism.
> 	-> equals what happens with Linux (through end-user), u-boot
> will "always" start.

OK.

> So, I'm looking to clarify the step 2. What is missing ? Ideally,
> something like this:
>     yrdm /images/my_newer_rootfs.tgz  my_ram_address
>     yunzip my_ram_address /rootfs/

For me the reason to have the images partition is missing. If I were
in your place, I would probably use the spoace rather to have space
for a second root file system, so I can always install into an
alternative partition while keeping the old (working copy) in place.
Even if an update fails permanently for some reason (like corrupted
images on the server) you can then still fall back to the old version.

And as long as you download the images anyway there is little reason
to store these locally in a non-installed form.  At least I cannt see
one.

> The patch's I means are:    
> http://lists.denx.de/pipermail/u-boot/2008-September/040910.html
> http://lists.denx.de/pipermail/u-boot/2006-September/016867.html

That's old and obsolete stuff. Should not be needed at all.

> So, what do you think ? Sense or no sense ? Is it a way to achieve this
> from u-boot ?

It can be done as you described it, but it makes little sense to me.

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
Our universe is a fragile house of atoms, held together by the mortar
of cause-and-effect. One magician would be two too many.
                        - Terry Pratchett, _The Dark Side of the Sun_


More information about the U-Boot mailing list