syzbot


KCSAN: data-race in init_file / prepare_creds (2)

Status: moderation: reported on 2025/07/27 03:30
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+0873b15fae924aab48d4@syzkaller.appspotmail.com
First crash: 6d14h, last: 6d14h
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in init_file / prepare_creds fs 6 1 64d 64d 0/29 auto-obsoleted due to no activity on 2025/07/25 02:49

Sample crash report:
==================================================================
BUG: KCSAN: data-race in init_file / prepare_creds

write to 0xffff88810da31528 of 4 bytes by task 11425 on cpu 1:
 get_cred_many include/linux/cred.h:202 [inline]
 get_cred include/linux/cred.h:218 [inline]
 init_file+0x2e/0x1d0 fs/file_table.c:155
 alloc_empty_file+0x8b/0x200 fs/file_table.c:238
 alloc_file fs/file_table.c:351 [inline]
 alloc_file_pseudo+0xc6/0x160 fs/file_table.c:380
 sock_alloc_file+0x9c/0x1e0 net/socket.c:470
 sock_map_fd net/socket.c:500 [inline]
 __sys_socket+0x116/0x180 net/socket.c:1692
 __do_sys_socket net/socket.c:1697 [inline]
 __se_sys_socket net/socket.c:1695 [inline]
 __x64_sys_socket+0x3f/0x50 net/socket.c:1695
 x64_sys_call+0x285a/0x2fb0 arch/x86/include/generated/asm/syscalls_64.h:42
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xd2/0x200 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff88810da31480 of 184 bytes by task 11424 on cpu 0:
 prepare_creds+0x6c/0x4c0 kernel/cred.c:219
 copy_creds+0x8f/0x3f0 kernel/cred.c:312
 copy_process+0x658/0x1f90 kernel/fork.c:2033
 kernel_clone+0x16c/0x5b0 kernel/fork.c:2599
 __do_sys_clone kernel/fork.c:2742 [inline]
 __se_sys_clone kernel/fork.c:2726 [inline]
 __x64_sys_clone+0xe6/0x120 kernel/fork.c:2726
 x64_sys_call+0x2c59/0x2fb0 arch/x86/include/generated/asm/syscalls_64.h:57
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xd2/0x200 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 11424 Comm: syz.1.12764 Not tainted 6.16.0-rc7-syzkaller-00127-g302f88ff3584 #0 PREEMPT(voluntary) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/07/27 03:29 upstream 302f88ff3584 fb8f743d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in init_file / prepare_creds
* Struck through repros no longer work on HEAD.