Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1248021

[PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING option flag

From Boris Brezillon <boris.brezillon@free-electrons.com>
Newsgroups linux.kernel
Subject [PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING option flag
Date 2015-10-15 19:20 +0200
Message-ID <qjUm6-4xd-15@gated-at.bofh.it> (permalink)
References <qjUm6-4xd-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Some MLC NANDs are sensible to repeated patterns and require data to be
scrambled in order to limit the number of bitflips.
Add a new flag to let the NAND controller know about this constraint.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
---
 include/linux/mtd/nand.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h
index 5a9d1d4..19b4c6f 100644
--- a/include/linux/mtd/nand.h
+++ b/include/linux/mtd/nand.h
@@ -160,6 +160,12 @@ typedef enum {
 /* Device supports subpage reads */
 #define NAND_SUBPAGE_READ	0x00001000
 
+/*
+ * Some MLC NANDs need data scrambling to limit bitflips caused by repeated
+ * patterns.
+ */
+#define NAND_NEED_SCRAMBLING	0x00002000
+
 /* Options valid for Samsung large page devices */
 #define NAND_SAMSUNG_LP_OPTIONS NAND_CACHEPRG
 
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING option flag Boris Brezillon <boris.brezillon@free-electrons.com> - 2015-10-15 19:20 +0200
  Re: [linux-sunxi] [PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING  option flag Julian Calaby <julian.calaby@gmail.com> - 2015-10-16 00:40 +0200
    Re: [linux-sunxi] [PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING  option flag Boris Brezillon <boris.brezillon@free-electrons.com> - 2015-10-16 08:30 +0200
      Re: [linux-sunxi] [PATCH 1/3] mtd: nand: add NAND_NEED_SCRAMBLING  option flag Boris Brezillon <boris.brezillon@free-electrons.com> - 2015-10-16 08:40 +0200

csiph-web