syzbot


KCSAN: data-race in check_mmio_spte / kvm_set_memslot (3)

Status: auto-closed as invalid on 2020/12/28 17:11
Reported-by: syzbot+1b79c9c4f558970278ed@syzkaller.appspotmail.com
First crash: 740d, last: 735d
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in check_mmio_spte / kvm_set_memslot (4) 1 675d 675d 0/24 auto-closed as invalid on 2021/02/26 09:27
upstream KCSAN: data-race in check_mmio_spte / kvm_set_memslot 2 840d 855d 0/24 auto-closed as invalid on 2020/09/14 12:48
upstream KCSAN: data-race in check_mmio_spte / kvm_set_memslot (2) 2 792d 800d 0/24 auto-closed as invalid on 2020/11/01 14:13

Sample crash report:
==================================================================
BUG: KCSAN: data-race in check_mmio_spte / kvm_set_memslot

write to 0xffff88801be7d800 of 8 bytes by task 25233 on cpu 1:
 install_new_memslots arch/x86/kvm/../../../virt/kvm/kvm_main.c:1146 [inline]
 kvm_set_memslot+0x945/0xa00 arch/x86/kvm/../../../virt/kvm/kvm_main.c:1222
 __kvm_set_memory_region+0x708/0x910 arch/x86/kvm/../../../virt/kvm/kvm_main.c:1374
 kvm_set_memory_region arch/x86/kvm/../../../virt/kvm/kvm_main.c:1395 [inline]
 kvm_vm_ioctl_set_memory_region arch/x86/kvm/../../../virt/kvm/kvm_main.c:1407 [inline]
 kvm_vm_ioctl+0x822/0x17d0 arch/x86/kvm/../../../virt/kvm/kvm_main.c:3708
 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 0xffff88801be7d800 of 8 bytes by task 25226 on cpu 0:
 check_mmio_spte+0x58/0x160 arch/x86/kvm/mmu/mmu.c:254
 handle_mmio_page_fault+0x64c/0x890 arch/x86/kvm/mmu/mmu.c:3579
 kvm_mmu_page_fault+0x348/0x3c0 arch/x86/kvm/mmu/mmu.c:5053
 handle_ept_misconfig+0x96/0x150 arch/x86/kvm/vmx/vmx.c:5375
 vmx_handle_exit+0x2fd/0x7e0 arch/x86/kvm/vmx/vmx.c:6068
 vcpu_enter_guest+0x1978/0x2390 arch/x86/kvm/x86.c:9025
 vcpu_run+0x26e/0x730 arch/x86/kvm/x86.c:9090
 kvm_arch_vcpu_ioctl_run+0x362/0x660 arch/x86/kvm/x86.c:9307
 kvm_vcpu_ioctl+0x562/0x8f0 arch/x86/kvm/../../../virt/kvm/kvm_main.c:3234
 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

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

Crashes (3):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2020/11/23 17:10 upstream 418baf2c28f3 878fb17a .config log report info
ci2-upstream-kcsan-gce 2020/11/20 17:08 upstream 4d02da974ea8 68068804 .config log report info
ci2-upstream-kcsan-gce 2020/11/17 21:08 upstream 111e91a6df50 bd2a760b .config log report info
* Struck through repros no longer work on HEAD.