summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--io_uring/io_uring.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io_uring/io_uring.c b/io_uring/io_uring.c
index b688953d1de8..bd1ab21ed539 100644
--- a/io_uring/io_uring.c
+++ b/io_uring/io_uring.c
@@ -900,7 +900,7 @@ static void io_req_complete_post(struct io_kiocb *req, unsigned issue_flags)
* Handle special CQ sync cases via task_work. DEFER_TASKRUN requires
* the submitter task context, IOPOLL protects with uring_lock.
*/
- if (ctx->task_complete || (ctx->flags & IORING_SETUP_IOPOLL)) {
+ if (ctx->lockless_cq) {
req->io_task_work.func = io_req_task_complete;
io_req_task_work_add(req);
return;