diff --git a/io_uring/sqpoll.c b/io_uring/sqpoll.c index ad42e8eb1002..ee97808a065a 100644 --- a/io_uring/sqpoll.c +++ b/io_uring/sqpoll.c @@ -385,6 +385,13 @@ static int io_sq_thread(void *data) */ smp_mb__after_atomic(); + /* + * Nothing gets submitted before the ring is + * enabled, which comes with a wake up. + */ + if (READ_ONCE(ctx->flags) & IORING_SETUP_R_DISABLED) + continue; + if (io_sqring_entries(ctx)) { needs_sched = false; break;