Skip to content

Commit

Permalink
crypto: qce - Add support for AEAD algorithms
Browse files Browse the repository at this point in the history
Introduce support to enable following algorithms in Qualcomm Crypto Engine.

- authenc(hmac(sha1),cbc(des))
- authenc(hmac(sha1),cbc(des3_ede))
- authenc(hmac(sha256),cbc(des))
- authenc(hmac(sha256),cbc(des3_ede))
- authenc(hmac(sha256),cbc(aes))
- ccm(aes)
- rfc4309(ccm(aes))

Signed-off-by: Thara Gopinath <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
  • Loading branch information
tharagopinath authored and herbertx committed May 14, 2021
1 parent 7ba9cd4 commit 9363efb
Show file tree
Hide file tree
Showing 6 changed files with 874 additions and 0 deletions.
15 changes: 15 additions & 0 deletions drivers/crypto/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -627,6 +627,12 @@ config CRYPTO_DEV_QCE_SHA
select CRYPTO_SHA1
select CRYPTO_SHA256

config CRYPTO_DEV_QCE_AEAD
bool
depends on CRYPTO_DEV_QCE
select CRYPTO_AUTHENC
select CRYPTO_LIB_DES

choice
prompt "Algorithms enabled for QCE acceleration"
default CRYPTO_DEV_QCE_ENABLE_ALL
Expand All @@ -647,6 +653,7 @@ choice
bool "All supported algorithms"
select CRYPTO_DEV_QCE_SKCIPHER
select CRYPTO_DEV_QCE_SHA
select CRYPTO_DEV_QCE_AEAD
help
Enable all supported algorithms:
- AES (CBC, CTR, ECB, XTS)
Expand All @@ -672,6 +679,14 @@ choice
- SHA1, HMAC-SHA1
- SHA256, HMAC-SHA256

config CRYPTO_DEV_QCE_ENABLE_AEAD
bool "AEAD algorithms only"
select CRYPTO_DEV_QCE_AEAD
help
Enable AEAD algorithms only:
- authenc()
- ccm(aes)
- rfc4309(ccm(aes))
endchoice

config CRYPTO_DEV_QCE_SW_MAX_LEN
Expand Down
1 change: 1 addition & 0 deletions drivers/crypto/qce/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ qcrypto-objs := core.o \

qcrypto-$(CONFIG_CRYPTO_DEV_QCE_SHA) += sha.o
qcrypto-$(CONFIG_CRYPTO_DEV_QCE_SKCIPHER) += skcipher.o
qcrypto-$(CONFIG_CRYPTO_DEV_QCE_AEAD) += aead.o
Loading

0 comments on commit 9363efb

Please sign in to comment.