Does JFFS respect partitions?

David Woodhouse dwmw2 at
Thu Feb 15 06:41:47 EST 2001

jelson at ISI.EDU said:
>  Interesting - I didn't realize the DOC did internal wear-levelling.

The DiskOnChip doesn't. It's just a bunch of flash chips with a clever ASIC 
to multiplex them and do some ECC in hardware.

The NFTL psuedo-filesystem does. In software. 

> I guess that might mean that there's no point in using JFFS on top of
> the NTFL layer anyway?


> > It's also possible to register the DiskOnChip raw flash as two
> > separate MTD devices, which is how we 'partition' normal flash. Then
> > you let the NFTL code put a filesystem on one of them and use JFFS
> > on the other. 

> This sounds ideal - how does one do this?

You need to get your hands dirty. See the 'add_mtd_partitions' code in 
mtdpart.c and some of the drivers which call it - basically you have an 
underlying MTD device (the DiskOnChip) and you define two dummy devices 
which just add an offset to the address requested and pass through to the 
'real' device's methods. 

It's probably better to take the other route I suggested - have two NFTL
partitions on the DiskOnChip. Clever offset/len args to nftl_format will do
that. The NFTL code ought to be OK with it, and it shouldn't be difficult to
fix if it isn't.

> I don't know the intricacies of the existing jffs2 code or what's left
> to implement, but, will a broomstick speed things up for you?  :-)

Heh - maybe. But stupid quantities of caffeine seem to be working OK at the 


To unsubscribe, send "unsubscribe mtd" to majordomo at

More information about the linux-mtd mailing list