From: Russell King Date: Sun, 18 Oct 2015 16:23:30 +0000 (+0100) Subject: crypto: marvell/cesa - easier way to get the transform X-Git-Tag: KARO-TX6UL-2015-11-03~86^2~34 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=80754539ec936b0afe8a3c406b7d67612977cc71;p=karo-tx-linux.git crypto: marvell/cesa - easier way to get the transform There's an easier way to get at the hash transform - rather than using crypto_ahash_tfm(ahash), we can get it directly from req->base.tfm. Signed-off-by: Russell King Signed-off-by: Herbert Xu --- diff --git a/drivers/crypto/marvell/hash.c b/drivers/crypto/marvell/hash.c index 5e0e102ecbfc..40241fd822c6 100644 --- a/drivers/crypto/marvell/hash.c +++ b/drivers/crypto/marvell/hash.c @@ -805,7 +805,7 @@ static int mv_cesa_ahash_export(struct ahash_request *req, void *hash, unsigned int digsize = crypto_ahash_digestsize(ahash); unsigned int blocksize; - blocksize = crypto_tfm_alg_blocksize(crypto_ahash_tfm(ahash)); + blocksize = crypto_ahash_blocksize(ahash); *len = creq->len; memcpy(hash, creq->state, digsize); @@ -830,7 +830,7 @@ static int mv_cesa_ahash_import(struct ahash_request *req, const void *hash, if (ret) return ret; - blocksize = crypto_tfm_alg_blocksize(crypto_ahash_tfm(ahash)); + blocksize = crypto_ahash_blocksize(ahash); if (len >= blocksize) mv_cesa_update_op_cfg(&creq->op_tmpl, CESA_SA_DESC_CFG_MID_FRAG,