When accel task is processed is processed in several iterations (submit part of cryops, wait for completion and submit next part of cryops), sgl is initialized with offset to exclude previously processed blocks. However there is a bug since spdk_iov_sgl_init doesn't advance iovs, as result when we do sgl->iov->iov_len - sgl->iov_offset, we may get unsigned int underflow. Fix is init sgl with 0 offset and then advance it with offset. Modified unit test and added an assert in code to verify this fix. Signed-off-by: Alexey Marchuk <alexeymar@nvidia.com> Change-Id: Ib53ff30f0c90d521f2cf6b3ec847b0d06869c2b5 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/17456 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Community-CI: Mellanox Build Bot Reviewed-by: Jim Harris <james.r.harris@intel.com> |
||
---|---|---|
.. | ||
accel_dpdk_cryptodev_rpc.c | ||
accel_dpdk_cryptodev.c | ||
accel_dpdk_cryptodev.h | ||
Makefile |