In the latency test, when number of enqueued operations
is less than the burst size, the timestamp value of the
non-enqueued operations was being stored, even though
those operations were being freed.
This could cause an array overflow, since it could store
more values than the total number of operations.
Fixes:
5d75fb09d3be ("app/crypto-perf: fix invalid latency for QAT")
Cc: stable@dpdk.org
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
for (i = ops_enqd; i < burst_size; i++)
rte_crypto_op_free(ops[i]);
- for (i = 0; i < burst_size; i++) {
+ for (i = 0; i < ops_enqd; i++) {
ctx->res[tsc_idx].tsc_start = tsc_start;
ops[i]->opaque_data = (void *)&ctx->res[tsc_idx];
tsc_idx++;