DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] app/test: improve error message in crypto test code
@ 2016-09-16 14:37 Fiona Trahe
  2016-09-16 15:50 ` Trahe, Fiona
  2016-09-26 12:57 ` [dpdk-dev] [PATCH v2] " Fiona Trahe
  0 siblings, 2 replies; 5+ messages in thread
From: Fiona Trahe @ 2016-09-16 14:37 UTC (permalink / raw)
  To: dev; +Cc: pablo.de.lara.guarch, fiona.trahe

Resending patch as first send got to mailing list but didn't get to pachwork


Improve error message if crypto PMD build is not enabled in config file

Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
---
 app/test/test_cryptodev.c      | 37 +++++++++++++++++++++++++++++++++++++
 app/test/test_cryptodev_perf.c | 23 +++++++++++++++++++++++
 2 files changed, 60 insertions(+)

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index f17c84c..c30a421 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -189,6 +189,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
@@ -206,6 +211,11 @@ testsuite_setup(void)
 
 	/* Create 2 LIBCRYPTO devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_LIBCRYPTO_PMD) {
+#ifndef RTE_LIBRTE_PMD_LIBCRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_LIBCRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_LIBCRYPTO_PMD);
 		if (nb_devs < 2) {
@@ -223,6 +233,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI GCM devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_GCM_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_GCM
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_GCM must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_GCM_PMD);
 		if (nb_devs < 2) {
@@ -238,6 +253,11 @@ testsuite_setup(void)
 
 	/* Create 2 Snow3G devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -252,6 +272,11 @@ testsuite_setup(void)
 
 	/* Create 2 KASUMI devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_KASUMI_PMD) {
+#ifndef RTE_LIBRTE_PMD_KASUMI
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_KASUMI must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_KASUMI_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -266,6 +291,11 @@ testsuite_setup(void)
 
 	/* Create 2 NULL devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_NULL_PMD) {
+#ifndef RTE_LIBRTE_PMD_NULL_CRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_NULL_CRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_NULL_PMD);
 		if (nb_devs < 2) {
@@ -281,6 +311,13 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_type == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
 
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
diff --git a/app/test/test_cryptodev_perf.c b/app/test/test_cryptodev_perf.c
index 0a0085d..c80c335 100644
--- a/app/test/test_cryptodev_perf.c
+++ b/app/test/test_cryptodev_perf.c
@@ -261,6 +261,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -276,6 +281,11 @@ testsuite_setup(void)
 
 	/* Create 2 SNOW3G devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -291,6 +301,11 @@ testsuite_setup(void)
 
 	/* Create 2 LIBCRYPTO devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_LIBCRYPTO_PMD) {
+#ifndef RTE_LIBRTE_PMD_LIBCRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_LIBCRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_LIBCRYPTO_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -304,6 +319,14 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
+
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
 		RTE_LOG(ERR, USER1, "No crypto devices found?\n");
-- 
2.5.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [PATCH] app/test: improve error message in crypto test code
  2016-09-16 14:37 [dpdk-dev] [PATCH] app/test: improve error message in crypto test code Fiona Trahe
@ 2016-09-16 15:50 ` Trahe, Fiona
  2016-09-26 12:57 ` [dpdk-dev] [PATCH v2] " Fiona Trahe
  1 sibling, 0 replies; 5+ messages in thread
From: Trahe, Fiona @ 2016-09-16 15:50 UTC (permalink / raw)
  To: dev; +Cc: De Lara Guarch, Pablo, Trahe, Fiona



> -----Original Message-----
> From: Trahe, Fiona
> Sent: Friday, September 16, 2016 3:37 PM
> To: dev@dpdk.org
> Cc: De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>; Trahe, Fiona
> <fiona.trahe@intel.com>
> Subject: [PATCH] app/test: improve error message in crypto test code
> 
> Resending patch as first send got to mailing list but didn't get to pachwork
> 
> 
> Improve error message if crypto PMD build is not enabled in config file
> 
> Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>


Nack -  This patch will need rebasing after the libcrypto patchset.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [dpdk-dev] [PATCH v2] app/test: improve error message in crypto test code
  2016-09-16 14:37 [dpdk-dev] [PATCH] app/test: improve error message in crypto test code Fiona Trahe
  2016-09-16 15:50 ` Trahe, Fiona
@ 2016-09-26 12:57 ` Fiona Trahe
  2016-09-26 22:32   ` De Lara Guarch, Pablo
  1 sibling, 1 reply; 5+ messages in thread
From: Fiona Trahe @ 2016-09-26 12:57 UTC (permalink / raw)
  To: dev; +Cc: pablo.de.lara.guarch, fiona.trahe

Improve error message if crypto PMD build is not enabled in config file

Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
---
 app/test/test_cryptodev.c      | 33 +++++++++++++++++++++++++++++++++
 app/test/test_cryptodev_perf.c | 18 ++++++++++++++++++
 2 files changed, 51 insertions(+)

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index d744b37..77cf8a2 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -182,6 +182,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
@@ -199,6 +204,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI GCM devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_GCM_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_GCM
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_GCM must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_GCM_PMD);
 		if (nb_devs < 2) {
@@ -214,6 +224,11 @@ testsuite_setup(void)
 
 	/* Create 2 SNOW 3G devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -228,6 +243,11 @@ testsuite_setup(void)
 
 	/* Create 2 KASUMI devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_KASUMI_PMD) {
+#ifndef RTE_LIBRTE_PMD_KASUMI
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_KASUMI must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_KASUMI_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -242,6 +262,11 @@ testsuite_setup(void)
 
 	/* Create 2 NULL devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_NULL_PMD) {
+#ifndef RTE_LIBRTE_PMD_NULL_CRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_NULL_CRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_NULL_PMD);
 		if (nb_devs < 2) {
@@ -257,6 +282,14 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_type == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
+
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
 		RTE_LOG(ERR, USER1, "No crypto devices found?");
diff --git a/app/test/test_cryptodev_perf.c b/app/test/test_cryptodev_perf.c
index 20713d4..b97ab7e 100644
--- a/app/test/test_cryptodev_perf.c
+++ b/app/test/test_cryptodev_perf.c
@@ -245,6 +245,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -260,6 +265,11 @@ testsuite_setup(void)
 
 	/* Create 2 SNOW3G devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -273,6 +283,14 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
+
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
 		RTE_LOG(ERR, USER1, "No crypto devices found?");
-- 
2.5.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [PATCH v2] app/test: improve error message in crypto test code
  2016-09-26 12:57 ` [dpdk-dev] [PATCH v2] " Fiona Trahe
@ 2016-09-26 22:32   ` De Lara Guarch, Pablo
  0 siblings, 0 replies; 5+ messages in thread
From: De Lara Guarch, Pablo @ 2016-09-26 22:32 UTC (permalink / raw)
  To: Trahe, Fiona, dev



> -----Original Message-----
> From: Trahe, Fiona
> Sent: Monday, September 26, 2016 5:57 AM
> To: dev@dpdk.org
> Cc: De Lara Guarch, Pablo; Trahe, Fiona
> Subject: [PATCH v2] app/test: improve error message in crypto test code
> 
> Improve error message if crypto PMD build is not enabled in config file
> 
> Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
> ---

Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [dpdk-dev] [PATCH] app/test: improve error message in crypto test code
@ 2016-09-16 12:01 Fiona Trahe
  0 siblings, 0 replies; 5+ messages in thread
From: Fiona Trahe @ 2016-09-16 12:01 UTC (permalink / raw)
  To: dev; +Cc: pablo.de.lara.guarch, fiona.trahe

From: Fiona Trahe <fiona.trahe@intel.com>

Improve error message if crypto PMD build is not enabled in config file

Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
---
 app/test/test_cryptodev.c      | 37 +++++++++++++++++++++++++++++++++++++
 app/test/test_cryptodev_perf.c | 23 +++++++++++++++++++++++
 2 files changed, 60 insertions(+)

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index f17c84c..c30a421 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -189,6 +189,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
@@ -206,6 +211,11 @@ testsuite_setup(void)
 
 	/* Create 2 LIBCRYPTO devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_LIBCRYPTO_PMD) {
+#ifndef RTE_LIBRTE_PMD_LIBCRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_LIBCRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_LIBCRYPTO_PMD);
 		if (nb_devs < 2) {
@@ -223,6 +233,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI GCM devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_AESNI_GCM_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_GCM
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_GCM must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_AESNI_GCM_PMD);
 		if (nb_devs < 2) {
@@ -238,6 +253,11 @@ testsuite_setup(void)
 
 	/* Create 2 Snow3G devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -252,6 +272,11 @@ testsuite_setup(void)
 
 	/* Create 2 KASUMI devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_KASUMI_PMD) {
+#ifndef RTE_LIBRTE_PMD_KASUMI
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_KASUMI must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_KASUMI_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -266,6 +291,11 @@ testsuite_setup(void)
 
 	/* Create 2 NULL devices if required */
 	if (gbl_cryptodev_type == RTE_CRYPTODEV_NULL_PMD) {
+#ifndef RTE_LIBRTE_PMD_NULL_CRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_NULL_CRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(
 				RTE_CRYPTODEV_NULL_PMD);
 		if (nb_devs < 2) {
@@ -281,6 +311,13 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_type == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
 
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
diff --git a/app/test/test_cryptodev_perf.c b/app/test/test_cryptodev_perf.c
index 0a0085d..c80c335 100644
--- a/app/test/test_cryptodev_perf.c
+++ b/app/test/test_cryptodev_perf.c
@@ -261,6 +261,11 @@ testsuite_setup(void)
 
 	/* Create 2 AESNI MB devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_AESNI_MB_PMD) {
+#ifndef RTE_LIBRTE_PMD_AESNI_MB
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_AESNI_MB must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_AESNI_MB_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -276,6 +281,11 @@ testsuite_setup(void)
 
 	/* Create 2 SNOW3G devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_SNOW3G_PMD) {
+#ifndef RTE_LIBRTE_PMD_SNOW3G
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_SNOW3G must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_SNOW3G_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -291,6 +301,11 @@ testsuite_setup(void)
 
 	/* Create 2 LIBCRYPTO devices if required */
 	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_LIBCRYPTO_PMD) {
+#ifndef RTE_LIBRTE_PMD_LIBCRYPTO
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_LIBCRYPTO must be"
+			" enabled in config file to run this testsuite.\n");
+		return TEST_FAILED;
+#endif
 		nb_devs = rte_cryptodev_count_devtype(RTE_CRYPTODEV_LIBCRYPTO_PMD);
 		if (nb_devs < 2) {
 			for (i = nb_devs; i < 2; i++) {
@@ -304,6 +319,14 @@ testsuite_setup(void)
 		}
 	}
 
+#ifndef RTE_LIBRTE_PMD_QAT
+	if (gbl_cryptodev_perftest_devtype == RTE_CRYPTODEV_QAT_SYM_PMD) {
+		RTE_LOG(ERR, USER1, "CONFIG_RTE_LIBRTE_PMD_QAT must be enabled "
+				"in config file to run this testsuite.\n");
+		return TEST_FAILED;
+	}
+#endif
+
 	nb_devs = rte_cryptodev_count();
 	if (nb_devs < 1) {
 		RTE_LOG(ERR, USER1, "No crypto devices found?\n");
-- 
2.5.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-09-26 22:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-16 14:37 [dpdk-dev] [PATCH] app/test: improve error message in crypto test code Fiona Trahe
2016-09-16 15:50 ` Trahe, Fiona
2016-09-26 12:57 ` [dpdk-dev] [PATCH v2] " Fiona Trahe
2016-09-26 22:32   ` De Lara Guarch, Pablo
  -- strict thread matches above, loose matches on Subject: below --
2016-09-16 12:01 [dpdk-dev] [PATCH] " Fiona Trahe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).