[dpdk-dev,v2,2/3] app/test: move pre-counter block computation from test files

Message ID 1474541155-29367-3-git-send-email-arkadiuszx.kusztal@intel.com (mailing list archive)
State Accepted, archived
Delegated to: Pablo de Lara Guarch
Headers

Commit Message

Arkadiusz Kusztal Sept. 22, 2016, 10:45 a.m. UTC
  This patch removes pre-counter block computation from
test_cryptodev.c file for AES GCM

Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Deepak Kumar Jain <deepak.k.jain@intel.com>
---
 app/test/test_cryptodev.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
  

Patch

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index ae5fa1d..db5606a 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -3259,14 +3259,10 @@  create_gcm_operation(enum rte_crypto_cipher_operation op,
 
 	memset(sym_op->cipher.iv.data, 0, iv_pad_len);
 	sym_op->cipher.iv.phys_addr = rte_pktmbuf_mtophys(ut_params->ibuf);
-	sym_op->cipher.iv.length = iv_pad_len;
+	sym_op->cipher.iv.length = iv_len;
 
 	rte_memcpy(sym_op->cipher.iv.data, iv, iv_len);
 
-	/* CalcY0 */
-	if (iv_len != 16)
-		sym_op->cipher.iv.data[15] = 1;
-
 	/*
 	 * Always allocate the aad up to the block size.
 	 * The cryptodev API calls out -