mirror-linux/include/crypto
Herbert Xu c4cb61c5f9 crypto: api - Use work queue in crypto_destroy_instance
[ Upstream commit 9ae4577bc0 ]

The function crypto_drop_spawn expects to be called in process
context.  However, when an instance is unregistered while it still
has active users, the last user may cause the instance to be freed
in atomic context.

Fix this by delaying the freeing to a work queue.

Fixes: 6bfd48096f ("[CRYPTO] api: Added spawns")
Reported-by: Florent Revest <revest@chromium.org>
Reported-by: syzbot+d769eed29cc42d75e2a3@syzkaller.appspotmail.com
Reported-by: syzbot+610ec0671f51e838436e@syzkaller.appspotmail.com
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Tested-by: Florent Revest <revest@chromium.org>
Acked-by: Florent Revest <revest@chromium.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-09-13 09:42:32 +02:00
..
internal crypto: kpp - Add helper to set reqsize 2023-07-19 16:21:42 +02:00
acompress.h
aead.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
aes.h
akcipher.h
algapi.h crypto: api - Use work queue in crypto_destroy_instance 2023-09-13 09:42:32 +02:00
arc4.h
aria.h crypto: aria - prepare generic module for optimized implementations 2022-09-24 16:14:44 +08:00
authenc.h
b128ops.h
blake2b.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
blake2s.h lib/crypto: blake2s: move hmac construction into wireguard 2022-01-18 13:03:55 +01:00
blowfish.h
cast5.h
cast6.h
cast_common.h
chacha.h random: early initialization of ChaCha constants 2022-01-07 00:25:25 +01:00
chacha20poly1305.h
cryptd.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
ctr.h
curve25519.h
des.h
dh.h crypto: dh - split out deserialization code from crypto_dh_decode() 2022-03-03 10:47:50 +12:00
drbg.h crypto: drbg - reseed 'nopr' drbgs periodically from get_random_bytes() 2021-11-26 16:16:50 +11:00
ecc_curve.h
ecdh.h
engine.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
gcm.h
gf128mul.h
ghash.h
hash.h crypto: add crypto_has_shash() 2022-08-02 17:14:47 -06:00
hash_info.h
hmac.h
if_alg.h
kdf_sp800108.h crypto: kdf - add SP800-108 counter key derivation function 2021-11-26 16:25:17 +11:00
kpp.h crypto: add crypto_has_kpp() 2022-08-02 17:14:47 -06:00
md5.h
nhpoly1305.h
null.h
padlock.h
pcrypt.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
pkcs7.h
poly1305.h
polyval.h crypto: x86/polyval - Add PCLMULQDQ accelerated implementation of POLYVAL 2022-06-10 16:40:17 +08:00
public_key.h keys: X.509 public key issuer lookup without AKID 2022-01-09 00:18:42 +02:00
rng.h
scatterwalk.h crypto: scatterwalk - Remove unused inline function scatterwalk_aligned() 2022-09-30 13:59:13 +08:00
serpent.h
sha1.h
sha1_base.h
sha2.h
sha3.h
sha256_base.h
sha512_base.h
skcipher.h crypto: api - Replace kernel.h with the necessary inclusions 2021-12-17 16:59:48 +11:00
sm2.h
sm3.h crypto: sm3 - make dependent on sm3 library 2022-01-28 16:51:11 +11:00
sm3_base.h
sm4.h crypto: sm4 - export sm4 constant arrays 2022-04-08 16:12:46 +08:00
streebog.h
twofish.h
xts.h