summaryrefslogtreecommitdiffstats
path: root/crypto/testmgr.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-12-15 12:35:19 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2012-12-15 12:35:19 -0800
commit1ed55eac3b1fc30b29cdb52251e0f13b24fc344c (patch)
treeb7a4c67f2e29f8aa418708c5da871e64c511f3ff /crypto/testmgr.c
parent08242bc2210938761230f79c5288dbcf72e94808 (diff)
parenta2c0911c09190125f52c9941b9d187f601c2f7be (diff)
downloadlinux-1ed55eac3b1fc30b29cdb52251e0f13b24fc344c.tar.gz
linux-1ed55eac3b1fc30b29cdb52251e0f13b24fc344c.tar.bz2
linux-1ed55eac3b1fc30b29cdb52251e0f13b24fc344c.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto update from Herbert Xu: - Added aesni/avx/x86_64 implementations for camellia. - Optimised AVX code for cast5/serpent/twofish/cast6. - Fixed vmac bug with unaligned input. - Allow compression algorithms in FIPS mode. - Optimised crc32c implementation for Intel. - Misc fixes. * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (32 commits) crypto: caam - Updated SEC-4.0 device tree binding for ERA information. crypto: testmgr - remove superfluous initializers for xts(aes) crypto: testmgr - allow compression algs in fips mode crypto: testmgr - add larger crc32c test vector to test FPU path in crc32c_intel crypto: testmgr - clean alg_test_null entries in alg_test_descs[] crypto: testmgr - remove fips_allowed flag from camellia-aesni null-tests crypto: cast5/cast6 - move lookup tables to shared module padata: use __this_cpu_read per-cpu helper crypto: s5p-sss - Fix compilation error crypto: picoxcell - Add terminating entry for platform_device_id table crypto: omap-aes - select BLKCIPHER2 crypto: camellia - add AES-NI/AVX/x86_64 assembler implementation of camellia cipher crypto: camellia-x86_64 - share common functions and move structures and function definitions to header file crypto: tcrypt - add async speed test for camellia cipher crypto: tegra-aes - fix error-valued pointer dereference crypto: tegra - fix missing unlock on error case crypto: cast5/avx - avoid using temporary stack buffers crypto: serpent/avx - avoid using temporary stack buffers crypto: twofish/avx - avoid using temporary stack buffers crypto: cast6/avx - avoid using temporary stack buffers ...
Diffstat (limited to 'crypto/testmgr.c')
-rw-r--r--crypto/testmgr.c369
1 files changed, 45 insertions, 324 deletions
diff --git a/crypto/testmgr.c b/crypto/testmgr.c
index 941d75cd1f7c..edf4a0818773 100644
--- a/crypto/testmgr.c
+++ b/crypto/testmgr.c
@@ -1638,270 +1638,66 @@ static const struct alg_test_desc alg_test_descs[] = {
{
.alg = "__cbc-cast5-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__cbc-cast6-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__cbc-serpent-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__cbc-serpent-sse2",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__cbc-twofish-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-cbc-aes-aesni",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
+ }, {
+ .alg = "__driver-cbc-camellia-aesni",
+ .test = alg_test_null,
}, {
.alg = "__driver-cbc-cast5-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-cbc-cast6-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-cbc-serpent-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-cbc-serpent-sse2",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-cbc-twofish-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-ecb-aes-aesni",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
+ }, {
+ .alg = "__driver-ecb-camellia-aesni",
+ .test = alg_test_null,
}, {
.alg = "__driver-ecb-cast5-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-ecb-cast6-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-ecb-serpent-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-ecb-serpent-sse2",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__driver-ecb-twofish-avx",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "__ghash-pclmulqdqni",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .hash = {
- .vecs = NULL,
- .count = 0
- }
- }
}, {
.alg = "ansi_cprng",
.test = alg_test_cprng,
@@ -2130,135 +1926,39 @@ static const struct alg_test_desc alg_test_descs[] = {
.alg = "cryptd(__driver-cbc-aes-aesni)",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
+ }, {
+ .alg = "cryptd(__driver-cbc-camellia-aesni)",
+ .test = alg_test_null,
}, {
.alg = "cryptd(__driver-ecb-aes-aesni)",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
+ }, {
+ .alg = "cryptd(__driver-ecb-camellia-aesni)",
+ .test = alg_test_null,
}, {
.alg = "cryptd(__driver-ecb-cast5-avx)",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__driver-ecb-cast6-avx)",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__driver-ecb-serpent-avx)",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__driver-ecb-serpent-sse2)",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__driver-ecb-twofish-avx)",
.test = alg_test_null,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__driver-gcm-aes-aesni)",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "cryptd(__ghash-pclmulqdqni)",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .hash = {
- .vecs = NULL,
- .count = 0
- }
- }
}, {
.alg = "ctr(aes)",
.test = alg_test_skcipher,
@@ -2336,6 +2036,36 @@ static const struct alg_test_desc alg_test_descs[] = {
}
}
}, {
+ .alg = "ctr(des)",
+ .test = alg_test_skcipher,
+ .suite = {
+ .cipher = {
+ .enc = {
+ .vecs = des_ctr_enc_tv_template,
+ .count = DES_CTR_ENC_TEST_VECTORS
+ },
+ .dec = {
+ .vecs = des_ctr_dec_tv_template,
+ .count = DES_CTR_DEC_TEST_VECTORS
+ }
+ }
+ }
+ }, {
+ .alg = "ctr(des3_ede)",
+ .test = alg_test_skcipher,
+ .suite = {
+ .cipher = {
+ .enc = {
+ .vecs = des3_ede_ctr_enc_tv_template,
+ .count = DES3_EDE_CTR_ENC_TEST_VECTORS
+ },
+ .dec = {
+ .vecs = des3_ede_ctr_dec_tv_template,
+ .count = DES3_EDE_CTR_DEC_TEST_VECTORS
+ }
+ }
+ }
+ }, {
.alg = "ctr(serpent)",
.test = alg_test_skcipher,
.suite = {
@@ -2383,6 +2113,7 @@ static const struct alg_test_desc alg_test_descs[] = {
}, {
.alg = "deflate",
.test = alg_test_comp,
+ .fips_allowed = 1,
.suite = {
.comp = {
.comp = {
@@ -2399,18 +2130,6 @@ static const struct alg_test_desc alg_test_descs[] = {
.alg = "ecb(__aes-aesni)",
.test = alg_test_null,
.fips_allowed = 1,
- .suite = {
- .cipher = {
- .enc = {
- .vecs = NULL,
- .count = 0
- },
- .dec = {
- .vecs = NULL,
- .count = 0
- }
- }
- }
}, {
.alg = "ecb(aes)",
.test = alg_test_skcipher,
@@ -2859,6 +2578,7 @@ static const struct alg_test_desc alg_test_descs[] = {
}, {
.alg = "lzo",
.test = alg_test_comp,
+ .fips_allowed = 1,
.suite = {
.comp = {
.comp = {
@@ -3226,6 +2946,7 @@ static const struct alg_test_desc alg_test_descs[] = {
}, {
.alg = "zlib",
.test = alg_test_pcomp,
+ .fips_allowed = 1,
.suite = {
.pcomp = {
.comp = {