From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id C0D4C2E8A; Wed, 12 Apr 2017 11:26:34 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Apr 2017 02:26:33 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,189,1488873600"; d="scan'208";a="844878639" Received: from silpixa00381631.ir.intel.com (HELO silpixa00381631.ger.corp.intel.com) ([10.237.222.122]) by FMSMGA003.fm.intel.com with ESMTP; 12 Apr 2017 02:26:32 -0700 From: Pablo de Lara To: dev@dpdk.org Cc: declan.doherty@intel.com, stable@dpdk.org, Pablo de Lara Date: Wed, 12 Apr 2017 10:26:26 +0100 Message-Id: <1491989186-159933-1-git-send-email-pablo.de.lara.guarch@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [dpdk-stable] [PATCH] app/crypto-perf: fix AEAD tests when AAD is zero X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Apr 2017 09:26:35 -0000 For AEAD algorithms, additional authenticated data (AAD) can be passed, but it is optional, so its size can be zero. Therefore, test can be run if no memory is allocated. Fixes: f8be1786b1b8 ("app/crypto-perf: introduce performance test application") Signed-off-by: Pablo de Lara --- app/test-crypto-perf/cperf_test_vectors.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test-crypto-perf/cperf_test_vectors.c b/app/test-crypto-perf/cperf_test_vectors.c index f87bb8e..757957f 100644 --- a/app/test-crypto-perf/cperf_test_vectors.c +++ b/app/test-crypto-perf/cperf_test_vectors.c @@ -463,7 +463,7 @@ cperf_test_vector_get_dummy(struct cperf_options *options) break; } - if (aad_alloc) { + if (aad_alloc && options->auth_aad_sz) { t_vec->aad.data = rte_malloc(NULL, options->auth_aad_sz, 16); if (t_vec->aad.data == NULL) { -- 2.7.4