Re: NAND simulator

Josh Boyer
2005-12-11T22:07:48Z

On 12/11/05, Charles Manning <manningc2@actrix.gen.nz> wrote:
> On Monday 12 December 2005 02:46, Artem B. Bityutskiy wrote:
> > Charles Manning wrote:
> > > Yes please.
> >
> > Uhh, will pospone this for now, will try to repair JFFS2 which doesn't
> > work after the last month's commits. Crud! Not sure whom to blame so far.
> >
> > > Can nandsim simulate storage larger than physical RAM (just swapping out)
> > > or would this need special support (eg. add some block device support?
> > > We're getting people in YAFFSland who are working with 8Gbytes of flash
> > > (and it will only get bigger!) and I expect you'd want large emulations
> > > to stress JFFS3. Being able to simulate areas up to, say, 16Gbytes for
> > > now would be a nice thing.
> >
> > Well, did not plan it. But we probably may add this functionality. We
> > may borrow it from mtd2blk ...
> >
> > > A way of simulating a failure (bit flip, write error) would also be handy
> > > for testing fs and ecc error handling.
> >
> > Yeah, good feature. But I'm not sure how to implement an interface for
> > this. It is probably easier to hack nandsim and add this manually...
>
> Manual hacking does work. I have done stuff like that in the past. Perhaps
> dynamic hacking could be done via procfs?
> eg, perhaps somethiong like
> echo "flip 12345 400 1" > /procfs/nandsim # flip bit 1 in byte 400, page
> 12345

Sysfs would be better. Or debugfs if you really want to be "Right
(tm)". But the general idea is good.

josh