From: Joshua Wise <joshua@joshuawise.com>
To: linux-mtd@lists.infradead.org
Cc: Matt Reimer <mreimer@vpop.net>
Subject: oobavail issues
Date: Wed, 30 Mar 2005 20:18:50 -0500 [thread overview]
Message-ID: <424B4FFA.7050906@joshuawise.com> (raw)
Hi folks,
We're debugging a mysterious crash on NAND writes on an s3c2410-derived
driver. The culprit seems to be in how oobavail is determined:
line 2524 nand_base.c: mtd->oobavail = mtd->oobsize -
(this->autooob->eccbytes + 1);
Our oobinfo is the same as the s3c2410's. For reference, that's:
static struct nand_oobinfo nand_hw_eccoob = {
.useecc = MTD_NANDECC_AUTOPLACE,
.eccbytes = 3,
.eccpos = {0, 1, 2 },
.oobfree = { {8, 8} }
};
We found that making our oobfree match up with oobavail seemed to do the
trick for avoiding this, and make JFFS2 work, to boot! Here's what we did:
static struct nand_oobinfo nand_hw_eccoob = {
.useecc = MTD_NANDECC_AUTOPLACE,
.eccbytes = 3,
.eccpos = {0, 1, 2 },
.oobfree = { {8, 8}, {3, 2}, {6, 2} } /* {6, 10} instead? */
};
I suspect that oobavail should be summing oobfree instead of doing that
arithmetic. Or is there something I'm not seeing?
joshua
next reply other threads:[~2005-03-31 1:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-31 1:18 Joshua Wise [this message]
2005-03-31 11:52 ` oobavail issues Thomas Gleixner
2005-03-31 17:29 ` Matthew Reimer
2005-03-31 19:20 ` Thomas Gleixner
2005-03-31 18:29 ` Matthew Reimer
2005-04-01 8:23 ` Thomas Gleixner
2005-04-01 17:27 ` Matthew Reimer
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=424B4FFA.7050906@joshuawise.com \
--to=joshua@joshuawise.com \
--cc=linux-mtd@lists.infradead.org \
--cc=mreimer@vpop.net \
/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