From: Elie De Brauwer <eliedebrauwer@gmail.com>
To: b32955@freescale.com, dwmw2@infradead.org, dedekind1@gmail.com,
computersforpeace@gmail.com
Cc: Elie De Brauwer <eliedebrauwer@gmail.com>, linux-mtd@lists.infradead.org
Subject: [PATCH v2] mtd: gpmi: Bitflip support in erased regions
Date: Sun, 15 Dec 2013 19:44:20 +0100 [thread overview]
Message-ID: <1387133061-6573-1-git-send-email-eliedebrauwer@gmail.com> (raw)
Hello All,
This is version 2 of my patch for gpmi-nand which corrects bitflips in
erased regions by correcting them in software. Thanks to Huagn Shijie's
feedback I added a 'fast'-path and a 'slow'-path for erased blocks.
Apparently the BCH's block's HW_BCH_STATUS0:ALLONES contains a bit which
indicates if the last block consisted out of all ones or not. This allows
us to easily discriminate between a read transaction of an erase block which
requires fixing and a read transaction which does not require fixing.
I did some benchmark testing (dd if=/dev/mtd1 of=/dev/null bs=1M) and
on my i.MX28 platform the performance of this patch is close to the
original version of the gpmi-nand driver (as currently present in
3.9 vanilla). While my original version of the patch where all erased
blocks where soft-corrected showed a 20% performance penalty. (One could
argue the performance penalty is a non-issue since the upper layer should
be intelligent enough not to start reading empty pages, or at least not
at a very high frequency).
I'm currently still awaiting feedback of Huang Shijie regarding the setting
for BM_BCH_MODE_ERASE_THRESHOLD. Which I currently set to bch strength,
since I think that from a regular block with bitflips the BCH block should
be able to correct up to this level.
Feedback/comments welcome.
Elie De Brauwer (1):
mtd: gpmi: Deal with bitflips in erased regions regions
drivers/mtd/nand/gpmi-nand/bch-regs.h | 2 ++
drivers/mtd/nand/gpmi-nand/gpmi-lib.c | 17 +++++++++++++
drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 43 +++++++++++++++++++++++++++++---
drivers/mtd/nand/gpmi-nand/gpmi-nand.h | 1 +
4 files changed, 60 insertions(+), 3 deletions(-)
--
1.7.10.4
next reply other threads:[~2013-12-15 18:44 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-15 18:44 Elie De Brauwer [this message]
2013-12-15 18:44 ` [PATCH v2] mtd: gpmi: Deal with bitflips in erased regions regions Elie De Brauwer
2013-12-16 4:30 ` Huang Shijie
2013-12-16 9:43 ` Elie De Brauwer
2013-12-16 13:00 ` Huang Shijie
2013-12-16 13:14 ` Elie De Brauwer
2013-12-17 2:23 ` Huang Shijie
2013-12-17 2:29 ` Huang Shijie
2013-12-17 2:37 ` Huang Shijie
2013-12-17 6:35 ` Elie De Brauwer
2013-12-17 7:10 ` Brian Norris
2013-12-17 3:50 ` Huang Shijie
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=1387133061-6573-1-git-send-email-eliedebrauwer@gmail.com \
--to=eliedebrauwer@gmail.com \
--cc=b32955@freescale.com \
--cc=computersforpeace@gmail.com \
--cc=dedekind1@gmail.com \
--cc=dwmw2@infradead.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