Commit d14a9b38 authored by Josef Bacik's avatar Josef Bacik Committed by Jens Axboe

rq-qos: set ourself TASK_UNINTERRUPTIBLE after we schedule

In case we get a spurious wakeup we need to make sure to re-set
ourselves to TASK_UNINTERRUPTIBLE so we don't busy wait.
Reviewed-by: default avatarOleg Nesterov <oleg@redhat.com>
Signed-off-by: default avatarJosef Bacik <josef@toxicpanda.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 64e7ea87
...@@ -262,6 +262,7 @@ void rq_qos_wait(struct rq_wait *rqw, void *private_data, ...@@ -262,6 +262,7 @@ void rq_qos_wait(struct rq_wait *rqw, void *private_data,
} }
io_schedule(); io_schedule();
has_sleeper = true; has_sleeper = true;
set_current_state(TASK_UNINTERRUPTIBLE);
} while (1); } while (1);
finish_wait(&rqw->wait, &data.wq); finish_wait(&rqw->wait, &data.wq);
} }
......
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