Lines Matching defs:ecc
200 u8 *ecc = chip->oob_poi + BBM_SIZE + METADATA_SIZE;
201 const int ecc_size = chip->ecc.bytes;
202 const int pkt_size = chip->ecc.size;
205 for (i = 0; i < chip->ecc.steps; ++i) {
207 res = nand_check_erased_ecc_chunk(buf, pkt_size, ecc, ecc_size,
209 chip->ecc.strength);
217 ecc += ecc_size;
305 chip->ecc.read_oob(chip, page);
313 chip->ecc.read_oob_raw(chip, page);
405 const int ecc_size = chip->ecc.bytes;
406 const int pkt_size = chip->ecc.size;
432 const int ecc_size = chip->ecc.bytes;
433 const int pkt_size = chip->ecc.size;
491 struct nand_ecc_ctrl *ecc = &chip->ecc;
493 if (idx >= ecc->steps)
496 res->offset = BBM_SIZE + METADATA_SIZE + ecc->bytes * idx;
497 res->length = ecc->bytes;
508 .ecc = oob_ecc,
550 struct nand_ecc_ctrl *ecc = &chip->ecc;
552 ecc->engine_type = NAND_ECC_ENGINE_TYPE_ON_HOST;
553 ecc->algo = NAND_ECC_ALGO_BCH;
554 ecc->bytes = DIV_ROUND_UP(ecc->strength * FIELD_ORDER, BITS_PER_BYTE);
556 ecc->read_page_raw = tango_read_page_raw;
557 ecc->write_page_raw = tango_write_page_raw;
558 ecc->read_page = tango_read_page;
559 ecc->write_page = tango_write_page;
560 ecc->read_oob = tango_read_oob;
561 ecc->write_oob = tango_write_oob;
579 struct nand_ecc_ctrl *ecc;
601 ecc = &chip->ecc;
618 tchip->xfer_cfg = XFER_CFG(cs, 1, ecc->steps, METADATA_SIZE);
619 tchip->pkt_0_cfg = PKT_CFG(ecc->size + METADATA_SIZE, ecc->strength);
620 tchip->pkt_n_cfg = PKT_CFG(ecc->size, ecc->strength);