[moderation] [perf?] KCSAN: data-race in perf_event_set_state / perf_event_update_userpage

1 view
Skip to first unread message

syzbot

unread,
Mar 5, 2024, 6:19:26 AMMar 5
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 90d35da658da Linux 6.8-rc7
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=132de3ca180000
kernel config: https://syzkaller.appspot.com/x/.config?x=f10ff55d327ef698
dashboard link: https://syzkaller.appspot.com/bug?extid=2c739cbfe7a7fa3f02ef
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [ac...@kernel.org adrian...@intel.com alexander...@linux.intel.com iro...@google.com jo...@kernel.org linux-...@vger.kernel.org linux-pe...@vger.kernel.org mark.r...@arm.com mi...@redhat.com namh...@kernel.org pet...@infradead.org]

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

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/db68fe219e77/disk-90d35da6.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/feb8e6632739/vmlinux-90d35da6.xz
kernel image: https://storage.googleapis.com/syzbot-assets/0c6e98b6523c/bzImage-90d35da6.xz

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

==================================================================
BUG: KCSAN: data-race in perf_event_set_state / perf_event_update_userpage

write to 0xffff88814212c4f8 of 8 bytes by task 533 on cpu 0:
perf_event_update_time kernel/events/core.c:641 [inline]
perf_event_set_state+0x1a1/0x3f0 kernel/events/core.c:660
event_sched_out+0x421/0x5f0 kernel/events/core.c:2301
group_sched_out kernel/events/core.c:2323 [inline]
__pmu_ctx_sched_out+0x386/0x4a0 kernel/events/core.c:3268
ctx_sched_out+0x2b1/0x310 kernel/events/core.c:3337
task_ctx_sched_out kernel/events/core.c:2669 [inline]
ctx_resched+0x1e0/0x3e0 kernel/events/core.c:2721
__perf_install_in_context+0x323/0x380 kernel/events/core.c:2807
remote_function+0x9a/0xb0 kernel/events/core.c:92
csd_do_func kernel/smp.c:133 [inline]
generic_exec_single+0xc9/0x390 kernel/smp.c:404
smp_call_function_single+0x15c/0x2e0 kernel/smp.c:647
task_function_call kernel/events/core.c:120 [inline]
perf_install_in_context+0x2f1/0x460 kernel/events/core.c:2909
__do_sys_perf_event_open kernel/events/core.c:12768 [inline]
__se_sys_perf_event_open+0x1f62/0x2170 kernel/events/core.c:12420
__x64_sys_perf_event_open+0x67/0x80 kernel/events/core.c:12420
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xcd/0x1d0 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x63/0x6b

read to 0xffff88814212c4f8 of 8 bytes by task 534 on cpu 1:
__perf_update_times kernel/events/core.c:632 [inline]
calc_timer_values kernel/events/core.c:4550 [inline]
perf_event_update_userpage+0x1f5/0x450 kernel/events/core.c:6124
perf_mmap+0xa46/0xcb0 kernel/events/core.c:6620
call_mmap include/linux/fs.h:2092 [inline]
mmap_region+0x9a6/0x1640 mm/mmap.c:2821
do_mmap+0x6a5/0xab0 mm/mmap.c:1379
vm_mmap_pgoff+0x12e/0x240 mm/util.c:556
ksys_mmap_pgoff+0x2b8/0x330 mm/mmap.c:1425
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xcd/0x1d0 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x63/0x6b

value changed: 0x0000000000436417 -> 0x0000000000449802

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 534 Comm: syz-executor.4 Not tainted 6.8.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024
==================================================================


---
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.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Apr 9, 2024, 7:19:13 AMApr 9
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