]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
io_uring/io-wq: kill off now unused IO_WQ_WORK_NO_CANCEL
authorJens Axboe <axboe@kernel.dk>
Tue, 19 Jan 2021 22:53:54 +0000 (15:53 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 1 Feb 2021 17:02:43 +0000 (10:02 -0700)
It's no longer used as IORING_OP_CLOSE got rid for the need of flagging
it as uncancelable, kill it of.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io-wq.c
fs/io-wq.h
fs/io_uring.c

index a564f36e260c13fda11be0960dfd6256499bf695..2e2f14f42bf22d9e39d0f4bff4a0b59c63bb1bc5 100644 (file)
@@ -944,7 +944,6 @@ static bool io_wq_worker_cancel(struct io_worker *worker, void *data)
         */
        spin_lock_irqsave(&worker->lock, flags);
        if (worker->cur_work &&
-           !(worker->cur_work->flags & IO_WQ_WORK_NO_CANCEL) &&
            match->fn(worker->cur_work, match->data)) {
                send_sig(SIGINT, worker->task, 1);
                match->nr_running++;
index b158f8addcf3e1460af3caf9df1a6f69a84b5b0c..e1ffb80a4a1dca665f90d6179e49cbef17dd9403 100644 (file)
@@ -9,7 +9,6 @@ enum {
        IO_WQ_WORK_CANCEL       = 1,
        IO_WQ_WORK_HASHED       = 2,
        IO_WQ_WORK_UNBOUND      = 4,
-       IO_WQ_WORK_NO_CANCEL    = 8,
        IO_WQ_WORK_CONCURRENT   = 16,
 
        IO_WQ_WORK_FILES        = 32,
index 4dd18c81789c1a548669d6df7bd619097626573e..be73f6ddbd9e91e0ea2b51a204a64bef6068bb97 100644 (file)
@@ -6386,11 +6386,8 @@ static struct io_wq_work *io_wq_submit_work(struct io_wq_work *work)
        if (timeout)
                io_queue_linked_timeout(timeout);
 
-       /* if NO_CANCEL is set, we must still run the work */
-       if ((work->flags & (IO_WQ_WORK_CANCEL|IO_WQ_WORK_NO_CANCEL)) ==
-                               IO_WQ_WORK_CANCEL) {
+       if (work->flags & IO_WQ_WORK_CANCEL)
                ret = -ECANCELED;
-       }
 
        if (!ret) {
                do {