syzbot


KCSAN: data-race in setattr_copy / vfs_write (4)

Status: moderation: reported on 2025/09/29 16:42
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+4fde77d66555ad4c1ef9@syzkaller.appspotmail.com
First crash: 2d20h, last: 2d20h
Similar bugs (3)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in setattr_copy / vfs_write ext4 6 1 1628d 1628d 0/29 auto-closed as invalid on 2021/05/23 06:39
upstream KCSAN: data-race in setattr_copy / vfs_write (2) ext4 6 1 1563d 1563d 0/29 auto-closed as invalid on 2021/07/27 10:55
upstream KCSAN: data-race in setattr_copy / vfs_write (3) ext4 6 1 1332d 1332d 0/29 auto-closed as invalid on 2022/03/14 15:19

Sample crash report:
==================================================================
BUG: KCSAN: data-race in setattr_copy / vfs_write

write to 0xffff888119ca4f08 of 2 bytes by task 7703 on cpu 1:
 setattr_copy+0x199/0x4b0 fs/attr.c:352
 shmem_setattr+0x566/0x840 mm/shmem.c:1375
 notify_change+0x809/0x890 fs/attr.c:552
 chmod_common+0x138/0x270 fs/open.c:650
 do_fchmodat+0xcd/0x180 fs/open.c:697
 __do_sys_chmod fs/open.c:721 [inline]
 __se_sys_chmod fs/open.c:719 [inline]
 __x64_sys_chmod+0x38/0x50 fs/open.c:719
 x64_sys_call+0x291c/0x2ff0 arch/x86/include/generated/asm/syscalls_64.h:91
 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 0xffff888119ca4f08 of 2 bytes by task 7698 on cpu 0:
 file_end_write include/linux/fs.h:3126 [inline]
 vfs_write+0x757/0x960 fs/read_write.c:694
 ksys_write+0xda/0x1a0 fs/read_write.c:738
 __do_sys_write fs/read_write.c:749 [inline]
 __se_sys_write fs/read_write.c:746 [inline]
 __x64_sys_write+0x40/0x50 fs/read_write.c:746
 x64_sys_call+0x27fe/0x2ff0 arch/x86/include/generated/asm/syscalls_64.h:2
 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

value changed: 0x8000 -> 0x8120

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 7698 Comm: syz.3.956 Tainted: G        W           syzkaller #0 PREEMPT(voluntary) 
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/18/2025
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/09/29 16:41 upstream e5f0a698b34e 86341da6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in setattr_copy / vfs_write
* Struck through repros no longer work on HEAD.