
Hi Pekon, Thank you for you advices. http://processors.wiki.ti.com/index.php/AM35x-OMAP35x-PSP_04.02.00.07_UserGu... selecting "Selecting NAND ECC scheme for Linux Kernel" by editing: arch/arm/mach-omap2/board-flash.c and drivers/mtd/nand/omap2.c I try to use Angstrom distribution as a base for my design. Angstrom provides 3.8.13 kernel for beaglebone. There drivers/mtd/nand/omap2.c seems pretty demanding as far as changing chip->ecc.bytes configuration is concerned. That feature seems hard-coded with numeric literal 13 everywhere in that file. So, changing that to 14 does not seem too good idea with my understanding level of that module operation.
Thanks anyway, Matti
2013/11/18 Gupta, Pekon pekon@ti.com
From: matti kaasinen [matti.kaasinen@gmail.com]
[...]
You mentioned, that OMAP_ECC_BCH8_CODE_HW mode and ecc.bytes=14 has to be used. I suppose that at least the former option requires kernel patching like explained in http://processors.wiki.ti.com/index.php/AM35x-OMAP35x PSP_04.02.00.07_UserGuide#Selecting_NAND_ECC_scheme_for_Linux_Kernel
In any case I did not find configuration option in menuconfig for that. Will "ecc.bytes=14" setting be taken care by that selection,
too?
Yes, the selection of "BCH8" along with "H/W ECC for OMAP devices" should automatically select (OMAP_ECC_BCH8_CODE_HW) which implicitly would configure chip->ecc.bytes = 14.
The layout will also be selected automatically, and this all is in accordance to NAND boot as documented in AM335x TRM [1].
- http://www.ti.com/product/am3359
- [1] latest AM3359 TRM
http://www.ti.com/litv/pdf/spruh73i
(a) Section: 26.1.7.4 NAND
- This section explains ROM code behavior for booting from NAND. ROM code also fetches device geometry from ONFI params. In addition there is a separate boot mode (called NANDI2C) where device parameters can be fetched from on-board EEPROM.
(b) Figure 26-15. ECC Data Mapping for 2 KB Page and 8b BCH Encoding
- This figure explains ecc layout used by ROM code, which is what I'm using as reference for BCH8_HW algorithm.
with regards, pekon