linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Stefani Seibold <stefani@seibold.net>
To: dedekind1@gmail.com
Cc: "Kreuzer, Michael \(NSN - DE/Ulm\)" <michael.kreuzer@nsn.com>,
	linux-mtd@lists.infradead.org,
	"Matthew L. Creech" <mlcreech@gmail.com>
Subject: Re: ubi_eba_init_scan: cannot reserve enough PEBs
Date: Wed, 28 Jul 2010 07:46:49 +0200	[thread overview]
Message-ID: <1280296009.4310.5.camel@wall-e.seibold.net> (raw)
In-Reply-To: <1280244117.3021.36.camel@localhost.localdomain>

Am Dienstag, den 27.07.2010, 18:21 +0300 schrieb Artem Bityutskiy:
> On Tue, 2010-07-27 at 18:12 +0300, Artem Bityutskiy wrote:
> > This really does not look like a NAND/MTD driver issue. More look like
> > either an UBIFS bug of some kind of corruption which corrupted an EC or
> > VID header, then UBI decided to erase this PEB, and then UBIFS reads all
> > 0xFFs from there.
> > 
> > The second theory should BTW be fixed. Indeed, when UBI finds a PEB with
> > corrupted headers, it adds this PEB to the 'corr' list, and then just
> > erases. But this is wrong! It should erase them only if there are all
> > 0xFFs in the rest of the block.
> 
> Yeah, indeed looks like a bad bug in UBI. So, when we have some flash
> corruptions which corrupt the VID header, UBI just silently erases this
> PEB! And then we have small chances to find out why on LEB suddenly
> became unmapped (erased).
> 
> UBI logic is - if VID header is corrupted, it is because a sudden power
> cut while writing the header. And we can erase the PEB because if we
> were writing the header, we have not written the data yet.
> 
> But it does not bother checking what goes _after_ the header. If there
> are some data, UBI should not erase the PEB but preserve it and switch
> to R/O mode.
> 
> CCing Stefani, I think here group faced a similar issue recently - one
> of LEB suddenly disappeared. This may be the reason.
> 
> Then the other question - why VID became corrupted? Dunno, but if UBI
> won't erase the PEB we'll have better chances to find this out. Does
> this sound reasonable?
> 

Not really. Why should especially the master LEB crash?

First: As i understand UBIFS will append data to the master LEBs until
no space is free, and then it will erase the master LEB and create a new
one. Is this right?

Second: We need a kind of the patch which i had provided i the case one
of the master block will be damaged. Otherwise the whole file system is
garbage.

- Stefani

  reply	other threads:[~2010-07-28  5:46 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-22 18:37 ubi_eba_init_scan: cannot reserve enough PEBs Matthew L. Creech
2010-07-26  5:21 ` Artem Bityutskiy
2010-07-26 21:13   ` Matthew L. Creech
2010-07-27 15:12     ` Artem Bityutskiy
2010-07-27 15:21       ` Artem Bityutskiy
2010-07-28  5:46         ` Stefani Seibold [this message]
2010-08-22 15:04           ` Artem Bityutskiy
2010-08-31 12:09             ` Stefani Seibold
2010-09-01 15:47               ` Artem Bityutskiy
2010-09-02  6:47                 ` Stefani Seibold
2010-09-02  9:45                   ` Artem Bityutskiy
2010-08-22 15:02         ` Artem Bityutskiy
2010-07-27 20:47       ` Matthew L. Creech
2010-07-30 16:12         ` Artem Bityutskiy
2010-07-30 17:51           ` Matthew L. Creech
2010-08-02  4:22             ` Artem Bityutskiy
2010-08-22 18:30       ` Artem Bityutskiy
2010-08-24 22:38         ` Matthew L. Creech
2010-08-25  3:51           ` Artem Bityutskiy
2010-08-31 15:36           ` Matthew L. Creech
2010-09-01 18:57             ` Artem Bityutskiy
2010-09-06  9:17               ` Artem Bityutskiy
2010-09-07 15:59                 ` Matthew L. Creech
2010-09-07 17:17                   ` Artem Bityutskiy
2010-09-07 17:48                     ` Artem Bityutskiy

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=1280296009.4310.5.camel@wall-e.seibold.net \
    --to=stefani@seibold.net \
    --cc=dedekind1@gmail.com \
    --cc=linux-mtd@lists.infradead.org \
    --cc=michael.kreuzer@nsn.com \
    --cc=mlcreech@gmail.com \
    /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).