syzbot


KCSAN: data-race in kernfs_refresh_inode / tomoyo_realpath_from_path

Status: closed as invalid on 2019/11/19 14:44
Subsystems: kernfs
[Documentation on labels]
First crash: 1635d, last: 1627d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in kernfs_refresh_inode / tomoyo_realpath_from_path (2) tomoyo 3 1547d 1598d 0/26 auto-closed as invalid on 2020/04/07 01:15

Sample crash report:
==================================================================
BUG: KCSAN: data-race in kernfs_refresh_inode / tomoyo_realpath_from_path

write to 0xffff8880b98cbb68 of 2 bytes by task 2826 on cpu 1:
 kernfs_refresh_inode+0x42/0x140 fs/kernfs/inode.c:172
 kernfs_iop_getattr+0x68/0x90 fs/kernfs/inode.c:191
 vfs_getattr_nosec+0x12e/0x170 fs/stat.c:81
 vfs_getattr+0x54/0x70 fs/stat.c:118
 vfs_statx_fd+0x7a/0xd0 fs/stat.c:145
 vfs_fstat include/linux/fs.h:3258 [inline]
 __do_sys_newfstat+0x49/0xa0 fs/stat.c:378
 __se_sys_newfstat fs/stat.c:375 [inline]
 __x64_sys_newfstat+0x3a/0x50 fs/stat.c:375
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff8880b98cbb68 of 2 bytes by task 3889 on cpu 0:
 tomoyo_get_absolute_path security/tomoyo/realpath.c:104 [inline]
 tomoyo_realpath_from_path+0x441/0x4c0 security/tomoyo/realpath.c:304
 tomoyo_get_realpath security/tomoyo/file.c:151 [inline]
 tomoyo_path_perm+0x15d/0x390 security/tomoyo/file.c:822
 tomoyo_inode_getattr+0x26/0x40 security/tomoyo/tomoyo.c:129
 security_inode_getattr+0x9b/0xd0 security/security.c:1222
 vfs_getattr+0x2e/0x70 fs/stat.c:115
 vfs_statx+0x102/0x190 fs/stat.c:191
 vfs_stat include/linux/fs.h:3242 [inline]
 __do_sys_newstat+0x51/0xb0 fs/stat.c:341
 __se_sys_newstat fs/stat.c:337 [inline]
 __x64_sys_newstat+0x3a/0x50 fs/stat.c:337
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 3889 Comm: udevd Not tainted 5.4.0-rc6+ #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/11/09 00:50 https://github.com/google/ktsan.git kcsan 94c006602e13 1e35461e .config console log report ci2-upstream-kcsan-gce
2019/11/03 13:45 https://github.com/google/ktsan.git kcsan 05f2236801fe c9610487 .config console log report ci2-upstream-kcsan-gce
2019/11/01 19:18 https://github.com/google/ktsan.git kcsan 05f2236801fe 997ccc67 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.