Commit 2d27267b authored by Linus Walleij's avatar Linus Walleij Committed by Herbert Xu

crypto: stm32/hash - Simplify code

We are passing (rctx->flags & HASH_FLAGS_FINUP) as indicator
for the final request but we already know this to be true since
we are in the (final) arm of an if-statement set from the same
flag. Just open-code it as true.
Acked-by: default avatarLionel Debieve <lionel.debieve@foss.st.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 85f3fc54
...@@ -399,8 +399,7 @@ static int stm32_hash_update_cpu(struct stm32_hash_dev *hdev) ...@@ -399,8 +399,7 @@ static int stm32_hash_update_cpu(struct stm32_hash_dev *hdev)
if (final) { if (final) {
bufcnt = rctx->bufcnt; bufcnt = rctx->bufcnt;
rctx->bufcnt = 0; rctx->bufcnt = 0;
err = stm32_hash_xmit_cpu(hdev, rctx->buffer, bufcnt, err = stm32_hash_xmit_cpu(hdev, rctx->buffer, bufcnt, 1);
(rctx->flags & HASH_FLAGS_FINUP));
} }
return err; return err;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment