All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Weinberger <richard.weinberger@gmail.com>
To: Kees Trommel <ctrommel@aimvalley.nl>
Cc: Linux MTD <linux-mtd@lists.infradead.org>,
	Norbert van Bolhuis <nvbolhuis@aimvalley.nl>
Subject: Re: One bit flip in erased page causes uncorrectable error using (LS1020A) HW ECC
Date: Thu, 9 Mar 2017 23:15:56 +0100	[thread overview]
Message-ID: <CAFLxGvxrcUDEBcUsnQibYbX=-8BRSuP7ir3vzpFD-GL+Ofk7wg@mail.gmail.com> (raw)
In-Reply-To: <8f214368-48d1-ae21-b303-b36431abbeb9@aimvalley.nl>

Kees,

On Tue, Mar 7, 2017 at 10:15 AM, Kees Trommel <ctrommel@aimvalley.nl> wrote:
> Hello,
>
> I am doing development on a custom board with a NXP LS1020A of which the
> NAND controller supports HW ECC. Unfortunately the implementation of the HW
> ECC does not do the final XOR with the ECC of an empty page (like the Linux
> SW implementation does). This causes that a read of an empty page (both data
> and OOB) causes the HW to report an uncorrectable error. The Linux driver of
> this NAND controller (drivers/mtd/nand/fsl_ifc_nand.c) tries to workaround
> this by checking whether a page with an uncorrectable error is erased and if
> so the uncorrectable error is suppressed. However this work around does not
> work when a bit flips in an erased page because the page is no longer
> regarded as empty:(
>
> I observed a few times that UBI reports uncorrectable errors for the above
> reason and I am wondering whether this can cause a corruption of the
> UBI/UBIFS on top of the NAND mtd?

What exactly does UBI report?

> Until now I did not observe an UBI/UBIFS corruption but I am not sure
> whether I am just lucky or whether UBI/UBIFS can deal with uncorrectable
> errors in erased pages. I am  hoping that someone with a more in depth
> knowledge of UBI/UBIFS can answer this.

UBIFS assumes that empty space is really empty and assumes that the layers below
deals with bit flips in empty pages.
So, I fear your driver needs a better way to work around these bit flips.

-- 
Thanks,
//richard

  reply	other threads:[~2017-03-09 22:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-07  9:15 One bit flip in erased page causes uncorrectable error using (LS1020A) HW ECC Kees Trommel
2017-03-09 22:15 ` Richard Weinberger [this message]
2017-03-14 15:56   ` Kees Trommel
2017-03-19 20:34     ` Richard Weinberger

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='CAFLxGvxrcUDEBcUsnQibYbX=-8BRSuP7ir3vzpFD-GL+Ofk7wg@mail.gmail.com' \
    --to=richard.weinberger@gmail.com \
    --cc=ctrommel@aimvalley.nl \
    --cc=linux-mtd@lists.infradead.org \
    --cc=nvbolhuis@aimvalley.nl \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.