From: Herbert Xu Date: Wed, 17 Jun 2015 06:04:21 +0000 (+0800) Subject: crypto: tcrypt - Add rfc4309(ccm(aes)) speed test X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4e4aab63d7456fb3db108ad8eead8e330d5fb958;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git crypto: tcrypt - Add rfc4309(ccm(aes)) speed test This patch adds a speed test for rfc4309(ccm(aes)) as mode 212. Signed-off-by: Herbert Xu --- diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c index 4b4a9313f308..5146367f4a1f 100644 --- a/crypto/tcrypt.c +++ b/crypto/tcrypt.c @@ -1761,6 +1761,11 @@ static int do_test(const char *alg, u32 type, u32 mask, int m) NULL, 0, 16, 8, aead_speed_template_20); break; + case 212: + test_aead_speed("rfc4309(ccm(aes))", ENCRYPT, sec, + NULL, 0, 16, 8, aead_speed_template_19); + break; + case 300: if (alg) { test_hash_speed(alg, sec, generic_hash_speed_template); diff --git a/crypto/tcrypt.h b/crypto/tcrypt.h index 6c7e21a09f78..6cc1b856871b 100644 --- a/crypto/tcrypt.h +++ b/crypto/tcrypt.h @@ -65,6 +65,7 @@ static u8 speed_template_32_64[] = {32, 64, 0}; /* * AEAD speed tests */ +static u8 aead_speed_template_19[] = {19, 0}; static u8 aead_speed_template_20[] = {20, 0}; /*