Date:2010-08-31 01:43:20 (12 years 1 month ago)
Author:Maarten ter Huurne
Commit:8f56829b2361ca9e8d938661dfbc3a270501c371
Message:MIPS: JZ4740: A320: Take advantage of 72-byte eccpos.

Expanding eccpos to 72 bytes is a cleaner solution than the workaround used in jz-2.6.34.
Files: arch/mips/jz4740/board-a320.c (2 diffs)

Change Details

arch/mips/jz4740/board-a320.c
123123};
124124
125125static struct nand_ecclayout a320_nand_ecc_layout = {
126    .eccpos = { 4 },
126    .eccpos = {
127         4, 5, 6, 7, 8, 9, 10, 11, 12, /* sector 0 */
128        16, 17, 18, 19, 20, 21, 22, 23, 24, /* sector 1 */
129        28, 29, 30, 31, 32, 33, 34, 35, 36, /* sector 2 */
130        40, 41, 42, 43, 44, 45, 46, 47, 48, /* sector 3 */
131        52, 53, 54, 55, 56, 57, 58, 59, 60, /* sector 4 */
132        64, 65, 66, 67, 68, 69, 70, 71, 72, /* sector 5 */
133        76, 77, 78, 79, 80, 81, 82, 83, 84, /* sector 6 */
134        88, 89, 90, 91, 92, 93, 94, 95, 96, /* sector 7 */
135    },
127136    .oobfree = {
128137        { .offset = 100, .length = 22 },
129        }
138    }
130139};
131140
132141static void a320_nand_ident(struct platform_device *pdev,
...... 
135144                int *num_partitions)
136145{
137146    chip->options |= NAND_USE_FLASH_BBT;
138    chip->ecc.bytes = 12; /* 9 bytes ECC + 3 bytes zero padding */
139147    chip->bbt_td = &a320_nand_bbt_main_descr;
140148    /* MtH: I did not find a mirror bbt yet, but it might exist. */
141149    chip->bbt_md = NULL;

Archive Download the corresponding diff file



interactive