diff options
author | Zhang Jiejing <jiejing.zhang@freescale.com> | 2012-09-21 09:52:36 +0800 |
---|---|---|
committer | Jason Liu <r64343@freescale.com> | 2013-06-17 10:16:46 +0800 |
commit | 6068d7a77b2101c172fc2f003f90b1febbf99505 (patch) | |
tree | eb4370a54fb9c4d8b424a156917d997de92e5ce1 /drivers | |
parent | b30237c79003223c6e8035d5be183cd4f0b469f9 (diff) |
ENGR00240112-2 crypto: caam: add ecb(aes) crypto algorithm to caam.
add ecb(aes) support for caam algorithm, the caam H/W
support both ecb and cbc, add the algorithm into template.
Signed-off-by: Zhang Jiejing <jiejing.zhang@freescale.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/crypto/caam/caamalg.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/drivers/crypto/caam/caamalg.c b/drivers/crypto/caam/caamalg.c index 87b365f8089f..59299501a524 100644 --- a/drivers/crypto/caam/caamalg.c +++ b/drivers/crypto/caam/caamalg.c @@ -1,7 +1,7 @@ /* * caam - Freescale FSL CAAM support for crypto API * - * Copyright (C) 2008-2012 Freescale Semiconductor, Inc. + * Copyright (C) 2008-2013 Freescale Semiconductor, Inc. * * Based on talitos crypto API driver. * @@ -2051,6 +2051,22 @@ static struct caam_alg_template driver_algs[] = { .class1_alg_type = OP_ALG_ALGSEL_AES | OP_ALG_AAI_CBC, }, { + .name = "ecb(aes)", + .driver_name = "ecb-aes-caam", + .blocksize = AES_BLOCK_SIZE, + .type = CRYPTO_ALG_TYPE_ABLKCIPHER, + .template_ablkcipher = { + .setkey = ablkcipher_setkey, + .encrypt = ablkcipher_encrypt, + .decrypt = ablkcipher_decrypt, + .geniv = "eseqiv", + .min_keysize = AES_MIN_KEY_SIZE, + .max_keysize = AES_MAX_KEY_SIZE, + .ivsize = AES_BLOCK_SIZE, + }, + .class1_alg_type = OP_ALG_ALGSEL_AES | OP_ALG_AAI_ECB, + }, + { .name = "cbc(des3_ede)", .driver_name = "cbc-3des-caam", .blocksize = DES3_EDE_BLOCK_SIZE, |