[PATCH v3 23/31] app/test-crypto-perf: rename local vars to fix shadowing
Bruce Richardson
bruce.richardson at intel.com
Mon Dec 1 12:44:40 CET 2025
The global variable iv_offset was shadowed by a local var. Rename the
local variable to a shorter form to solve the issue.
Signed-off-by: Bruce Richardson <bruce.richardson at intel.com>
Acked-by: Stephen Hemminger <stephen at networkplumber.org>
---
app/test-crypto-perf/cperf_test_pmd_cyclecount.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/app/test-crypto-perf/cperf_test_pmd_cyclecount.c b/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
index 07a842f40a..5e3153b9dd 100644
--- a/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
+++ b/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
@@ -111,15 +111,13 @@ cperf_pmd_cyclecount_test_constructor(struct rte_mempool *sess_mp,
ctx->test_vector = test_vector;
/* IV goes at the end of the crypto operation */
- uint16_t iv_offset = sizeof(struct rte_crypto_op) +
- sizeof(struct rte_crypto_sym_op);
+ uint16_t iv_ofs = sizeof(struct rte_crypto_op) + sizeof(struct rte_crypto_sym_op);
if (*sess != NULL) {
ctx->sess = *sess;
ctx->sess_owner = false;
} else {
- ctx->sess = op_fns->sess_create(sess_mp, dev_id, options, test_vector,
- iv_offset);
+ ctx->sess = op_fns->sess_create(sess_mp, dev_id, options, test_vector, iv_ofs);
if (ctx->sess == NULL)
goto err;
*sess = ctx->sess;
--
2.51.0
More information about the dev
mailing list