public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: David Woodhouse <dwmw2@infradead.org>
To: gleixner@autronix.de
Cc: linux-mtd@lists.infradead.org
Subject: Re: JFFS2 on NAND flash
Date: Thu, 31 Jan 2002 10:22:43 +0000	[thread overview]
Message-ID: <17832.1012472563@redhat.com> (raw)
In-Reply-To: <02013022481901.00763@thomas>

gleixner@autronix.de said:
>  I tried jffs2 on a NAND flash. Tracking down one ugly bug in fs/jffs2/
> write.c  i got it basicly working ! Thanks to all of you, who did his
> job on that jffs2/nand stuff obviously  without having access to a
> NAND device. 

Be careful. You have nothing there to make sure that it doesn't violate the 
constraints on the number of write cycles per page. You have no ECC, you 
have no real chance of it working in the wild.

Also note that the locking in jffs2_garbage_collect_deletion_dirent() is 
broken. We need to lock the erase_completion_lock while we go through the 
list, and drop the lock when we read the nodes. 

> jffs2_flash_writev calls mtd->writev, if available else it calls
> mtd_fake_writev. The nand driver supports writev and does not check if
> the  vecs[1] entry is empty. mtd_fake_writev takes care of this. I
> suggest to do the check in jffs_write_dnode (where the wrong count
> comes  from), although i will include a check in nand.c. This problem
> did not show up due to the fact, that obviously none of the  FLASH
> drivers supports writev. (I could not find one in mtd)

All the writev stuff was put there for the benefit of NAND flash - so yes,
nobody's used it yet. This problem had come up recently in the eCos port,
but the fix hadn't yet propagated to the main tree.

--
dwmw2

  reply	other threads:[~2002-01-31 10:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-12-01  9:51 JFFS2 on NAND flash/DiskOnChip David Woodhouse
2002-01-31 10:04 ` JFFS2 on NAND flash Thomas Gleixner
2002-01-31 10:22   ` David Woodhouse [this message]
2002-01-31 12:26     ` Thomas Gleixner
2002-01-31 14:29       ` Thomas Gleixner
2002-01-31 14:30       ` David Woodhouse

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=17832.1012472563@redhat.com \
    --to=dwmw2@infradead.org \
    --cc=gleixner@autronix.de \
    --cc=linux-mtd@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox