syzbot


KCSAN: data-race in __fsnotify_recalc_mask / fsnotify

Status: closed as invalid on 2019/11/19 14:04
Subsystems: fs
[Documentation on labels]
First crash: 1625d, last: 1625d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __fsnotify_recalc_mask / fsnotify (3) fs 1 580d 580d 0/26 auto-obsoleted due to no activity on 2022/10/21 23:59
upstream KCSAN: data-race in __fsnotify_recalc_mask / fsnotify (2) fs 5 1514d 1594d 0/26 auto-closed as invalid on 2020/05/06 06:05

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __fsnotify_recalc_mask / fsnotify

read to 0xffff888102f565d4 of 4 bytes by task 14298 on cpu 1:
 fsnotify+0x17f/0x7d0 fs/notify/fsnotify.c:348
 fsnotify_path include/linux/fsnotify.h:54 [inline]
 fsnotify_path include/linux/fsnotify.h:47 [inline]
 fsnotify_perm include/linux/fsnotify.h:85 [inline]
 security_file_permission+0x1c7/0x280 security/security.c:1379
 rw_verify_area+0xe1/0x250 fs/read_write.c:399
 do_splice_to+0x6c/0x130 fs/splice.c:865
 splice_direct_to_actor+0x1a1/0x510 fs/splice.c:954
 do_splice_direct+0x161/0x1e0 fs/splice.c:1063
 do_sendfile+0x384/0x7f0 fs/read_write.c:1464
 __do_sys_sendfile64 fs/read_write.c:1525 [inline]
 __se_sys_sendfile64 fs/read_write.c:1511 [inline]
 __x64_sys_sendfile64+0x12a/0x140 fs/read_write.c:1511
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

write to 0xffff888102f565d4 of 4 bytes by task 8027 on cpu 0:
 __fsnotify_recalc_mask+0x152/0x1b0 fs/notify/mark.c:132
 fsnotify_recalc_mask.part.0+0x28/0x90 fs/notify/mark.c:147
 fsnotify_recalc_mask fs/notify/mark.c:143 [inline]
 fsnotify_add_mark_locked+0x77d/0x9b0 fs/notify/mark.c:664
 fsnotify_add_inode_mark_locked include/linux/fsnotify_backend.h:466 [inline]
 inotify_new_watch fs/notify/inotify/inotify_user.c:590 [inline]
 inotify_update_watch+0x343/0x3c0 fs/notify/inotify/inotify_user.c:617
 __do_sys_inotify_add_watch fs/notify/inotify/inotify_user.c:755 [inline]
 __se_sys_inotify_add_watch fs/notify/inotify/inotify_user.c:698 [inline]
 __x64_sys_inotify_add_watch+0x1f8/0x250 fs/notify/inotify/inotify_user.c:698
 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: 8027 Comm: udevd Not tainted 5.4.0-rc6+ #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
2019/11/07 15:15 https://github.com/google/ktsan.git kcsan 94c006602e13 d5bc6812 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.