Lines Matching defs:cw

764 /* Helper to check the code word, whether it is last cw or not */
765 static bool qcom_nandc_is_last_cw(struct nand_ecc_ctrl *ecc, int cw)
767 return cw == (ecc->steps - 1);
771 static void nandc_set_read_loc(struct nand_chip *chip, int cw, int reg,
778 if (nandc->props->qpic_v2 && qcom_nandc_is_last_cw(ecc, cw))
783 if (nandc->props->qpic_v2 && qcom_nandc_is_last_cw(ecc, cw))
809 * @cw : which code word
811 static void update_rw_regs(struct qcom_nand_host *host, int num_cw, bool read, int cw)
851 nandc_set_read_loc(chip, cw, 0, 0, host->use_ecc ?
1237 config_nand_cw_read(struct nand_chip *chip, bool use_ecc, int cw)
1244 if (nandc->props->qpic_v2 && qcom_nandc_is_last_cw(ecc, cw))
1268 bool use_ecc, int cw)
1271 config_nand_cw_read(chip, use_ecc, cw);
1464 u8 *data_buf, u8 *oob_buf, int page, int cw)
1471 int raw_cw = cw;
1483 set_address(host, host->cw_size * cw, page);
1490 if (qcom_nandc_is_last_cw(ecc, cw) && !host->codeword_fixup) {
1501 nandc_set_read_loc(chip, cw, 0, read_loc, data_size1, 0);
1504 nandc_set_read_loc(chip, cw, 1, read_loc, oob_size1, 0);
1507 nandc_set_read_loc(chip, cw, 2, read_loc, data_size2, 0);
1510 nandc_set_read_loc(chip, cw, 3, read_loc, oob_size2, 1);
1528 dev_err(nandc->dev, "failure to read raw cw %d\n", cw);
1559 int cw, data_size, oob_size, ret;
1569 for_each_set_bit(cw, &uncorrectable_cws, ecc->steps) {
1570 if (qcom_nandc_is_last_cw(ecc, cw) && !host->codeword_fixup) {
1579 cw_data_buf = data_buf + (cw * host->cw_data);
1580 cw_oob_buf = oob_buf + (cw * ecc->bytes);
1583 cw_oob_buf, page, cw);
1919 int cw, ret;
1925 for (cw = 0; cw < ecc->steps; cw++) {
1927 page, cw);