[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1453885718-24599-3-git-send-email-rui.y.wang@intel.com>
Date: Wed, 27 Jan 2016 17:08:36 +0800
From: Rui Wang <rui.y.wang@...el.com>
To: herbert@...dor.apana.org.au
Cc: tim.c.chen@...ux.intel.com, rui.y.wang@...el.com,
linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH v2 2/4] crypto: mcryptd - Fix load failure
mcryptd_create_hash() fails by returning -EINVAL, causing any
driver using mcryptd to fail to load. It is because it needs
to set its statesize properly.
Signed-off-by: Rui Wang <rui.y.wang@...el.com>
---
crypto/mcryptd.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/crypto/mcryptd.c b/crypto/mcryptd.c
index f78d4fc..c4eb9da 100644
--- a/crypto/mcryptd.c
+++ b/crypto/mcryptd.c
@@ -522,6 +522,7 @@ static int mcryptd_create_hash(struct crypto_template *tmpl, struct rtattr **tb,
inst->alg.halg.base.cra_flags = type;
inst->alg.halg.digestsize = salg->digestsize;
+ inst->alg.halg.statesize = salg->statesize;
inst->alg.halg.base.cra_ctxsize = sizeof(struct mcryptd_hash_ctx);
inst->alg.halg.base.cra_init = mcryptd_hash_init_tfm;
--
1.8.3.1
Powered by blists - more mailing lists