|
@@ -772,7 +772,7 @@ static int nand_read_page_swecc(struct mtd_info *mtd, struct nand_chip *chip,
|
|
|
uint8_t *p = buf;
|
|
|
uint8_t *ecc_calc = chip->buffers->ecccalc;
|
|
|
uint8_t *ecc_code = chip->buffers->ecccode;
|
|
|
- int *eccpos = chip->ecc.layout->eccpos;
|
|
|
+ uint32_t *eccpos = chip->ecc.layout->eccpos;
|
|
|
|
|
|
chip->ecc.read_page_raw(mtd, chip, buf);
|
|
|
|
|
@@ -814,7 +814,7 @@ static int nand_read_page_hwecc(struct mtd_info *mtd, struct nand_chip *chip,
|
|
|
uint8_t *p = buf;
|
|
|
uint8_t *ecc_calc = chip->buffers->ecccalc;
|
|
|
uint8_t *ecc_code = chip->buffers->ecccode;
|
|
|
- int *eccpos = chip->ecc.layout->eccpos;
|
|
|
+ uint32_t *eccpos = chip->ecc.layout->eccpos;
|
|
|
|
|
|
for (i = 0; eccsteps; eccsteps--, i += eccbytes, p += eccsize) {
|
|
|
chip->ecc.hwctl(mtd, NAND_ECC_READ);
|
|
@@ -1420,7 +1420,7 @@ static void nand_write_page_swecc(struct mtd_info *mtd, struct nand_chip *chip,
|
|
|
int eccsteps = chip->ecc.steps;
|
|
|
uint8_t *ecc_calc = chip->buffers->ecccalc;
|
|
|
const uint8_t *p = buf;
|
|
|
- int *eccpos = chip->ecc.layout->eccpos;
|
|
|
+ uint32_t *eccpos = chip->ecc.layout->eccpos;
|
|
|
|
|
|
/* Software ecc calculation */
|
|
|
for (i = 0; eccsteps; eccsteps--, i += eccbytes, p += eccsize)
|
|
@@ -1446,7 +1446,7 @@ static void nand_write_page_hwecc(struct mtd_info *mtd, struct nand_chip *chip,
|
|
|
int eccsteps = chip->ecc.steps;
|
|
|
uint8_t *ecc_calc = chip->buffers->ecccalc;
|
|
|
const uint8_t *p = buf;
|
|
|
- int *eccpos = chip->ecc.layout->eccpos;
|
|
|
+ uint32_t *eccpos = chip->ecc.layout->eccpos;
|
|
|
|
|
|
for (i = 0; eccsteps; eccsteps--, i += eccbytes, p += eccsize) {
|
|
|
chip->ecc.hwctl(mtd, NAND_ECC_WRITE);
|