From: Jens Axboe Date: Mon, 20 Apr 2026 20:24:50 +0000 (-0600) Subject: io_uring/futex: ensure partial wakes are appropriately dequeued X-Git-Tag: v7.1-rc1~11^2~6 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=7faaa6812aba550c24bffdfd9399568223c8a477;p=thirdparty%2Fkernel%2Flinux.git io_uring/futex: ensure partial wakes are appropriately dequeued If a FUTEX_WAITV vectored operation is only partially woken, we should call __futex_wake_mark() on the queue to account for that. If not, then a later wakeup will wake the same entry, rather than the next one in line. Fixes: 8f350194d5cfd ("io_uring: add support for vectored futex waits") Reviewed-by: Gabriel Krisman Bertazi Signed-off-by: Jens Axboe --- diff --git a/io_uring/futex.c b/io_uring/futex.c index fd503c24b428..9cc1788ef4c6 100644 --- a/io_uring/futex.c +++ b/io_uring/futex.c @@ -159,8 +159,10 @@ static void io_futex_wakev_fn(struct wake_q_head *wake_q, struct futex_q *q) struct io_kiocb *req = q->wake_data; struct io_futexv_data *ifd = req->async_data; - if (!io_futexv_claim(ifd)) + if (!io_futexv_claim(ifd)) { + __futex_wake_mark(q); return; + } if (unlikely(!__futex_wake_mark(q))) return;