test/crypto: add MRVL to hash test cases
authorTomasz Duszynski <tdu@semihalf.com>
Wed, 14 Mar 2018 13:12:54 +0000 (14:12 +0100)
committerPablo de Lara <pablo.de.lara.guarch@intel.com>
Mon, 23 Apr 2018 15:57:55 +0000 (16:57 +0100)
MRVL Crypto PMD supports most of the hash algorithms covered
by test suites thus specific bits should be set in pmd_masks.

Otherwise blockcipher authonly test returns success even though no
real tests have been executed.

Fixes: 84e0ded38ac5 ("test/crypto: add mrvl crypto unit tests")
Cc: stable@dpdk.org
Signed-off-by: Tomasz Duszynski <tdu@semihalf.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
test/test/test_cryptodev_hash_test_vectors.h

index 93dacb7..df9202f 100644 (file)
@@ -324,13 +324,15 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                .test_descr = "MD5 Digest",
                .test_data = &md5_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "MD5 Digest Verify",
                .test_data = &md5_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-MD5 Digest",
@@ -341,7 +343,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-MD5 Digest Verify",
@@ -352,19 +355,22 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA1 Digest",
                .test_data = &sha1_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA1 Digest Verify",
                .test_data = &sha1_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA1 Digest",
@@ -375,7 +381,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA1 Digest Scatter Gather",
@@ -394,7 +401,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA1 Digest Verify Scatter Gather",
@@ -408,13 +416,15 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                .test_descr = "SHA224 Digest",
                .test_data = &sha224_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA224 Digest Verify",
                .test_data = &sha224_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA224 Digest",
@@ -442,13 +452,15 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                .test_descr = "SHA256 Digest",
                .test_data = &sha256_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA256 Digest Verify",
                .test_data = &sha256_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA256 Digest",
@@ -459,7 +471,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA256 Digest Verify",
@@ -470,19 +483,22 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA384 Digest",
                .test_data = &sha384_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA384 Digest Verify",
                .test_data = &sha384_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA384 Digest",
@@ -493,7 +509,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA384 Digest Verify",
@@ -504,19 +521,22 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA512 Digest",
                .test_data = &sha512_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "SHA512 Digest Verify",
                .test_data = &sha512_test_vector,
                .op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
-               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL
+               .pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+                           BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA512 Digest",
@@ -527,7 +547,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
        {
                .test_descr = "HMAC-SHA512 Digest Verify",
@@ -538,7 +559,8 @@ static const struct blockcipher_test_case hash_test_cases[] = {
                        BLOCKCIPHER_TEST_TARGET_PMD_SCHEDULER |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA2_SEC |
                        BLOCKCIPHER_TEST_TARGET_PMD_DPAA_SEC |
-                       BLOCKCIPHER_TEST_TARGET_PMD_QAT
+                       BLOCKCIPHER_TEST_TARGET_PMD_QAT |
+                       BLOCKCIPHER_TEST_TARGET_PMD_MRVL
        },
 };