KCSAN: data-race in __fsnotify_parent / fsnotify_recalc_mask

5 views
Skip to first unread message

syzbot

unread,
Dec 7, 2020, 6:58:10 AM12/7/20
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 407ab579 Merge tag 'for-linus' of git://git.kernel.org/pub..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=1587bb46500000
kernel config: https://syzkaller.appspot.com/x/.config?x=671e27f23e60a67b
dashboard link: https://syzkaller.appspot.com/bug?extid=d14081028b28694e3a5f
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project.git 913f6005669cfb590c99865a90bc51ed0983d09d)
CC: [amir...@gmail.com ja...@suse.cz linux-...@vger.kernel.org linux-...@vger.kernel.org]

Unfortunately, I don't have any reproducer for this issue yet.

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+d14081...@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in __fsnotify_parent / fsnotify_recalc_mask

write to 0xffff88810d3e7f2c of 4 bytes by task 10763 on cpu 1:
__fsnotify_recalc_mask fs/notify/mark.c:132 [inline]
fsnotify_recalc_mask+0x17d/0x1e0 fs/notify/mark.c:147
fsnotify_add_mark_locked+0x77a/0x950 fs/notify/mark.c:668
fsnotify_add_inode_mark_locked include/linux/fsnotify_backend.h:541 [inline]
inotify_new_watch fs/notify/inotify/inotify_user.c:592 [inline]
inotify_update_watch fs/notify/inotify/inotify_user.c:619 [inline]
__do_sys_inotify_add_watch fs/notify/inotify/inotify_user.c:757 [inline]
__se_sys_inotify_add_watch+0x527/0x660 fs/notify/inotify/inotify_user.c:700
__x64_sys_inotify_add_watch+0x3f/0x50 fs/notify/inotify/inotify_user.c:700
do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff88810d3e7f2c of 4 bytes by task 8461 on cpu 0:
fsnotify_event_needs_parent fs/notify/fsnotify.c:156 [inline]
__fsnotify_parent+0x132/0x460 fs/notify/fsnotify.c:196
fsnotify_parent include/linux/fsnotify.h:68 [inline]
fsnotify_file include/linux/fsnotify.h:90 [inline]
fsnotify_perm+0x296/0x2d0 include/linux/fsnotify.h:115
security_file_open+0x85/0x90 security/security.c:1579
do_dentry_open+0x22d/0x870 fs/open.c:804
vfs_open+0x43/0x50 fs/open.c:931
do_open fs/namei.c:3252 [inline]
path_openat+0x1844/0x20a0 fs/namei.c:3369
do_filp_open+0xbd/0x1d0 fs/namei.c:3396
do_sys_openat2+0xa3/0x240 fs/open.c:1168
do_sys_open fs/open.c:1184 [inline]
__do_sys_open fs/open.c:1192 [inline]
__se_sys_open fs/open.c:1188 [inline]
__x64_sys_open+0xe2/0x110 fs/open.c:1188
do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
entry_SYSCALL_64_after_hwframe+0x44/0xa9

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


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

syzbot

unread,
Dec 21, 2020, 6:59:08 AM12/21/20
to syzkaller-upst...@googlegroups.com
Auto-closing this bug as obsolete.
Crashes did not happen for a while, no reproducer and no activity.
Reply all
Reply to author
Forward
0 new messages