From: Thomas Gleixner <gleixner@autronix.de>
To: David Woodhouse <dwmw2@infradead.org>
Cc: linux-mtd@lists.infradead.org, jffs-dev@axis.com
Subject: JFFS2 list_dirty corruption
Date: Wed, 20 Feb 2002 20:41:48 +0100 [thread overview]
Message-ID: <02022020414807.18560@thomas> (raw)
While hacking on JFFS2 for NAND I found a possibility, where scan_medium
corrupts list_dirty.
jffs2_scan_medium calls
jffs2_scan_eraseblock calls
jffs2_scan_dirent_node calls
jffs2_add_fd_to_list
There is a duplicate entry detected, so it calls
jffs2_mark_node_obsolete
There is it possible that the jeb is added to list_dirty,
because it's a duplicate entry
with list_add_tail
We come back to
jffs2_scan_eraseblock
There is another condition, that marks the block dirty
We come back to
jffs2_scan_medium
There we add the block to list_dirty too with add_list
Then we have a circular list entry.
Result: chaos
That's not a problem of the NAND modifications. I verified, that this can
happen in the actual CVS-version too.
--
Thomas
__________________________________________________
Thomas Gleixner, autronix automation GmbH
auf dem berg 3, d-88690 uhldingen-muehlhofen
fon: +49 7556 919891 , fax: +49 7556 919886
mail: gleixner@autronix.de, http://www.autronix.de
next reply other threads:[~2002-02-20 19:27 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-20 19:41 Thomas Gleixner [this message]
2002-02-20 20:10 ` JFFS2 list_dirty corruption Thomas Gleixner
2002-02-20 23:55 ` Adam Wozniak
2002-02-20 23:58 ` Adam Wozniak
2002-02-21 0:26 ` Thomas Gleixner
2002-02-21 8:59 ` David Woodhouse
2002-02-21 9:19 ` Thomas Gleixner
2002-02-21 9:23 ` 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=02022020414807.18560@thomas \
--to=gleixner@autronix.de \
--cc=dwmw2@infradead.org \
--cc=jffs-dev@axis.com \
--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