aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ar71xx/files/drivers
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2013-09-27 11:15:34 +0000
committerGabor Juhos <juhosg@openwrt.org>2013-09-27 11:15:34 +0000
commit7815af409af011e1a5572fde06450cb42130d461 (patch)
treed03a7f16eefe2579a4dcc698b9b6ef628d3f5294 /target/linux/ar71xx/files/drivers
parent5da90c4e1f657bb7ecb1faed0b1d2c4a3888a8c7 (diff)
downloadupstream-7815af409af011e1a5572fde06450cb42130d461.tar.gz
upstream-7815af409af011e1a5572fde06450cb42130d461.tar.bz2
upstream-7815af409af011e1a5572fde06450cb42130d461.zip
ar71xx: ar934x-nfc: disable subpage write when hardware ECC is used
It is not supported by the controller. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> SVN-Revision: 38234
Diffstat (limited to 'target/linux/ar71xx/files/drivers')
-rw-r--r--target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c b/target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c
index 8b6658087f..9231251593 100644
--- a/target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c
+++ b/target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c
@@ -1281,6 +1281,12 @@ ar934x_nfc_setup_hwecc(struct ar934x_nfc *nfc)
switch (nfc->mtd.writesize) {
case 2048:
+ /*
+ * Writing a subpage separately is not supported, because
+ * the controller only does ECC on full-page accesses.
+ */
+ nand->options = NAND_NO_SUBPAGE_WRITE;
+
nand->ecc.size = 512;
nand->ecc.bytes = 7;
nand->ecc.strength = 4;