[moderation] [io-uring?] KCSAN: data-race in io_req_defer_failed / io_wq_free_work

0 views
Skip to first unread message

syzbot

unread,
May 6, 2024, 1:59:24 AMMay 6
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: b9158815de52 Merge tag 'char-misc-6.9-rc7' of git://git.ke..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=17084338980000
kernel config: https://syzkaller.appspot.com/x/.config?x=c3beef2aff822313
dashboard link: https://syzkaller.appspot.com/bug?extid=ddbb83d8287549071f48
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [asml.s...@gmail.com ax...@kernel.dk io-u...@vger.kernel.org linux-...@vger.kernel.org]

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/db22b6db75b9/disk-b9158815.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/d3a1ba9974d9/vmlinux-b9158815.xz
kernel image: https://storage.googleapis.com/syzbot-assets/b75aa15ef863/bzImage-b9158815.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+ddbb83...@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in io_req_defer_failed / io_wq_free_work

write to 0xffff888153712248 of 8 bytes by task 15154 on cpu 0:
io_req_defer_failed+0x6e/0x240 io_uring/io_uring.c:1047
io_req_task_cancel+0x6e/0x80 io_uring/io_uring.c:1498
io_handle_tw_list+0x1ef/0x240 io_uring/io_uring.c:1198
tctx_task_work_run+0x6c/0x1b0 io_uring/io_uring.c:1270
tctx_task_work+0x40/0x80 io_uring/io_uring.c:1288
task_work_run+0x13a/0x1a0 kernel/task_work.c:180
get_signal+0xeee/0x1080 kernel/signal.c:2683
arch_do_signal_or_restart+0x95/0x4b0 arch/x86/kernel/signal.c:310
exit_to_user_mode_loop kernel/entry/common.c:111 [inline]
exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline]
__syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline]
syscall_exit_to_user_mode+0x59/0x130 kernel/entry/common.c:218
do_syscall_64+0xda/0x1d0 arch/x86/entry/common.c:89
entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff888153712248 of 8 bytes by task 15155 on cpu 1:
req_ref_put_and_test io_uring/refs.h:22 [inline]
io_wq_free_work+0x24/0x1b0 io_uring/io_uring.c:1937
io_worker_handle_work+0x4e4/0xa20 io_uring/io-wq.c:599
io_wq_worker+0x20c/0x730 io_uring/io-wq.c:649
ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

value changed: 0x00000000002c2058 -> 0x00000000006c2118

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 15155 Comm: iou-wrk-15154 Tainted: G W 6.9.0-rc6-syzkaller-00290-gb9158815de52 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup
Reply all
Reply to author
Forward
0 new messages