• Home
  • Raw
  • Download

Lines Matching refs:nand

362 int nand_ecc_sw_hamming_calculate(struct nand_device *nand,  in nand_ecc_sw_hamming_calculate()  argument
365 struct nand_ecc_sw_hamming_conf *engine_conf = nand->ecc.ctx.priv; in nand_ecc_sw_hamming_calculate()
366 unsigned int step_size = nand->ecc.ctx.conf.step_size; in nand_ecc_sw_hamming_calculate()
454 int nand_ecc_sw_hamming_correct(struct nand_device *nand, unsigned char *buf, in nand_ecc_sw_hamming_correct() argument
458 struct nand_ecc_sw_hamming_conf *engine_conf = nand->ecc.ctx.priv; in nand_ecc_sw_hamming_correct()
459 unsigned int step_size = nand->ecc.ctx.conf.step_size; in nand_ecc_sw_hamming_correct()
466 int nand_ecc_sw_hamming_init_ctx(struct nand_device *nand) in nand_ecc_sw_hamming_init_ctx() argument
468 struct nand_ecc_props *conf = &nand->ecc.ctx.conf; in nand_ecc_sw_hamming_init_ctx()
470 struct mtd_info *mtd = nanddev_to_mtd(nand); in nand_ecc_sw_hamming_init_ctx()
491 conf->step_size = nand->ecc.user_conf.step_size; in nand_ecc_sw_hamming_init_ctx()
502 ret = nand_ecc_init_req_tweaking(&engine_conf->req_ctx, nand); in nand_ecc_sw_hamming_init_ctx()
514 nand->ecc.ctx.priv = engine_conf; in nand_ecc_sw_hamming_init_ctx()
515 nand->ecc.ctx.nsteps = mtd->writesize / conf->step_size; in nand_ecc_sw_hamming_init_ctx()
516 nand->ecc.ctx.total = nand->ecc.ctx.nsteps * engine_conf->code_size; in nand_ecc_sw_hamming_init_ctx()
531 void nand_ecc_sw_hamming_cleanup_ctx(struct nand_device *nand) in nand_ecc_sw_hamming_cleanup_ctx() argument
533 struct nand_ecc_sw_hamming_conf *engine_conf = nand->ecc.ctx.priv; in nand_ecc_sw_hamming_cleanup_ctx()
544 static int nand_ecc_sw_hamming_prepare_io_req(struct nand_device *nand, in nand_ecc_sw_hamming_prepare_io_req() argument
547 struct nand_ecc_sw_hamming_conf *engine_conf = nand->ecc.ctx.priv; in nand_ecc_sw_hamming_prepare_io_req()
548 struct mtd_info *mtd = nanddev_to_mtd(nand); in nand_ecc_sw_hamming_prepare_io_req()
549 int eccsize = nand->ecc.ctx.conf.step_size; in nand_ecc_sw_hamming_prepare_io_req()
551 int eccsteps = nand->ecc.ctx.nsteps; in nand_ecc_sw_hamming_prepare_io_req()
552 int total = nand->ecc.ctx.total; in nand_ecc_sw_hamming_prepare_io_req()
575 nand_ecc_sw_hamming_calculate(nand, data, &ecccalc[i]); in nand_ecc_sw_hamming_prepare_io_req()
581 static int nand_ecc_sw_hamming_finish_io_req(struct nand_device *nand, in nand_ecc_sw_hamming_finish_io_req() argument
584 struct nand_ecc_sw_hamming_conf *engine_conf = nand->ecc.ctx.priv; in nand_ecc_sw_hamming_finish_io_req()
585 struct mtd_info *mtd = nanddev_to_mtd(nand); in nand_ecc_sw_hamming_finish_io_req()
586 int eccsize = nand->ecc.ctx.conf.step_size; in nand_ecc_sw_hamming_finish_io_req()
587 int total = nand->ecc.ctx.total; in nand_ecc_sw_hamming_finish_io_req()
589 int eccsteps = nand->ecc.ctx.nsteps; in nand_ecc_sw_hamming_finish_io_req()
618 nand_ecc_sw_hamming_calculate(nand, data, &ecccalc[i]); in nand_ecc_sw_hamming_finish_io_req()
621 for (eccsteps = nand->ecc.ctx.nsteps, i = 0, data = req->databuf.in; in nand_ecc_sw_hamming_finish_io_req()
624 int stat = nand_ecc_sw_hamming_correct(nand, data, in nand_ecc_sw_hamming_finish_io_req()