public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Artem Bityutskiy <dedekind@infradead.org>
To: Eirik Aanonsen <eaa@wprmedical.com>
Cc: kernel@avr32linux.org, linux-mtd <linux-mtd@lists.infradead.org>
Subject: RE: UBIFS error CRC calculation on avr32 CPU
Date: Wed, 03 Dec 2008 11:25:25 +0200	[thread overview]
Message-ID: <1228296325.13686.24.camel@sauron> (raw)
In-Reply-To: <2DE39384A09B744FA1E53FD4BF78D430535E64@dware1013.doorway.loc>

On Wed, 2008-12-03 at 08:55 +0100, Eirik Aanonsen wrote:
> > It looks like you indeed have corrupted data. Where the 'wpr_004.wfp'
> > file comes from? You wrote it previously? Or you used mkfs.ubifs?
> > 
> The file is a binary file from my system. And the file has been checked for integrity before being copied over to the ubifs file system.

OK.

> Wpr_004.wfp originates from a vfat partition, and was moved along with 10 other files, and then when I try to move the file back out from ubifs the read error occurs.

OK, this means that the file had not been correctly written to UBIFS.
Your NAND driver may have problems. The fact that you use NAND flash
with 4KiB page size also suggests this, because AFAIK MTD does not
really support 4KiB per page NANDs. You probably have some custom MTD
diver/modifications.

Could you please verify your NAND driver before trying to use UBIFS?
Here you may get NAND tests which should do this:

git://git.infradead.org/users/ahunter/nand-tests.git

The tests are kernel modules. Compile them properly, then just insert
them, may be with some parameters. Use modinfo to see the parameters,
or look at the source code. All tests are harmless, except of torture
test - be careful with it.

Note, these tests has not been run on 4KiB-page NANDs, but they should
work fine anyway.

Could you please tell which NAND hardware you have? Is it SLC or MLC?

> > Also, did you try to enable UBIFS and UBI extra self-checks? Please,
> > try. Things will become very slow then, though, but this may give
> > some useful information.
> 
> Here are the result after enabling these two options.

I see. Basically, you have broken nodes on your flash media, which means
your files have not been written correctly for some reasons. For now I
suspect buggy NAND driver.

> How do I do cleaning in ubifs?

Well, in _normal_ situations you should not need this at all, and UBIFS
is self-recoverable. In your case you have some severe problems so you
have data corruptions which you cannot recover anyway. You may only
delete the corrupted files.

But yes, an ckfs.ubifs user-space utility would be nice to have, and we
were thinking to create it. At the moment, it does not exist.

-- 
Best regards,
Artem Bityutskiy (Битюцкий Артём)

  reply	other threads:[~2008-12-03  9:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-01  3:49 [ARM] pxa: explicit #include <mach/dma.h> in various drivers Eric Miao
2008-12-01 12:33 ` UBIFS error CRC calculation on avr32 CPU Eirik Aanonsen
2008-12-02  8:44   ` Artem Bityutskiy
2008-12-02 12:59     ` Eirik Aanonsen
2008-12-02 15:15       ` Artem Bityutskiy
2008-12-03  7:55         ` Eirik Aanonsen
2008-12-03  9:25           ` Artem Bityutskiy [this message]
2008-12-05 10:46             ` Eirik Aanonsen
2008-12-05 10:58               ` 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=1228296325.13686.24.camel@sauron \
    --to=dedekind@infradead.org \
    --cc=eaa@wprmedical.com \
    --cc=kernel@avr32linux.org \
    --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