From: David Jander <david.jander@protonic.nl>
To: linuxppc-embedded@ozlabs.org
Subject: Re: jffs2 robustness against powerfailure
Date: Mon, 17 Oct 2005 08:42:05 +0200 [thread overview]
Message-ID: <200510170842.05970.david.jander@protonic.nl> (raw)
In-Reply-To: <00a701c5d0cc$4e0e6840$0301a8c0@chuck2>
On Friday 14 October 2005 16:33, Mark Chambers wrote:
>[...]
> Well, I can tell you this, from bitter experience: Chips do strange stuff
> when power is
> coming or going. One thing that can happen is addresses get messed up, so
> writes go
> to the wrong place. You say your hardware is good, but it may not have
> been thoroughly characterized for power-down behavior. Probably the same
> chip that
> generates a power-up reset generates a reset when power is falling, check
> if the trip
> voltage is high enough.
There's a hardware watchdog which monitors both power-supplies and asserts
reset in case of failure. It's reliable and it works.
But that all doesn't matter. You seem to oversee three facts:
1.- The file being written to at the moment of power failure is always the
file that has a CRC failure (if that happens) afterwards, not other files. So
"writes go to the wrong place" is quite unlikely.
2.- If a piece of flash get's corrupted, there's always the jffs2's CRC that
should trip and detect that block as invalid.
3.- If there really were writes to the wrong place, I'd expect that to be
noticeable by looking at the files. There is random data being written to the
files, but fortunately not that random: It's all 32-bit integers from
0...10000. That makes the chances of corrupt random data, or valid data
written to the wrong place not being noticed actually quite small!
It looks to me very much like a jffs2 bug or design flaw, maybe a
race-condition, but since I don't know jffs2 internals that much, I can't
tell for sure. Isn't this a known issue?
> You could rule a power problem out by running your tests where you reset
> the processor (shorting hreset or poreset somewhere) but not power-cycling
> the board, and see if
> the failures are the same.
I could do that, but I fear it will give the same results.
Ok, for sciences sake I'll do that experiment.
Sincerely,
--
David Jander
next prev parent reply other threads:[~2005-10-17 6:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-14 9:35 jffs2 robustness against powerfailure David Jander
2005-10-14 14:33 ` Mark Chambers
2005-10-17 6:42 ` David Jander [this message]
2005-10-17 12:37 ` David Woodhouse
2005-10-19 8:10 ` David Jander
2005-10-19 9:50 ` 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=200510170842.05970.david.jander@protonic.nl \
--to=david.jander@protonic.nl \
--cc=linuxppc-embedded@ozlabs.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;
as well as URLs for NNTP newsgroup(s).