syzbot


KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick (3)
Status: auto-closed as invalid on 2021/03/08 08:59
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 478d, last: 478d
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick (4) 1 410d 386d 0/22 auto-closed as invalid on 2021/05/18 19:52
upstream KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick (2) 2 571d 574d 0/22 auto-closed as invalid on 2020/12/05 18:11
upstream KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick 1 616d 616d 0/22 auto-closed as invalid on 2020/10/21 04:02

Sample crash report:
==================================================================
BUG: KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick

write to 0xffff88802f340ca0 of 4 bytes by task 30107 on cpu 1:
 kvm_arch_vcpu_load+0x423/0x590 arch/x86/kvm/x86.c:3999
 kvm_sched_in+0x57/0x60 arch/x86/kvm/../../../virt/kvm/kvm_main.c:4831
 __fire_sched_in_preempt_notifiers kernel/sched/core.c:3911 [inline]
 fire_sched_in_preempt_notifiers kernel/sched/core.c:3917 [inline]
 finish_task_switch+0x278/0x2a0 kernel/sched/core.c:4208
 context_switch kernel/sched/core.c:4330 [inline]
 __schedule+0x3c1/0x580 kernel/sched/core.c:5078
 schedule+0x7f/0xb0 kernel/sched/core.c:5157
 xfer_to_guest_mode_work kernel/entry/kvm.c:20 [inline]
 xfer_to_guest_mode_handle_work+0x87/0x170 kernel/entry/kvm.c:50
 vcpu_run+0x547/0x690 arch/x86/kvm/x86.c:9169
 kvm_arch_vcpu_ioctl_run+0x466/0x850 arch/x86/kvm/x86.c:9374
 kvm_vcpu_ioctl+0x562/0x8f0 arch/x86/kvm/../../../virt/kvm/kvm_main.c:3283
 vfs_ioctl fs/ioctl.c:48 [inline]
 __do_sys_ioctl fs/ioctl.c:753 [inline]
 __se_sys_ioctl+0xcb/0x140 fs/ioctl.c:739
 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:739
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff88802f340ca0 of 4 bytes by task 7 on cpu 0:
 kvm_vcpu_kick+0x15/0x160 arch/x86/kvm/../../../virt/kvm/kvm_main.c:2876
 kvm_arch_async_page_present_queued+0x43/0x50 arch/x86/kvm/x86.c:11120
 async_pf_execute+0x1d3/0x300 arch/x86/kvm/../../../virt/kvm/async_pf.c:79
 process_one_work+0x3e1/0x950 kernel/workqueue.c:2275
 worker_thread+0x616/0xa70 kernel/workqueue.c:2421
 kthread+0x20b/0x230 kernel/kthread.c:292
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 7 Comm: kworker/0:1 Not tainted 5.11.0-rc6-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: events async_pf_execute
==================================================================

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2021/02/01 08:56 upstream 1048ba83fb1c fc9fd31e .config log report info KCSAN: data-race in kvm_arch_vcpu_load / kvm_vcpu_kick