Hello,
[...]
> boot > load jffs
>
> Then I send rootfs.jffs by Xmodem. But what address does my
> rootfs.jffs be loaded. 0x00040000 (the end of bootldr
> partition)?
The partition of the flash is defined in
/linux/drivers/mtd/sa1100-flash.c
Assabet defaults with 3 partitions at addresses 0, 0x40000, 0x100000.
You can find that out with cat /proc/mtd as well (this will give
you at least the list and size of the partition, and maybe the
starting addresses as well depending on the version of your mtd
driver).
So it's up to you where you want to load your JFFS.. probably
on mtd2 and therefore at address 0x100000.
> How can I use ramfs ?
You need to compile your kernel with support for ramfs and then
mount -t ramfs ramfs /your_ramfs
This works like mounting /proc: it's not a device, so you replace
the device with "ramfs". After the mount, /your_ramfs is a file
system in ram.
[snip of the script]
> Should I use ramfs as the way in "linuxrc" ?
> Do I need a "linuxrc" in rootfs.jffs ?
> Of all,how can I get a jffs image to use as rootfs?
You don't _need_ a linuxrc, and you don't _have_ to use ramfs
as in this script. It depends on how you want your system to
boot up, what it's supposed to do, etc. The idea of this
script (from what I can tell) is to copy cramfs (compressed
images) from flash partitions on ramfs. Nico goes one step
farther and copies those ramfs from cramfs images stored
in the JFFS through the loopback device. This achives:
- compression in flash for the ramfs
- only one file system/partition in the flash
- security when updating the images, if needed.
To use a jffs image as root, simply store it at the beginning
of a flash partition (say at address 0x100000, corresponding
to mtd2 on Assabet), compile your kernel with jffs support and
run it with command line: root=1f02 (1f02 is the major/minor for
/dev/mtdblock2, which is the partition number for that address).
I'm not a specialist of the Assabet so I might have messed up
some addresses/numbers, but I hope there is enough details to help :)
Cheers
Yves
_______________________________________________
http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm
Please visit the above address for information on this list.