]> git.karo-electronics.de Git - linux-beck.git/blobdiff - crypto/tcrypt.c
Merge branch 'for-4.3/sg' of git://git.kernel.dk/linux-block
[linux-beck.git] / crypto / tcrypt.c
index 73ed4f2c8e5d16f746ad946e58a271957f91298d..2b00b617daab537dba7657b6fbc569d440db931f 100644 (file)
@@ -344,12 +344,7 @@ static void test_aead_speed(const char *algo, int enc, unsigned int secs,
                goto out_nosg;
        sgout = &sg[9];
 
-       tfm = crypto_alloc_aead(algo, CRYPTO_ALG_AEAD_NEW,
-                               CRYPTO_ALG_AEAD_NEW);
-       if (PTR_ERR(tfm) == -ENOENT) {
-               aad_size -= 8;
-               tfm = crypto_alloc_aead(algo, 0, CRYPTO_ALG_AEAD_NEW);
-       }
+       tfm = crypto_alloc_aead(algo, 0, 0);
 
        if (IS_ERR(tfm)) {
                pr_err("alg: aead: Failed to load transform for %s: %ld\n", algo,
@@ -1793,6 +1788,17 @@ static int do_test(const char *alg, u32 type, u32 mask, int m)
                                NULL, 0, 16, 16, aead_speed_template_19);
                break;
 
+       case 213:
+               test_aead_speed("rfc7539esp(chacha20,poly1305)", ENCRYPT, sec,
+                               NULL, 0, 16, 8, aead_speed_template_36);
+               break;
+
+       case 214:
+               test_cipher_speed("chacha20", ENCRYPT, sec, NULL, 0,
+                                 speed_template_32);
+               break;
+
+
        case 300:
                if (alg) {
                        test_hash_speed(alg, sec, generic_hash_speed_template);
@@ -1881,6 +1887,10 @@ static int do_test(const char *alg, u32 type, u32 mask, int m)
                test_hash_speed("crct10dif", sec, generic_hash_speed_template);
                if (mode > 300 && mode < 400) break;
 
+       case 321:
+               test_hash_speed("poly1305", sec, poly1305_speed_template);
+               if (mode > 300 && mode < 400) break;
+
        case 399:
                break;