[CRYPTO]: Use CRYPTO_TFM_REQ_MAY_SLEEP where appropriate
This patch goes through the current users of the crypto layer and sets CRYPTO_TFM_REQ_MAY_SLEEP at crypto_alloc_tfm() where all crypto operations are performed in process context. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
64baf3cfea
commit
eb6f1160dd
@@ -321,7 +321,7 @@ plaintext_to_sha1(unsigned char *hash, const char *plaintext, int len)
|
||||
"bytes.\n", len, PAGE_SIZE);
|
||||
return -ENOMEM;
|
||||
}
|
||||
tfm = crypto_alloc_tfm("sha1", 0);
|
||||
tfm = crypto_alloc_tfm("sha1", CRYPTO_TFM_REQ_MAY_SLEEP);
|
||||
if (tfm == NULL) {
|
||||
seclvl_printk(0, KERN_ERR,
|
||||
"Failed to load transform for SHA1\n");
|
||||
|
Reference in New Issue
Block a user