]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
crypto: skcipher - add might_sleep() to skcipher_walk_virt()
authorEric Biggers <ebiggers@google.com>
Sat, 15 Dec 2018 20:41:53 +0000 (12:41 -0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Sun, 23 Dec 2018 03:52:44 +0000 (11:52 +0800)
commitbb648291fc04c49197561939b8bfea0ada42bce3
tree06d6e933c6689ac2c4699ab5f29454480cea4652
parentf9c9bdb5131eee60dc3b92e5126d4c0e291703e2
crypto: skcipher - add might_sleep() to skcipher_walk_virt()

skcipher_walk_virt() can still sleep even with atomic=true, since that
only affects the later calls to skcipher_walk_done().  But,
skcipher_walk_virt() only has to allocate memory for some input data
layouts, so incorrectly calling it with preemption disabled can go
undetected.  Use might_sleep() so that it's detected reliably.

Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/skcipher.c