[U-Boot-Users] MTD Concat support

Luigi 'Comio' Mantellini luigi.mantellini at idf-hit.com
Wed Apr 16 14:26:10 CEST 2008


Hi Vlad,
Hi list,

see inline comments.

On mer, 2008-04-16 at 14:47 +0300, Vlad Lungu wrote:
> Luigi 'Comio' Mantellini wrote:
> > Hi Guys,
> >
> ..
> > [0xbe000000 -> 0xbfc00000 ] JFFS2 root 
> > [0xbfc00000 -> 0xbfe00000 ] U-BOOT code
> > [0xbfe00000 -> 0xbfffffff ] DATA
> >
> >   
> So you have 16+12Mo then u-boot then 2 Mo left. 
Yes. :)
> > Into the JFFS2 filesystem there are the Kernel images and a lot of spare datas.
> >   
> That's a rather big JFFS filesystem. Do you plan booting from it? Isn't 
> it rather slow? It would take a few seconds (5-10) to
> scan the FS on this under U-Boot. I would recommend two strategies here:
I know that the JFFS2 is rather slow, but I have this constraint on my
application. The kernel images are provided as a big all-in-one file
that contains the kernel and the rootfs (which will mounted via a
loopback device). Unfortunately I cannot change this logic because a lot
of user-space software (made by external providers) assumes a big images
repository to store the monolithic images.

> -put the uImage directly in the NOR flash. Maybe in those 2 Mo at the 
> end or somewhere else. Update it from Linux
> or if you screw up, from the network.
> -create a smaller partition (like 4Mo) and keep two kernels there, main 
> and spare. Mount it under /boot in Linux.

I cannot follow these solutions because I need to keep monolithic images
(large about 8-10 MB) without explode them.

> Boot from there. Use the rest of the available space as root with the 
> MTD concat driver but don't touch it from U-Boot.
The JFFS2 partition will not contain the ready-for-use rootfs but
monolithic images that will be mounted using the loopback devices. This
is a constraint of my application :S and I cannot change it.

> Will boot much faster than from a 28Mo partition, you can use *summary* 
> information on root (not supported in U-Boot)
> for faster mount in Linux, more versatile than uImage in NOR (you can 
> have 1 or more spares depending on kernel sizes and partition size).

Can you explain this point?

> > How I can say to U-boot to consider the two flashes as a single space of
> > memory (in order to place a big JFFS2 filesystem)? In Linux I can
> > achieve this using the MTD Concat driver but I don't understand How I
> > can do in U-boot.
> >   
> What you are asking could be already possible, or require just a few 
> modifications, but you have to ask yourself: do I really HAVE to do this?
> 

The answer is pretty simple: the flash layout is a project
constraint :D. I know that this approach is very slow, but the target
application is a device that should be rebooted about once in a year.

Thanks a lot for your observations.

ciao

luigi
> Regards,
> Vlad

-- 
     ______       Luigi Mantellini
   .'______'.     R&D - Software
  (.'      '.)    Industrie Dial Face S.p.A.
  ( :=----=: )    Via Canzo, 4
  ('.______.')    20068 Peschiera Borromeo (MI), Italy
   '.______.'     Tel.: +39 02 5167 2813
                  Fax:  +39 02 5167 2459
Ind.  Dial Face   Email: luigi.mantellini at idf-hit.com
www.idf-hit.com   GPG fingerprint: 3DD1 7B71 FBDF 6376 1B4A
                                   B003 175F E979 907E 1650








More information about the U-Boot mailing list