syzbot


KCSAN: data-race in generic_fillattr / setattr_copy (3)

Status: moderation: reported on 2025/02/06 17:04
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+37a45749dbc529a6cb1c@syzkaller.appspotmail.com
First crash: 1d01h, last: 1d01h
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in generic_fillattr / setattr_copy (2) fs 1 71d 71d 0/28 auto-obsoleted due to no activity on 2025/01/23 14:54
upstream KCSAN: data-race in generic_fillattr / setattr_copy fs 1 379d 379d 0/28 auto-obsoleted due to no activity on 2024/02/28 21:09

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

write to 0xffff88812358b82c of 4 bytes by task 4547 on cpu 0:
 inode_set_mtime_to_ts include/linux/fs.h:1696 [inline]
 setattr_copy+0x2c8/0x4a0 fs/attr.c:361
 shmem_setattr+0x532/0x830 mm/shmem.c:1330
 notify_change+0x85c/0x8e0 fs/attr.c:552
 vfs_utimes+0x2c6/0x3e0 fs/utimes.c:66
 do_utimes_path fs/utimes.c:99 [inline]
 do_utimes+0x149/0x1f0 fs/utimes.c:140
 __do_sys_utimensat fs/utimes.c:159 [inline]
 __se_sys_utimensat fs/utimes.c:143 [inline]
 __x64_sys_utimensat+0xc6/0x170 fs/utimes.c:143
 x64_sys_call+0x272a/0x2dc0 arch/x86/include/generated/asm/syscalls_64.h:281
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff88812358b82c of 4 bytes by task 3699 on cpu 1:
 inode_get_mtime_nsec include/linux/fs.h:1682 [inline]
 inode_get_mtime include/linux/fs.h:1688 [inline]
 generic_fillattr+0x205/0x330 fs/stat.c:102
 shmem_getattr+0x17b/0x200 mm/shmem.c:1249
 vfs_getattr_nosec fs/stat.c:208 [inline]
 vfs_getattr fs/stat.c:246 [inline]
 vfs_statx_path+0x171/0x2d0 fs/stat.c:283
 vfs_statx+0xe1/0x170 fs/stat.c:347
 vfs_fstatat fs/stat.c:366 [inline]
 __do_sys_newfstatat fs/stat.c:530 [inline]
 __se_sys_newfstatat+0xdc/0x300 fs/stat.c:524
 __x64_sys_newfstatat+0x55/0x70 fs/stat.c:524
 x64_sys_call+0x236d/0x2dc0 arch/x86/include/generated/asm/syscalls_64.h:263
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0x31dca96c -> 0x34b81a6f

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 3699 Comm: udevd Not tainted 6.14.0-rc1-syzkaller-00034-g92514ef226f5 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 12/27/2024
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/02/06 17:03 upstream 92514ef226f5 8002dd28 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in generic_fillattr / setattr_copy
* Struck through repros no longer work on HEAD.