Lines Matching refs:ecc
168 .ecc = lpc32xx_ooblayout_ecc,
406 static void lpc32xx_slc_ecc_copy(uint8_t *spare, const uint32_t *ecc, int count) in lpc32xx_slc_ecc_copy() argument
411 uint32_t ce = ecc[i / 3]; in lpc32xx_slc_ecc_copy()
530 for (i = 0; i < chip->ecc.steps; i++) { in lpc32xx_xfer()
533 dma_buf + i * chip->ecc.size, in lpc32xx_xfer()
534 mtd->writesize / chip->ecc.steps, dir); in lpc32xx_xfer()
539 if (i == chip->ecc.steps - 1) in lpc32xx_xfer()
571 host->ecc_buf[chip->ecc.steps - 1] = in lpc32xx_xfer()
614 status = lpc32xx_xfer(mtd, buf, chip->ecc.steps, 1); in lpc32xx_nand_read_page_syndrome()
620 lpc32xx_slc_ecc_copy(tmpecc, (uint32_t *) host->ecc_buf, chip->ecc.steps); in lpc32xx_nand_read_page_syndrome()
629 for (i = 0; i < chip->ecc.steps; i++) { in lpc32xx_nand_read_page_syndrome()
630 stat = chip->ecc.correct(chip, buf, oobecc, in lpc32xx_nand_read_page_syndrome()
631 &tmpecc[i * chip->ecc.bytes]); in lpc32xx_nand_read_page_syndrome()
637 buf += chip->ecc.size; in lpc32xx_nand_read_page_syndrome()
638 oobecc += chip->ecc.bytes; in lpc32xx_nand_read_page_syndrome()
658 chip->legacy.read_buf(chip, buf, chip->ecc.size * chip->ecc.steps); in lpc32xx_nand_read_page_raw_syndrome()
681 error = lpc32xx_xfer(mtd, (uint8_t *)buf, chip->ecc.steps, 0); in lpc32xx_nand_write_page_syndrome()
694 lpc32xx_slc_ecc_copy(pb, (uint32_t *)host->ecc_buf, chip->ecc.steps); in lpc32xx_nand_write_page_syndrome()
714 chip->ecc.size * chip->ecc.steps); in lpc32xx_nand_write_page_raw_syndrome()
777 if (chip->ecc.engine_type != NAND_ECC_ENGINE_TYPE_ON_HOST) in lpc32xx_nand_attach_chip()
791 chip->ecc.placement = NAND_ECC_PLACEMENT_INTERLEAVED; in lpc32xx_nand_attach_chip()
793 chip->ecc.size = 256; in lpc32xx_nand_attach_chip()
794 chip->ecc.strength = 1; in lpc32xx_nand_attach_chip()
795 chip->ecc.bytes = LPC32XX_SLC_DEV_ECC_BYTES; in lpc32xx_nand_attach_chip()
796 chip->ecc.prepad = 0; in lpc32xx_nand_attach_chip()
797 chip->ecc.postpad = 0; in lpc32xx_nand_attach_chip()
798 chip->ecc.read_page_raw = lpc32xx_nand_read_page_raw_syndrome; in lpc32xx_nand_attach_chip()
799 chip->ecc.read_page = lpc32xx_nand_read_page_syndrome; in lpc32xx_nand_attach_chip()
800 chip->ecc.write_page_raw = lpc32xx_nand_write_page_raw_syndrome; in lpc32xx_nand_attach_chip()
801 chip->ecc.write_page = lpc32xx_nand_write_page_syndrome; in lpc32xx_nand_attach_chip()
802 chip->ecc.write_oob = lpc32xx_nand_write_oob_syndrome; in lpc32xx_nand_attach_chip()
803 chip->ecc.read_oob = lpc32xx_nand_read_oob_syndrome; in lpc32xx_nand_attach_chip()
804 chip->ecc.calculate = lpc32xx_nand_ecc_calculate; in lpc32xx_nand_attach_chip()
805 chip->ecc.correct = rawnand_sw_hamming_correct; in lpc32xx_nand_attach_chip()
806 chip->ecc.hwctl = lpc32xx_nand_ecc_enable; in lpc32xx_nand_attach_chip()