]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
io_uring/timeout: annotate data race in io_flush_timeouts()
authorJens Axboe <axboe@kernel.dk>
Tue, 20 Jan 2026 16:53:43 +0000 (09:53 -0700)
committerJens Axboe <axboe@kernel.dk>
Tue, 20 Jan 2026 16:54:17 +0000 (09:54 -0700)
commit42b12cb5fd4554679bac06bbdd05dc8b643bcc42
tree220163d7b2670717adfb9ec7a985e0a62787e57a
parent8661d0b142bccfa19bb542ee21ec45a5423899ea
io_uring/timeout: annotate data race in io_flush_timeouts()

syzbot correctly reports this as a KCSAN race, as ctx->cached_cq_tail
should be read under ->uring_lock. This isn't immediately feasible in
io_flush_timeouts(), but as long as we read a stable value, that should
be good enough. If two io-wq threads compete on this value, then they
will both end up calling io_flush_timeouts() and at least one of them
will see the correct value.

Reported-by: syzbot+6c48db7d94402407301e@syzkaller.appspotmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/timeout.c