Re: jffs2 doubts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi,

El Sun, Jan 03, 2010 at 12:38:42PM +0530 Arun S ha dit:

>     I have couple of doubts regarding jffs2 filesystem.                       
>                                                                               
>    1. I've found instances of writing mtd partitions with dd (like dd         
>    if=rootfs.jffs2 of=/dev/mtd...) and another method is to use flash_erase   
>    /dev/mtd.. and then copying rootfs.jffs2 to /dev/mtd.. using cp command    
>    followed by sync. What is the difference between these two?.               

i'm not sure whether a modern kernel erases the partition before
writing it when using dd, cat, ... this works with 2.4, but IIRC not
with 2.6. another important difference is that flashcp verifies that
the flash has been written correctly by reading the data back.

>    2. How jffs2 works? I mean if my root partition is jffs2, if I access some 
>    files, is it accessed real-time from the flash device?                     
>                                                                               
>     OR                                                                        
>                                                                               
>    Does the kernel uncompress the jffs2 partition and stores it in memory     
>    during boot and access it from there when a read request comes?            

on the first access of a file the kernel reads it from the flash, on
successive accesses it is likely that the data is in the buffer cache,
ie in the RAM

best regards

-- 
Matthias Kaehlcke
Embedded Linux Developer
Barcelona

              Insanity: doing the same thing over and over
                again and expecting different results
                            (Albert Einstein)
                                                                 .''`.
    using free software / Debian GNU/Linux | http://debian.org  : :'  :
                                                                `. `'`
gpg --keyserver pgp.mit.edu --recv-keys 47D8E5D4                  `-

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux