• Home
  • Raw
  • Download

Lines Matching refs:fec

23 	return v->fec && v->fec->dev;  in verity_fec_is_enabled()
42 mod = do_div(offset, v->fec->rsn); in fec_interleave()
43 return offset + mod * (v->fec->rounds << v->data_dev_block_bits); in fec_interleave()
50 u8 *data, u8 *fec, int neras) in fec_decode_rs8() argument
55 for (i = 0; i < v->fec->roots; i++) in fec_decode_rs8()
56 par[i] = fec[i]; in fec_decode_rs8()
58 return decode_rs8(fio->rs, data, par, v->fec->rsn, NULL, neras, in fec_decode_rs8()
72 position = (index + rsb) * v->fec->roots; in fec_read_parity()
76 res = dm_bufio_read(v->fec->bufio, v->fec->start + block, buf); in fec_read_parity()
80 (unsigned long long)(v->fec->start + block), in fec_read_parity()
113 return &fio->bufs[i][j * v->fec->rsn]; in fec_buffer_rs_block()
162 offset += v->fec->roots; in fec_decode_bufs()
182 atomic_add_unless(&v->fec->corrected, 1, INT_MAX); in fec_decode_bufs()
228 for (i = 0; i < v->fec->rsn; i++) { in fec_read_bufs()
229 ileaved = fec_interleave(v, rsb * v->fec->rsn + i); in fec_read_bufs()
239 bufio = v->fec->data_bufio; in fec_read_bufs()
248 if (unlikely(block >= v->fec->hash_blocks)) in fec_read_bufs()
263 if (neras && *neras <= v->fec->roots) in fec_read_bufs()
270 if (bufio == v->fec->data_bufio && in fec_read_bufs()
281 if (neras && *neras <= v->fec->roots && in fec_read_bufs()
315 fio->rs = mempool_alloc(v->fec->rs_pool, 0); in fec_alloc_bufs()
326 fio->bufs[n] = mempool_alloc(v->fec->prealloc_pool, GFP_NOIO); in fec_alloc_bufs()
338 fio->bufs[n] = mempool_alloc(v->fec->extra_pool, GFP_NOIO); in fec_alloc_bufs()
346 fio->output = mempool_alloc(v->fec->output_pool, GFP_NOIO); in fec_alloc_bufs()
366 memset(fio->bufs[n], 0, v->fec->rsn << DM_VERITY_FEC_BUF_RS_BITS); in fec_init_bufs()
466 res = div64_u64(offset, v->fec->rounds << v->data_dev_block_bits); in verity_fec_decode()
472 rsb = offset - res * (v->fec->rounds << v->data_dev_block_bits); in verity_fec_decode()
504 struct dm_verity_fec *f = io->v->fec; in verity_fec_finish_io()
551 v->fec->dev->name, in verity_fec_status_table()
552 (unsigned long long)v->fec->blocks, in verity_fec_status_table()
553 (unsigned long long)v->fec->start, in verity_fec_status_table()
554 v->fec->roots); in verity_fec_status_table()
561 struct dm_verity_fec *f = v->fec; in verity_fec_dtr()
587 v->fec = NULL; in verity_fec_dtr()
594 return init_rs(8, 0x11d, 0, 1, v->fec->roots); in fec_rs_alloc()
632 r = dm_get_device(ti, arg_value, FMODE_READ, &v->fec->dev); in verity_fec_parse_opt_args()
645 v->fec->blocks = num_ll; in verity_fec_parse_opt_args()
654 v->fec->start = num_ll; in verity_fec_parse_opt_args()
663 v->fec->roots = num_c; in verity_fec_parse_opt_args()
707 v->fec = f; in verity_fec_ctr_alloc()
719 struct dm_verity_fec *f = v->fec; in verity_fec_ctr()