diff --git a/lib/accel/accel_engine.c b/lib/accel/accel_engine.c index b935ea5af1..5f4f644b5e 100644 --- a/lib/accel/accel_engine.c +++ b/lib/accel/accel_engine.c @@ -312,7 +312,7 @@ spdk_accel_submit_crc32c(struct spdk_io_channel *ch, uint32_t *crc_dst, void *sr return -ENOMEM; } - accel_task->dst = (void *)crc_dst; + accel_task->crc_dst = crc_dst; accel_task->src = src; accel_task->v.iovcnt = 0; accel_task->seed = seed; @@ -345,8 +345,8 @@ crc32cv_done(void *cb_arg, int status) ~(*((uint32_t *)accel_task->crc_dst)), accel_task->chained.cb_fn, accel_task->chained.cb_arg); } else { - status = spdk_accel_submit_crc32cv(ch, accel_task->dst, ++accel_task->v.iovs, - accel_task->v.iovcnt - 1, ~(*((uint32_t *)accel_task->dst)), + status = spdk_accel_submit_crc32cv(ch, accel_task->crc_dst, ++accel_task->v.iovs, + accel_task->v.iovcnt - 1, ~(*((uint32_t *)accel_task->crc_dst)), accel_task->chained.cb_fn, accel_task->chained.cb_arg); } @@ -390,7 +390,7 @@ spdk_accel_submit_crc32cv(struct spdk_io_channel *ch, uint32_t *crc_dst, struct accel_task->v.iovs = iov; accel_task->v.iovcnt = iov_cnt; - accel_task->dst = (void *)crc_dst; + accel_task->crc_dst = crc_dst; accel_task->seed = seed; accel_task->op_code = ACCEL_OPCODE_CRC32C; @@ -635,7 +635,7 @@ spdk_accel_batch_prep_crc32c(struct spdk_io_channel *ch, struct spdk_accel_batch return -ENOMEM; } - accel_task->dst = crc_dst; + accel_task->crc_dst = crc_dst; accel_task->src = src; accel_task->v.iovcnt = 0; accel_task->seed = seed; @@ -664,8 +664,9 @@ batched_crc32cv_done(void *cb_arg, int status) assert(accel_task->chained.cb_arg != NULL); if (spdk_likely(!status)) { - status = spdk_accel_batch_prep_crc32cv(ch, batch, accel_task->dst, - ++accel_task->v.iovs, accel_task->v.iovcnt - 1, ~(*((uint32_t *)accel_task->dst)), + status = spdk_accel_batch_prep_crc32cv(ch, batch, accel_task->crc_dst, + ++accel_task->v.iovs, accel_task->v.iovcnt - 1, + ~(*((uint32_t *)accel_task->crc_dst)), accel_task->chained.cb_fn, accel_task->chained.cb_arg); if (spdk_likely(!status)) { return; @@ -707,7 +708,7 @@ spdk_accel_batch_prep_crc32cv(struct spdk_io_channel *ch, struct spdk_accel_batc accel_task->v.iovs = iovs; accel_task->v.iovcnt = iov_cnt; - accel_task->dst = crc_dst; + accel_task->crc_dst = crc_dst; accel_task->seed = seed; accel_task->op_code = ACCEL_OPCODE_CRC32C; diff --git a/module/accel/idxd/accel_engine_idxd.c b/module/accel/idxd/accel_engine_idxd.c index 107af77ae2..5babc47ae9 100644 --- a/module/accel/idxd/accel_engine_idxd.c +++ b/module/accel/idxd/accel_engine_idxd.c @@ -164,7 +164,7 @@ _process_single_task(struct spdk_io_channel *ch, struct spdk_accel_task *task) break; case ACCEL_OPCODE_CRC32C: src = (task->v.iovcnt == 0) ? task->src : task->v.iovs[0].iov_base; - rc = spdk_idxd_submit_crc32c(chan->chan, task->dst, src, task->seed, task->nbytes, idxd_done, + rc = spdk_idxd_submit_crc32c(chan->chan, task->crc_dst, src, task->seed, task->nbytes, idxd_done, task); break; case ACCEL_OPCODE_COPY_CRC32C: