X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=app%2Ftest-crypto-perf%2Fcperf_ops.c;fp=app%2Ftest-crypto-perf%2Fcperf_ops.c;h=17df2eb46921e007c3722140ce4d242bcc80ed70;hb=90fb1fd9c01fbb2f44af75c63adb65d721da88ff;hp=c2c3db572f1917c5ee8bdca1d9375fae6c2a3d22;hpb=bf7567fd2a5b0b28ab724046143c24561d38d015;p=deb_dpdk.git diff --git a/app/test-crypto-perf/cperf_ops.c b/app/test-crypto-perf/cperf_ops.c index c2c3db57..17df2eb4 100644 --- a/app/test-crypto-perf/cperf_ops.c +++ b/app/test-crypto-perf/cperf_ops.c @@ -151,14 +151,13 @@ cperf_set_ops_auth(struct rte_crypto_op **ops, if (options->out_of_place) { buf = bufs_out[i]; } else { - buf = bufs_in[i]; - - tbuf = buf; + tbuf = bufs_in[i]; while ((tbuf->next != NULL) && (offset >= tbuf->data_len)) { offset -= tbuf->data_len; tbuf = tbuf->next; } + buf = tbuf; } sym_op->auth.digest.data = rte_pktmbuf_mtod_offset(buf, @@ -230,14 +229,13 @@ cperf_set_ops_cipher_auth(struct rte_crypto_op **ops, if (options->out_of_place) { buf = bufs_out[i]; } else { - buf = bufs_in[i]; - - tbuf = buf; + tbuf = bufs_in[i]; while ((tbuf->next != NULL) && (offset >= tbuf->data_len)) { offset -= tbuf->data_len; tbuf = tbuf->next; } + buf = tbuf; } sym_op->auth.digest.data = rte_pktmbuf_mtod_offset(buf, @@ -308,14 +306,13 @@ cperf_set_ops_aead(struct rte_crypto_op **ops, if (options->out_of_place) { buf = bufs_out[i]; } else { - buf = bufs_in[i]; - - tbuf = buf; + tbuf = bufs_in[i]; while ((tbuf->next != NULL) && (offset >= tbuf->data_len)) { offset -= tbuf->data_len; tbuf = tbuf->next; } + buf = tbuf; } sym_op->auth.digest.data = rte_pktmbuf_mtod_offset(buf,