aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/crypto/nx/nx.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/crypto/nx/nx.c')
-rw-r--r--drivers/crypto/nx/nx.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/crypto/nx/nx.c b/drivers/crypto/nx/nx.c
index f6198f29a4a8..436971343ff7 100644
--- a/drivers/crypto/nx/nx.c
+++ b/drivers/crypto/nx/nx.c
@@ -713,12 +713,15 @@ static int nx_crypto_ctx_init(struct nx_crypto_ctx *nx_ctx, u32 fc, u32 mode)
713/* entry points from the crypto tfm initializers */ 713/* entry points from the crypto tfm initializers */
714int nx_crypto_ctx_aes_ccm_init(struct crypto_tfm *tfm) 714int nx_crypto_ctx_aes_ccm_init(struct crypto_tfm *tfm)
715{ 715{
716 crypto_aead_set_reqsize(__crypto_aead_cast(tfm),
717 sizeof(struct nx_ccm_rctx));
716 return nx_crypto_ctx_init(crypto_tfm_ctx(tfm), NX_FC_AES, 718 return nx_crypto_ctx_init(crypto_tfm_ctx(tfm), NX_FC_AES,
717 NX_MODE_AES_CCM); 719 NX_MODE_AES_CCM);
718} 720}
719 721
720int nx_crypto_ctx_aes_gcm_init(struct crypto_aead *tfm) 722int nx_crypto_ctx_aes_gcm_init(struct crypto_aead *tfm)
721{ 723{
724 crypto_aead_set_reqsize(tfm, sizeof(struct nx_gcm_rctx));
722 return nx_crypto_ctx_init(crypto_aead_ctx(tfm), NX_FC_AES, 725 return nx_crypto_ctx_init(crypto_aead_ctx(tfm), NX_FC_AES,
723 NX_MODE_AES_GCM); 726 NX_MODE_AES_GCM);
724} 727}