u-boot/drivers/mtd/nand
Pekon Gupta 47f7187754 mtd: nand: omap: fix ecc-layout for HAM1 ecc-scheme
As per OMAP3530 TRM referenced below [1]

For large-page NAND, ROM code expects following ecc-layout for HAM1 ecc-scheme
 - OOB[1] (offset of 1 *byte* from start of OOB) for x8 NAND device
 - OOB[2] (offset of 1 *word* from start of OOB) for x16 NAND device

Thus ecc-layout expected by ROM code for HAM1 ecc-scheme is:
 *for x8 NAND Device*
 +--------+---------+---------+---------+---------+---------+---------+
 | xxxx   | ECC[A0] | ECC[A1] | ECC[A2] | ECC[B0] | ECC[B1] | ECC[B2] | ...
 +--------+---------+---------+---------+---------+---------+---------+

 *for x16 NAND Device*
 +--------+--------+---------+---------+---------+---------+---------+---------+
 | xxxxx  | xxxxx  | ECC[A0] | ECC[A1] | ECC[A2] | ECC[B0] | ECC[B1] | ECC[B2] |
 +--------+--------+---------+---------+---------+---------+---------+---------+

This patch fixes ecc-layout *only* for HAM1, as required by ROM-code
For other ecc-schemes like (BCH8) ecc-layout is same for x8 or x16 devices.

[1] OMAP3530: http://www.ti.com/product/omap3530
    TRM: http://www.ti.com/litv/pdf/spruf98x
		Chapter-25: Initialization Sub-topic: Memory Booting
		Section: 25.4.7.4 NAND
		Figure 25-19. ECC Locations in NAND Spare Areas

Reported-by: Stefan Roese <sr@denx.de>
Signed-off-by: Pekon Gupta <pekon@ti.com>
2013-12-06 15:17:15 -05:00
..
Makefile mtd: nand: omap: make am33xx/elm.c as common driver for all OMAPx and AMxxxx platforms 2013-11-26 08:54:43 -05:00
am335x_spl_bch.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
atmel_nand.c mtd: atmel_nand: pmecc: fix bug fail to correct bit error in 1024-bytes sector 2013-09-04 17:07:21 +02:00
atmel_nand_ecc.h Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
bfin_nand.c mtd: resync with Linux-3.7.1 2013-05-31 17:12:03 -05:00
davinci_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
diskonchip.c mtd: resync with Linux-3.7.1 2013-05-31 17:12:03 -05:00
docg4.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
docg4_spl.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
fsl_elbc_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
fsl_elbc_spl.c Coding Style cleanup: replace leading SPACEs by TABs 2013-10-14 16:06:54 -04:00
fsl_ifc_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
fsl_ifc_spl.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
fsl_upm.c Coding Style cleanup: replace leading SPACEs by TABs 2013-10-14 16:06:54 -04:00
fsmc_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
jz4740_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
kb9202_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
kirkwood_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
kmeter1_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
mpc5121_nfc.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
mxc_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
mxc_nand.h Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
mxc_nand_spl.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
mxs_nand.c mxs_nand: Fix ECC strength for NAND flash with OOB size of 224 2013-09-11 09:33:36 +02:00
nand.c nand: Introduce CONFIG_SYS_NAND_SELF_INIT 2012-01-26 16:09:06 -06:00
nand_base.c Coding Style cleanup: replace leading SPACEs by TABs 2013-10-14 16:06:54 -04:00
nand_bbt.c mtd: resync with Linux-3.7.1 2013-05-31 17:12:03 -05:00
nand_bch.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
nand_ecc.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
nand_ids.c Coding Style cleanup: remove trailing empty lines 2013-10-14 16:06:54 -04:00
nand_plat.c mtd: nand_plat: add simple GPIO framework DEV_READY option 2010-07-08 16:52:12 -05:00
nand_spl_load.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
nand_spl_simple.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
nand_util.c Coding Style cleanup: replace leading SPACEs by TABs 2013-10-14 16:06:54 -04:00
ndfc.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
nomadik.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
omap_elm.c mtd: nand: omap: add support for BCH16_ECC in ELM driver 2013-12-03 14:30:42 +05:30
omap_gpmc.c mtd: nand: omap: fix ecc-layout for HAM1 ecc-scheme 2013-12-06 15:17:15 -05:00
s3c2410_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
tegra_nand.c Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
tegra_nand.h Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00