KCSAN: data-race in __fsnotify_parent / fsnotify_put_mark

4 views
Skip to first unread message

syzbot

unread,
Nov 12, 2020, 6:07:27 AM11/12/20
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: eccc8767 Merge branch 'fixes' of git://git.kernel.org/pub/..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=146a2cfa500000
kernel config: https://syzkaller.appspot.com/x/.config?x=671e27f23e60a67b
dashboard link: https://syzkaller.appspot.com/bug?extid=97ac81fbea69845bf00a
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+97ac81...@syzkaller.appspotmail.com

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

write to 0xffff88810243ac5c of 4 bytes by task 11202 on cpu 0:
fsnotify_detach_connector_from_object fs/notify/mark.c:184 [inline]
fsnotify_put_mark+0x287/0x610 fs/notify/mark.c:250
__do_sys_inotify_rm_watch fs/notify/inotify/inotify_user.c:790 [inline]
__se_sys_inotify_rm_watch+0xff/0x170 fs/notify/inotify/inotify_user.c:764
__x64_sys_inotify_rm_watch+0x2d/0x40 fs/notify/inotify/inotify_user.c:764
do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff88810243ac5c of 4 bytes by task 4901 on cpu 1:
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_open include/linux/fsnotify.h:268 [inline]
do_sys_openat2+0x1d9/0x240 fs/open.c:1173
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: 1 PID: 4901 Comm: systemd-udevd Not tainted 5.10.0-rc3-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================
Kernel panic - not syncing: panic_on_warn set ...
CPU: 1 PID: 4901 Comm: systemd-udevd Not tainted 5.10.0-rc3-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x116/0x15d lib/dump_stack.c:118
panic+0x1e7/0x5fa kernel/panic.c:231
kcsan_report+0x67b/0x680 kernel/kcsan/report.c:634
kcsan_setup_watchpoint+0x46a/0x4d0 kernel/kcsan/core.c:568
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_open include/linux/fsnotify.h:268 [inline]
do_sys_openat2+0x1d9/0x240 fs/open.c:1173
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
RIP: 0033:0x7f80007a8840
Code: 73 01 c3 48 8b 0d 68 77 20 00 f7 d8 64 89 01 48 83 c8 ff c3 66 0f 1f 44 00 00 83 3d 89 bb 20 00 00 75 10 b8 02 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 1e f6 ff ff 48 89 04 24
RSP: 002b:00007fff459c0f78 EFLAGS: 00000246 ORIG_RAX: 0000000000000002
RAX: ffffffffffffffda RBX: 00007fff459c1020 RCX: 00007f80007a8840
RDX: 000055a4bd0fbfe3 RSI: 00000000000a0800 RDI: 000055a4bd940950
RBP: 00007fff459c1500 R08: 000055a4bd0fb670 R09: 0000000000000010
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fff459c1120
R13: 000055a4bd929010 R14: 000055a4bd92a380 R15: 00007fff459c0ff0
Kernel Offset: disabled
Rebooting in 86400 seconds..


---
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,
Jun 30, 2022, 6:31:19 AM6/30/22
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