提交 47856204 编写于 作者: R Romain Perier 提交者: Herbert Xu

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: NRomain Perier <romain.perier@free-electrons.com>
Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
上级 57cfda1a
...@@ -408,7 +408,7 @@ static bool mv_cesa_ahash_cache_req(struct ahash_request *req) ...@@ -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); struct mv_cesa_ahash_req *creq = ahash_request_ctx(req);
bool cached = false; 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; cached = true;
if (!req->nbytes) if (!req->nbytes)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册