syzbot


KCSAN: data-race in __d_rehash / retain_dentry

Status: auto-closed as invalid on 2021/06/05 04:33
Subsystems: fs
[Documentation on labels]
First crash: 1090d, last: 1090d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __d_rehash / retain_dentry (2) fs 1 688d 686d 0/26 auto-closed as invalid on 2022/07/12 06:48
upstream KCSAN: data-race in __d_rehash / retain_dentry (4) fs 2 243d 261d 0/26 auto-obsoleted due to no activity on 2023/09/29 23:13
upstream KCSAN: data-race in __d_rehash / retain_dentry (3) fs 1 338d 338d 0/26 auto-obsoleted due to no activity on 2023/06/26 14:48
upstream KCSAN: data-race in __d_rehash / retain_dentry (5) ext4 1 128d 128d 0/26 auto-obsoleted due to no activity on 2024/01/23 04:25

Sample crash report:
cgroup: Unknown subsys name 'perf_event'
cgroup: Unknown subsys name 'net_cls'
==================================================================
BUG: KCSAN: data-race in __d_rehash / retain_dentry

write to 0xffff888105c1b910 of 8 bytes by task 1758 on cpu 0:
 hlist_bl_add_head_rcu include/linux/rculist_bl.h:81 [inline]
 __d_rehash+0xaf/0x180 fs/dcache.c:2517
 __d_add+0x345/0x490 fs/dcache.c:2711
 d_splice_alias+0xd9/0x4f0 fs/dcache.c:3098
 proc_sys_lookup+0x421/0x550 fs/proc/proc_sysctl.c:530
 lookup_open fs/namei.c:3193 [inline]
 open_last_lookups fs/namei.c:3285 [inline]
 path_openat+0xb5a/0x20b0 fs/namei.c:3491
 do_filp_open+0xd9/0x1f0 fs/namei.c:3521
 do_sys_openat2+0xa3/0x250 fs/open.c:1187
 do_sys_open fs/open.c:1203 [inline]
 __do_sys_openat fs/open.c:1219 [inline]
 __se_sys_openat fs/open.c:1214 [inline]
 __x64_sys_openat+0xef/0x110 fs/open.c:1214
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff888105c1b910 of 8 bytes by task 1759 on cpu 1:
 hlist_bl_unhashed include/linux/list_bl.h:54 [inline]
 d_unhashed include/linux/dcache.h:341 [inline]
 retain_dentry+0x42/0x260 fs/dcache.c:641
 dput+0x3d/0x360 fs/dcache.c:881
 __fput+0x3ab/0x4e0 fs/file_table.c:293
 ____fput+0x11/0x20 fs/file_table.c:313
 task_work_run+0xae/0x130 kernel/task_work.c:161
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x156/0x190 kernel/entry/common.c:208
 __syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline]
 syscall_exit_to_user_mode+0x20/0x40 kernel/entry/common.c:301
 do_syscall_64+0x56/0x90 arch/x86/entry/common.c:57
 entry_SYSCALL_64_after_hwframe+0x44/0xae

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 1759 Comm: syz-executor.1 Not tainted 5.12.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/05/01 04:26 upstream 65c61de9d090 77e2b668 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / retain_dentry
* Struck through repros no longer work on HEAD.