Update to 3.4-final.
[linux-flexiantxendom0-3.2.10.git] / crypto / tcrypt.c
index dd3a0f8..8f147bf 100644 (file)
@@ -990,12 +990,16 @@ static int do_test(int m)
                ret += tcrypt_test("ecb(twofish)");
                ret += tcrypt_test("cbc(twofish)");
                ret += tcrypt_test("ctr(twofish)");
+               ret += tcrypt_test("lrw(twofish)");
+               ret += tcrypt_test("xts(twofish)");
                break;
 
        case 9:
                ret += tcrypt_test("ecb(serpent)");
                ret += tcrypt_test("cbc(serpent)");
                ret += tcrypt_test("ctr(serpent)");
+               ret += tcrypt_test("lrw(serpent)");
+               ret += tcrypt_test("xts(serpent)");
                break;
 
        case 10:
@@ -1248,6 +1252,14 @@ static int do_test(int m)
                                speed_template_16_24_32);
                test_cipher_speed("ctr(twofish)", DECRYPT, sec, NULL, 0,
                                speed_template_16_24_32);
+               test_cipher_speed("lrw(twofish)", ENCRYPT, sec, NULL, 0,
+                               speed_template_32_40_48);
+               test_cipher_speed("lrw(twofish)", DECRYPT, sec, NULL, 0,
+                               speed_template_32_40_48);
+               test_cipher_speed("xts(twofish)", ENCRYPT, sec, NULL, 0,
+                               speed_template_32_48_64);
+               test_cipher_speed("xts(twofish)", DECRYPT, sec, NULL, 0,
+                               speed_template_32_48_64);
                break;
 
        case 203:
@@ -1285,6 +1297,18 @@ static int do_test(int m)
                                speed_template_16_24_32);
                test_cipher_speed("cbc(camellia)", DECRYPT, sec, NULL, 0,
                                speed_template_16_24_32);
+               test_cipher_speed("ctr(camellia)", ENCRYPT, sec, NULL, 0,
+                               speed_template_16_24_32);
+               test_cipher_speed("ctr(camellia)", DECRYPT, sec, NULL, 0,
+                               speed_template_16_24_32);
+               test_cipher_speed("lrw(camellia)", ENCRYPT, sec, NULL, 0,
+                               speed_template_32_40_48);
+               test_cipher_speed("lrw(camellia)", DECRYPT, sec, NULL, 0,
+                               speed_template_32_40_48);
+               test_cipher_speed("xts(camellia)", ENCRYPT, sec, NULL, 0,
+                               speed_template_32_48_64);
+               test_cipher_speed("xts(camellia)", DECRYPT, sec, NULL, 0,
+                               speed_template_32_48_64);
                break;
 
        case 206:
@@ -1292,6 +1316,29 @@ static int do_test(int m)
                                  speed_template_16_32);
                break;
 
+       case 207:
+               test_cipher_speed("ecb(serpent)", ENCRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("ecb(serpent)", DECRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("cbc(serpent)", ENCRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("cbc(serpent)", DECRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("ctr(serpent)", ENCRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("ctr(serpent)", DECRYPT, sec, NULL, 0,
+                                 speed_template_16_32);
+               test_cipher_speed("lrw(serpent)", ENCRYPT, sec, NULL, 0,
+                                 speed_template_32_48);
+               test_cipher_speed("lrw(serpent)", DECRYPT, sec, NULL, 0,
+                                 speed_template_32_48);
+               test_cipher_speed("xts(serpent)", ENCRYPT, sec, NULL, 0,
+                                 speed_template_32_64);
+               test_cipher_speed("xts(serpent)", DECRYPT, sec, NULL, 0,
+                                 speed_template_32_64);
+               break;
+
        case 300:
                /* fall through */
 
@@ -1493,6 +1540,29 @@ static int do_test(int m)
                                   speed_template_8);
                break;
 
+       case 503:
+               test_acipher_speed("ecb(serpent)", ENCRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("ecb(serpent)", DECRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("cbc(serpent)", ENCRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("cbc(serpent)", DECRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("ctr(serpent)", ENCRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("ctr(serpent)", DECRYPT, sec, NULL, 0,
+                                  speed_template_16_32);
+               test_acipher_speed("lrw(serpent)", ENCRYPT, sec, NULL, 0,
+                                  speed_template_32_48);
+               test_acipher_speed("lrw(serpent)", DECRYPT, sec, NULL, 0,
+                                  speed_template_32_48);
+               test_acipher_speed("xts(serpent)", ENCRYPT, sec, NULL, 0,
+                                  speed_template_32_64);
+               test_acipher_speed("xts(serpent)", DECRYPT, sec, NULL, 0,
+                                  speed_template_32_64);
+               break;
+
        case 1000:
                test_available();
                break;