summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRomain Perier <romain.perier@free-electrons.com>2016-08-09 12:03:20 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2016-08-09 13:47:31 +0300
commit47856204146ba6fd0f198dbb23c4ed7ad1c3fd99 (patch)
treefb65639194c9dacee16868c75ddf3a5210f96d96
parent57cfda1ac74e58767f6305bd1ea3449177425460 (diff)
downloadlinux-47856204146ba6fd0f198dbb23c4ed7ad1c3fd99.tar.xz
crypto: marvell - Don't hardcode block size in mv_cesa_ahash_cache_req
Don't use 64 'as is', as max block size in mv_cesa_ahash_cache_req. Use CESA_MAX_HASH_BLOCK_SIZE instead, this is better for readability. Signed-off-by: Romain Perier <romain.perier@free-electrons.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
-rw-r--r--drivers/crypto/marvell/hash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/crypto/marvell/hash.c b/drivers/crypto/marvell/hash.c
index 44a8abeba295..9f284682c091 100644
--- a/drivers/crypto/marvell/hash.c
+++ b/drivers/crypto/marvell/hash.c
@@ -408,7 +408,7 @@ static bool mv_cesa_ahash_cache_req(struct ahash_request *req)
struct mv_cesa_ahash_req *creq = ahash_request_ctx(req);
bool cached = false;
- if (creq->cache_ptr + req->nbytes < 64 && !creq->last_req) {
+ if (creq->cache_ptr + req->nbytes < CESA_MAX_HASH_BLOCK_SIZE && !creq->last_req) {
cached = true;
if (!req->nbytes)