]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: algif_aead - Only wake up when ctx->more is zero
authorHerbert Xu <herbert@gondor.apana.org.au>
Fri, 29 May 2020 14:23:49 +0000 (00:23 +1000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 18 Jun 2020 07:19:44 +0000 (17:19 +1000)
commitb7dad8488f831a632e11d1a289e8c63cf3b78c49
treed0cc454c65a9ee0a9dc741c3ce32969a1b28be8a
parent85c0dee2c7226237364c8ccafb49e826016eb4f9
crypto: algif_aead - Only wake up when ctx->more is zero

AEAD does not support partial requests so we must not wake up
while ctx->more is set.  In order to distinguish between the
case of no data sent yet and a zero-length request, a new init
flag has been added to ctx.

SKCIPHER has also been modified to ensure that at least a block
of data is available if there is more data to come.

Fixes: 1b9f4079bf45 ("crypto: af_alg - consolidation of...")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/af_alg.c
crypto/algif_aead.c
crypto/algif_skcipher.c
include/crypto/if_alg.h