Commit 189fe317 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki Committed by Herbert Xu

[CRYPTO] cryptd: Fix problem with cryptd and the freezer

Make sure that cryptd is marked as nonfreezable and does not hold up the
freezer.
Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 7a74fc49
...@@ -298,7 +298,7 @@ static inline int cryptd_create_thread(struct cryptd_state *state, ...@@ -298,7 +298,7 @@ static inline int cryptd_create_thread(struct cryptd_state *state,
mutex_init(&state->mutex); mutex_init(&state->mutex);
crypto_init_queue(&state->queue, CRYPTD_MAX_QLEN); crypto_init_queue(&state->queue, CRYPTD_MAX_QLEN);
state->task = kthread_create(fn, state, name); state->task = kthread_run(fn, state, name);
if (IS_ERR(state->task)) if (IS_ERR(state->task))
return PTR_ERR(state->task); return PTR_ERR(state->task);
...@@ -316,6 +316,8 @@ static int cryptd_thread(void *data) ...@@ -316,6 +316,8 @@ static int cryptd_thread(void *data)
struct cryptd_state *state = data; struct cryptd_state *state = data;
int stop; int stop;
current->flags |= PF_NOFREEZE;
do { do {
struct crypto_async_request *req, *backlog; struct crypto_async_request *req, *backlog;
......
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