author: Jens Axboe <axboe@kernel.dk> 2020-10-14 10:12:37 -0600
committer: Jens Axboe <axboe@kernel.dk> 2020-10-17 09:25:45 -0600
commit: dfead8a8e2c494b947480bac90a6f9792f08bc12
parent: 0f203765880c4416675726be558b65da4a7604e2
Commit Summary:
Diffstat:
1 file changed, 0 insertions, 4 deletions
diff --git a/fs/io-wq.c b/fs/io-wq.c
index e636898f8a1f..b7d8e544a804 100644
--- a/fs/io-wq.c
+++ b/fs/io-wq.c
@@ -429,14 +429,10 @@ static void io_wq_switch_mm(struct io_worker *worker, struct io_wq_work *work)
mmput(worker->mm);
worker->mm = NULL;
}
- if (!work->mm)
- return;
if (mmget_not_zero(work->mm)) {
kthread_use_mm(work->mm);
worker->mm = work->mm;
- /* hang on to this mm */
- work->mm = NULL;
return;
}