Lines Matching refs:ctx

1154 		instrs[0].ctx.cmd.opcode = NAND_CMD_READOOB;
1157 instrs[0].ctx.cmd.opcode = NAND_CMD_READ1;
1168 instrs[1].ctx.addr.naddrs++;
1205 instrs[1].ctx.addr.naddrs++;
1271 start_instrs[1].ctx.addr.naddrs++;
1455 instrs[3].ctx.data.force_8bit = force_8bit;
1538 instrs[2].ctx.addr.naddrs = naddrs;
1555 instrs[0].ctx.cmd.opcode = NAND_CMD_READOOB;
1558 instrs[0].ctx.cmd.opcode = NAND_CMD_READ1;
1758 instrs[2].ctx.data.force_8bit = force_8bit;
1815 instrs[2].ctx.data.len *= 2;
1816 instrs[2].ctx.data.buf.in = ddrbuf;
1870 instrs[1].ctx.data.len *= 2;
1871 instrs[1].ctx.data.buf.in = ddrstatus;
1953 instrs[1].ctx.addr.naddrs++;
2065 instrs[3].ctx.data.len *= 2;
2066 instrs[3].ctx.data.buf.in = ddrbuf;
2170 instrs[0].ctx.data.force_8bit = force_8bit;
2184 instrs[0].ctx.data.len *= 2;
2185 instrs[0].ctx.data.buf.in = ddrbuf;
2249 instrs[0].ctx.data.force_8bit = force_8bit;
2310 if (!pat->ctx.addr.maxcycles)
2313 if (instr->ctx.addr.naddrs - *start_offset >
2314 pat->ctx.addr.maxcycles) {
2315 *start_offset += pat->ctx.addr.maxcycles;
2322 if (!pat->ctx.data.maxlen)
2325 if (instr->ctx.data.len - *start_offset >
2326 pat->ctx.data.maxlen) {
2327 *start_offset += pat->ctx.data.maxlen;
2343 * @ctx: the parser context structure to match with the pattern @pat
2345 * Check if @pat matches the set or a sub-set of instructions remaining in @ctx.
2347 * @ctx->subop is updated with the set of instructions to be passed to the
2352 struct nand_op_parser_ctx *ctx)
2354 unsigned int instr_offset = ctx->subop.first_instr_start_off;
2355 const struct nand_op_instr *end = ctx->instrs + ctx->ninstrs;
2356 const struct nand_op_instr *instr = ctx->subop.instrs;
2417 ctx->subop.ninstrs = ninstrs;
2418 ctx->subop.last_instr_end_off = instr_offset;
2424 static void nand_op_parser_trace(const struct nand_op_parser_ctx *ctx)
2430 pr_debug("executing subop (CS%d):\n", ctx->subop.cs);
2432 for (i = 0; i < ctx->ninstrs; i++) {
2433 instr = &ctx->instrs[i];
2435 if (instr == &ctx->subop.instrs[0])
2440 if (instr == &ctx->subop.instrs[ctx->subop.ninstrs - 1])
2445 static void nand_op_parser_trace(const struct nand_op_parser_ctx *ctx)
2493 struct nand_op_parser_ctx ctx = {
2501 while (ctx.subop.instrs < op->instrs + op->ninstrs) {
2507 struct nand_op_parser_ctx test_ctx = ctx;
2526 ctx = best_ctx;
2527 nand_op_parser_trace(&ctx);
2531 ret = pattern->exec(chip, &ctx.subop);
2540 ctx.subop.instrs = ctx.subop.instrs + ctx.subop.ninstrs;
2541 if (ctx.subop.last_instr_end_off)
2542 ctx.subop.instrs -= 1;
2544 ctx.subop.first_instr_start_off = ctx.subop.last_instr_end_off;
2620 end_off = subop->instrs[instr_idx].ctx.addr.naddrs;
2674 end_off = subop->instrs[instr_idx].ctx.data.len;
5735 engine_conf = base->ecc.ctx.priv;
5740 chip->ecc.size = base->ecc.ctx.conf.step_size;
5741 chip->ecc.strength = base->ecc.ctx.conf.strength;
5742 chip->ecc.total = base->ecc.ctx.total;
5744 chip->ecc.bytes = base->ecc.ctx.total / nanddev_get_ecc_nsteps(base);
5796 chip->ecc.total = base->ecc.ctx.total;
5798 chip->ecc.bytes = base->ecc.ctx.total / nanddev_get_ecc_nsteps(base);
6431 chip->base.ecc.ctx.total = ecc->total;