[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: garbage collect
The following might be helpful I hope:
In our 2100 and Developer board products we have the single flash chip
divided into three devices/partitions (cflashX is a character device and
flashX a block device):
The size and type of each partition can be described in a partition table:
# partition table info. Used by the mkptable tool.
# name size rw-options type name
rescue 0x10000 ro rescue rescue.img
flash1 0x1a0000 ro kernel flash1.img
flash2 0x50000 rw jffs flash2.img
The rescue image is kind of lika a bootloader as you described in a previous
It can also contains readonly parameters such as serial number etc.
This partition table can be encoded in the rescue image and read
by the kernel, but the partitioning above is the default used on our
The flash1 (kernel+romfs) contains a decompressor and a gzipped kernel+romfs
this image is decompressed to DRAM and then the kernel is booted from DRAM.
(On our wishlist is to have a romfs that is compressed on file/block level
or to make
add a loader that can handle compressed binaries - that would probably give
us about 1MB free DRAM)
I hope I got it all right, but if I didn't - I'm sure that Björn will
correct me :-)
From: Jason Gunthorpe <firstname.lastname@example.org>
To: Bjorn Wesen <email@example.com>
Date: Wednesday, June 28, 2000 08:10
Subject: Re: garbage collect
>On Tue, 27 Jun 2000, Bjorn Wesen wrote:
>> There is a magic sequence in the beginning of each node, that can be used
>> to locate the start (in combination with a correct checksum of the node
>> course, if other data is present). That's how the scan picks up after a
>> failed write.
>Hm.. What if the first sector has just been erased (GC operation) and the
>system crashes.. I think you need to store the expected flash extent in a
>sector header(s) :|
>How do you locate the spare sector if you don't have any sector headers?