syzbot


KCSAN: data-race in unix_gc / wait_for_unix_gc (4)

Status: auto-closed as invalid on 2021/12/07 18:51
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 415d, last: 395d
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in unix_gc / wait_for_unix_gc (2) 5 523d 559d 0/24 auto-closed as invalid on 2021/08/01 20:33
upstream KCSAN: data-race in unix_gc / wait_for_unix_gc (3) 1 467d 467d 0/24 auto-closed as invalid on 2021/09/27 04:17
upstream KCSAN: data-race in unix_gc / wait_for_unix_gc 1 704d 704d 0/24 auto-closed as invalid on 2021/02/02 07:05

Sample crash report:
==================================================================
BUG: KCSAN: data-race in unix_gc / wait_for_unix_gc

write to 0xffffffff84172093 of 1 bytes by task 16393 on cpu 1:
 unix_gc+0x8e/0x8a0 net/unix/garbage.c:216
 unix_release_sock+0x5f4/0x680 net/unix/af_unix.c:606
 unix_release+0x4e/0x70 net/unix/af_unix.c:949
 __sock_release net/socket.c:649 [inline]
 sock_close+0x6c/0x150 net/socket.c:1314
 __fput+0x295/0x520 fs/file_table.c:280
 ____fput+0x11/0x20 fs/file_table.c:313
 task_work_run+0x8e/0x110 kernel/task_work.c:164
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:175 [inline]
 exit_to_user_mode_prepare+0x160/0x190 kernel/entry/common.c:207
 __syscall_exit_to_user_mode_work kernel/entry/common.c:289 [inline]
 syscall_exit_to_user_mode+0x20/0x40 kernel/entry/common.c:300
 do_syscall_64+0x50/0xa0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffffffff84172093 of 1 bytes by task 372 on cpu 0:
 wait_for_unix_gc+0x7c/0x160 net/unix/garbage.c:198
 unix_dgram_sendmsg+0x8e/0x16b0 net/unix/af_unix.c:1772
 sock_sendmsg_nosec net/socket.c:704 [inline]
 sock_sendmsg net/socket.c:724 [inline]
 __sys_sendto+0x21e/0x2c0 net/socket.c:2036
 __do_sys_sendto net/socket.c:2048 [inline]
 __se_sys_sendto net/socket.c:2044 [inline]
 __x64_sys_sendto+0x74/0x90 net/socket.c:2044
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xa0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x00 -> 0x01

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 372 Comm: klogd Not tainted 5.15.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2021/11/02 18:44 upstream bfc484fe6abb 17f3edd2 .config log report info KCSAN: data-race in unix_gc / wait_for_unix_gc
ci2-upstream-kcsan-gce 2021/10/14 10:50 upstream 348949d9a444 5462d470 .config log report info KCSAN: data-race in unix_gc / wait_for_unix_gc
* Struck through repros no longer work on HEAD.