Commit d52b0c78 authored by Herbert Xu's avatar Herbert Xu

Revert "crypto: rsa-pkcs1pad - Replace GFP_ATOMIC with GFP_KERNEL in...

Revert "crypto: rsa-pkcs1pad - Replace GFP_ATOMIC with GFP_KERNEL in pkcs1pad_encrypt_sign_complete"

This reverts commit 1ca28098.

While the akcipher API as a whole is designed to be called only
from thread context, its completion path is still called from
softirq context as usual.  Therefore we must not use GFP_KERNEL
on that path.
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 8a1955f9
...@@ -190,7 +190,7 @@ static int pkcs1pad_encrypt_sign_complete(struct akcipher_request *req, int err) ...@@ -190,7 +190,7 @@ static int pkcs1pad_encrypt_sign_complete(struct akcipher_request *req, int err)
if (likely(!pad_len)) if (likely(!pad_len))
goto out; goto out;
out_buf = kzalloc(ctx->key_size, GFP_KERNEL); out_buf = kzalloc(ctx->key_size, GFP_ATOMIC);
err = -ENOMEM; err = -ENOMEM;
if (!out_buf) if (!out_buf)
goto out; goto out;
......
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