[PATCH 1/4] mtd: nand: pxa3xx: Normalize ECC strength for ECC scheme selection

Ezequiel Garcia ezequiel.garcia at free-electrons.com
Thu Mar 20 13:39:22 EDT 2014


On Mar 17, Ezequiel Garcia wrote:
> @@ -1525,8 +1524,8 @@ KEEP_CONFIG:
>  		ecc_step = 512;
>  	}
>  
> -	ret = pxa_ecc_init(info, &chip->ecc, ecc_strength,
> -			   ecc_step, mtd->writesize);
> +	ret = pxa_ecc_init(info, &chip->ecc, (ecc_strength * ecc_step) / 512,
> +			   mtd->writesize);

After a test report from Simon Guinot we found this normalization is horribly
wrong. It should be: (ecc_strength * 512) / ecc_step. I'll prepare a v2 and
make sure to test it properly this time!
-- 
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com



More information about the linux-mtd mailing list