summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorHuang Shijie <b32955@freescale.com>2013-09-25 14:58:20 +0800
committerHuang Shijie <b32955@freescale.com>2013-11-05 09:19:10 +0800
commitea7d2efa6bc39837f8fea8e952c1aa7368891b8a (patch)
tree71ce297079c2bcdfff891896662f9c3203fc2a76 /fs
parent65dbf133b25c091b35705ab7977e240100cbd3da (diff)
jffs2: do not support the MLC nand
We should not support the MLC nand for jffs2. So if the nand type is MLC, we quit immediatly. Signed-off-by: Huang Shijie <b32955@freescale.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/jffs2/fs.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/jffs2/fs.c b/fs/jffs2/fs.c
index fe3c0527545f..09b3ed455724 100644
--- a/fs/jffs2/fs.c
+++ b/fs/jffs2/fs.c
@@ -515,6 +515,10 @@ int jffs2_do_fill_super(struct super_block *sb, void *data, int silent)
c = JFFS2_SB_INFO(sb);
+ /* Do not support the MLC nand */
+ if (c->mtd->type == MTD_MLCNANDFLASH)
+ return -EINVAL;
+
#ifndef CONFIG_JFFS2_FS_WRITEBUFFER
if (c->mtd->type == MTD_NANDFLASH) {
pr_err("Cannot operate on NAND flash unless jffs2 NAND support is compiled in\n");