aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/crypto/picoxcell_crypto.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-03-21 16:20:43 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-03-21 16:20:43 -0400
commitb8716614a7cc2fc15ea2a518edd04755fb08d922 (patch)
tree2a8a5d04066b2bd589ba2ebbeb228e2a6a178ec9 /drivers/crypto/picoxcell_crypto.c
parent31f6765266417c0d99f0e922fe82848a7c9c2ae9 (diff)
parent2dc9b5dbdef09840de852a4f0cc6a9c9eece7220 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto update from Herbert Xu: "* sha512 bug fixes (already in your tree). * SHA224/SHA384 AEAD support in caam. * X86-64 optimised version of Camellia. * Tegra AES support. * Bulk algorithm registration interface to make driver registration easier. * padata race fixes. * Misc fixes." * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (31 commits) padata: Fix race on sequence number wrap padata: Fix race in the serialization path crypto: camellia - add assembler implementation for x86_64 crypto: camellia - rename camellia.c to camellia_generic.c crypto: camellia - fix checkpatch warnings crypto: camellia - rename camellia module to camellia_generic crypto: tcrypt - add more camellia tests crypto: testmgr - add more camellia test vectors crypto: camellia - simplify key setup and CAMELLIA_ROUNDSM macro crypto: twofish-x86_64/i586 - set alignmask to zero crypto: blowfish-x86_64 - set alignmask to zero crypto: serpent-sse2 - combine ablk_*_init functions crypto: blowfish-x86_64 - use crypto_[un]register_algs crypto: twofish-x86_64-3way - use crypto_[un]register_algs crypto: serpent-sse2 - use crypto_[un]register_algs crypto: serpent-sse2 - remove dead code from serpent_sse2_glue.c::serpent_sse2_init() crypto: twofish-x86 - Remove dead code from twofish_glue_3way.c::init() crypto: In crypto_add_alg(), 'exact' wants to be initialized to 0 crypto: caam - fix gcc 4.6 warning crypto: Add bulk algorithm registration interface ...
Diffstat (limited to 'drivers/crypto/picoxcell_crypto.c')
-rw-r--r--drivers/crypto/picoxcell_crypto.c46
1 files changed, 35 insertions, 11 deletions
diff --git a/drivers/crypto/picoxcell_crypto.c b/drivers/crypto/picoxcell_crypto.c
index 58480d009324..410a03c01ca4 100644
--- a/drivers/crypto/picoxcell_crypto.c
+++ b/drivers/crypto/picoxcell_crypto.c
@@ -1322,6 +1322,7 @@ static struct spacc_alg ipsec_engine_algs[] = {
1322 .cra_driver_name = "cbc-aes-picoxcell", 1322 .cra_driver_name = "cbc-aes-picoxcell",
1323 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1323 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1324 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | 1324 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1325 CRYPTO_ALG_KERN_DRIVER_ONLY |
1325 CRYPTO_ALG_ASYNC | 1326 CRYPTO_ALG_ASYNC |
1326 CRYPTO_ALG_NEED_FALLBACK, 1327 CRYPTO_ALG_NEED_FALLBACK,
1327 .cra_blocksize = AES_BLOCK_SIZE, 1328 .cra_blocksize = AES_BLOCK_SIZE,
@@ -1349,6 +1350,7 @@ static struct spacc_alg ipsec_engine_algs[] = {
1349 .cra_driver_name = "ecb-aes-picoxcell", 1350 .cra_driver_name = "ecb-aes-picoxcell",
1350 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1351 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1351 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | 1352 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1353 CRYPTO_ALG_KERN_DRIVER_ONLY |
1352 CRYPTO_ALG_ASYNC | CRYPTO_ALG_NEED_FALLBACK, 1354 CRYPTO_ALG_ASYNC | CRYPTO_ALG_NEED_FALLBACK,
1353 .cra_blocksize = AES_BLOCK_SIZE, 1355 .cra_blocksize = AES_BLOCK_SIZE,
1354 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1356 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
@@ -1373,7 +1375,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1373 .cra_name = "cbc(des)", 1375 .cra_name = "cbc(des)",
1374 .cra_driver_name = "cbc-des-picoxcell", 1376 .cra_driver_name = "cbc-des-picoxcell",
1375 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1377 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1376 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | CRYPTO_ALG_ASYNC, 1378 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1379 CRYPTO_ALG_ASYNC |
1380 CRYPTO_ALG_KERN_DRIVER_ONLY,
1377 .cra_blocksize = DES_BLOCK_SIZE, 1381 .cra_blocksize = DES_BLOCK_SIZE,
1378 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1382 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
1379 .cra_type = &crypto_ablkcipher_type, 1383 .cra_type = &crypto_ablkcipher_type,
@@ -1398,7 +1402,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1398 .cra_name = "ecb(des)", 1402 .cra_name = "ecb(des)",
1399 .cra_driver_name = "ecb-des-picoxcell", 1403 .cra_driver_name = "ecb-des-picoxcell",
1400 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1404 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1401 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | CRYPTO_ALG_ASYNC, 1405 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1406 CRYPTO_ALG_ASYNC |
1407 CRYPTO_ALG_KERN_DRIVER_ONLY,
1402 .cra_blocksize = DES_BLOCK_SIZE, 1408 .cra_blocksize = DES_BLOCK_SIZE,
1403 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1409 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
1404 .cra_type = &crypto_ablkcipher_type, 1410 .cra_type = &crypto_ablkcipher_type,
@@ -1422,7 +1428,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1422 .cra_name = "cbc(des3_ede)", 1428 .cra_name = "cbc(des3_ede)",
1423 .cra_driver_name = "cbc-des3-ede-picoxcell", 1429 .cra_driver_name = "cbc-des3-ede-picoxcell",
1424 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1430 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1425 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | CRYPTO_ALG_ASYNC, 1431 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1432 CRYPTO_ALG_ASYNC |
1433 CRYPTO_ALG_KERN_DRIVER_ONLY,
1426 .cra_blocksize = DES3_EDE_BLOCK_SIZE, 1434 .cra_blocksize = DES3_EDE_BLOCK_SIZE,
1427 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1435 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
1428 .cra_type = &crypto_ablkcipher_type, 1436 .cra_type = &crypto_ablkcipher_type,
@@ -1447,7 +1455,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1447 .cra_name = "ecb(des3_ede)", 1455 .cra_name = "ecb(des3_ede)",
1448 .cra_driver_name = "ecb-des3-ede-picoxcell", 1456 .cra_driver_name = "ecb-des3-ede-picoxcell",
1449 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1457 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1450 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER | CRYPTO_ALG_ASYNC, 1458 .cra_flags = CRYPTO_ALG_TYPE_ABLKCIPHER |
1459 CRYPTO_ALG_ASYNC |
1460 CRYPTO_ALG_KERN_DRIVER_ONLY,
1451 .cra_blocksize = DES3_EDE_BLOCK_SIZE, 1461 .cra_blocksize = DES3_EDE_BLOCK_SIZE,
1452 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1462 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
1453 .cra_type = &crypto_ablkcipher_type, 1463 .cra_type = &crypto_ablkcipher_type,
@@ -1472,7 +1482,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1472 .cra_name = "authenc(hmac(sha1),cbc(aes))", 1482 .cra_name = "authenc(hmac(sha1),cbc(aes))",
1473 .cra_driver_name = "authenc-hmac-sha1-cbc-aes-picoxcell", 1483 .cra_driver_name = "authenc-hmac-sha1-cbc-aes-picoxcell",
1474 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1484 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1475 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1485 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1486 CRYPTO_ALG_ASYNC |
1487 CRYPTO_ALG_KERN_DRIVER_ONLY,
1476 .cra_blocksize = AES_BLOCK_SIZE, 1488 .cra_blocksize = AES_BLOCK_SIZE,
1477 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1489 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1478 .cra_type = &crypto_aead_type, 1490 .cra_type = &crypto_aead_type,
@@ -1500,7 +1512,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1500 .cra_name = "authenc(hmac(sha256),cbc(aes))", 1512 .cra_name = "authenc(hmac(sha256),cbc(aes))",
1501 .cra_driver_name = "authenc-hmac-sha256-cbc-aes-picoxcell", 1513 .cra_driver_name = "authenc-hmac-sha256-cbc-aes-picoxcell",
1502 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1514 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1503 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1515 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1516 CRYPTO_ALG_ASYNC |
1517 CRYPTO_ALG_KERN_DRIVER_ONLY,
1504 .cra_blocksize = AES_BLOCK_SIZE, 1518 .cra_blocksize = AES_BLOCK_SIZE,
1505 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1519 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1506 .cra_type = &crypto_aead_type, 1520 .cra_type = &crypto_aead_type,
@@ -1527,7 +1541,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1527 .cra_name = "authenc(hmac(md5),cbc(aes))", 1541 .cra_name = "authenc(hmac(md5),cbc(aes))",
1528 .cra_driver_name = "authenc-hmac-md5-cbc-aes-picoxcell", 1542 .cra_driver_name = "authenc-hmac-md5-cbc-aes-picoxcell",
1529 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1543 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1530 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1544 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1545 CRYPTO_ALG_ASYNC |
1546 CRYPTO_ALG_KERN_DRIVER_ONLY,
1531 .cra_blocksize = AES_BLOCK_SIZE, 1547 .cra_blocksize = AES_BLOCK_SIZE,
1532 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1548 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1533 .cra_type = &crypto_aead_type, 1549 .cra_type = &crypto_aead_type,
@@ -1554,7 +1570,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1554 .cra_name = "authenc(hmac(sha1),cbc(des3_ede))", 1570 .cra_name = "authenc(hmac(sha1),cbc(des3_ede))",
1555 .cra_driver_name = "authenc-hmac-sha1-cbc-3des-picoxcell", 1571 .cra_driver_name = "authenc-hmac-sha1-cbc-3des-picoxcell",
1556 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1572 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1557 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1573 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1574 CRYPTO_ALG_ASYNC |
1575 CRYPTO_ALG_KERN_DRIVER_ONLY,
1558 .cra_blocksize = DES3_EDE_BLOCK_SIZE, 1576 .cra_blocksize = DES3_EDE_BLOCK_SIZE,
1559 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1577 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1560 .cra_type = &crypto_aead_type, 1578 .cra_type = &crypto_aead_type,
@@ -1582,7 +1600,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1582 .cra_name = "authenc(hmac(sha256),cbc(des3_ede))", 1600 .cra_name = "authenc(hmac(sha256),cbc(des3_ede))",
1583 .cra_driver_name = "authenc-hmac-sha256-cbc-3des-picoxcell", 1601 .cra_driver_name = "authenc-hmac-sha256-cbc-3des-picoxcell",
1584 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1602 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1585 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1603 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1604 CRYPTO_ALG_ASYNC |
1605 CRYPTO_ALG_KERN_DRIVER_ONLY,
1586 .cra_blocksize = DES3_EDE_BLOCK_SIZE, 1606 .cra_blocksize = DES3_EDE_BLOCK_SIZE,
1587 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1607 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1588 .cra_type = &crypto_aead_type, 1608 .cra_type = &crypto_aead_type,
@@ -1609,7 +1629,9 @@ static struct spacc_alg ipsec_engine_algs[] = {
1609 .cra_name = "authenc(hmac(md5),cbc(des3_ede))", 1629 .cra_name = "authenc(hmac(md5),cbc(des3_ede))",
1610 .cra_driver_name = "authenc-hmac-md5-cbc-3des-picoxcell", 1630 .cra_driver_name = "authenc-hmac-md5-cbc-3des-picoxcell",
1611 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1631 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1612 .cra_flags = CRYPTO_ALG_TYPE_AEAD | CRYPTO_ALG_ASYNC, 1632 .cra_flags = CRYPTO_ALG_TYPE_AEAD |
1633 CRYPTO_ALG_ASYNC |
1634 CRYPTO_ALG_KERN_DRIVER_ONLY,
1613 .cra_blocksize = DES3_EDE_BLOCK_SIZE, 1635 .cra_blocksize = DES3_EDE_BLOCK_SIZE,
1614 .cra_ctxsize = sizeof(struct spacc_aead_ctx), 1636 .cra_ctxsize = sizeof(struct spacc_aead_ctx),
1615 .cra_type = &crypto_aead_type, 1637 .cra_type = &crypto_aead_type,
@@ -1639,7 +1661,9 @@ static struct spacc_alg l2_engine_algs[] = {
1639 .cra_name = "f8(kasumi)", 1661 .cra_name = "f8(kasumi)",
1640 .cra_driver_name = "f8-kasumi-picoxcell", 1662 .cra_driver_name = "f8-kasumi-picoxcell",
1641 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY, 1663 .cra_priority = SPACC_CRYPTO_ALG_PRIORITY,
1642 .cra_flags = CRYPTO_ALG_TYPE_GIVCIPHER | CRYPTO_ALG_ASYNC, 1664 .cra_flags = CRYPTO_ALG_TYPE_GIVCIPHER |
1665 CRYPTO_ALG_ASYNC |
1666 CRYPTO_ALG_KERN_DRIVER_ONLY,
1643 .cra_blocksize = 8, 1667 .cra_blocksize = 8,
1644 .cra_ctxsize = sizeof(struct spacc_ablk_ctx), 1668 .cra_ctxsize = sizeof(struct spacc_ablk_ctx),
1645 .cra_type = &crypto_ablkcipher_type, 1669 .cra_type = &crypto_ablkcipher_type,