[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <819dc664597b64ee562e4ae15faadf542b4eae8c.1399973152.git.jslaby@suse.cz>
Date: Tue, 13 May 2014 11:28:39 +0200
From: Jiri Slaby <jslaby@...e.cz>
To: stable@...r.kernel.org
Cc: linux-kernel@...r.kernel.org,
Herve Codina <Herve.CODINA@...ad.com>,
Brian Norris <computersforpeace@...il.com>,
Jiri Slaby <jslaby@...e.cz>
Subject: [PATCH 3.12 167/182] mtd: atmel_nand: Disable subpage NAND write when using Atmel PMECC
From: Herve Codina <Herve.CODINA@...ad.com>
3.12-stable review patch. If anyone has any objections, please let me know.
===============
commit 90445ff6241e2a13445310803e2efa606c61f276 upstream.
Crash detected on sam5d35 and its pmecc nand ecc controller.
The problem was a call to chip->ecc.hwctl from nand_write_subpage_hwecc
(nand_base.c) when we write a sub page.
chip->ecc.hwctl function is not set when we are using PMECC controller.
As a workaround, set NAND_NO_SUBPAGE_WRITE for PMECC controller in
order to disable sub page access in nand_write_page.
Signed-off-by: Herve Codina <Herve.CODINA@...ad.com>
Acked-by: Josh Wu <josh.wu@...el.com>
Signed-off-by: Brian Norris <computersforpeace@...il.com>
Signed-off-by: Jiri Slaby <jslaby@...e.cz>
---
drivers/mtd/nand/atmel_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/atmel_nand.c b/drivers/mtd/nand/atmel_nand.c
index 9be079224761..1de054a0775d 100644
--- a/drivers/mtd/nand/atmel_nand.c
+++ b/drivers/mtd/nand/atmel_nand.c
@@ -1249,6 +1249,7 @@ static int __init atmel_pmecc_nand_init_params(struct platform_device *pdev,
goto err;
}
+ nand_chip->options |= NAND_NO_SUBPAGE_WRITE;
nand_chip->ecc.read_page = atmel_nand_pmecc_read_page;
nand_chip->ecc.write_page = atmel_nand_pmecc_write_page;
--
1.9.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists