syzbot


KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa (4)

Status: auto-closed as invalid on 2021/03/08 13:59
Subsystems: kvm
[Documentation on labels]
First crash: 1173d, last: 1173d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa (2) kvm 1 1356d 1356d 0/26 auto-closed as invalid on 2020/09/06 22:08
upstream KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa kvm 1 1399d 1399d 0/26 auto-closed as invalid on 2020/07/25 12:23
upstream KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa (3) kvm 2 1258d 1229d 0/26 auto-closed as invalid on 2020/12/21 11:51

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

write to 0xffff88801d353800 of 8 bytes by task 6365 on cpu 1:
 install_new_memslots arch/x86/kvm/../../../virt/kvm/kvm_main.c:1148 [inline]
 kvm_set_memslot+0x958/0xa10 arch/x86/kvm/../../../virt/kvm/kvm_main.c:1224
 __kvm_set_memory_region+0x794/0x930 arch/x86/kvm/../../../virt/kvm/kvm_main.c:1377
 kvm_set_memory_region arch/x86/kvm/../../../virt/kvm/kvm_main.c:1398 [inline]
 kvm_vm_ioctl_set_memory_region arch/x86/kvm/../../../virt/kvm/kvm_main.c:1410 [inline]
 kvm_vm_ioctl+0xacb/0x1c40 arch/x86/kvm/../../../virt/kvm/kvm_main.c:3825
 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 0xffff88801d353800 of 8 bytes by task 6355 on cpu 0:
 vcpu_match_mmio_gen arch/x86/kvm/x86.h:190 [inline]
 vcpu_match_mmio_gva arch/x86/kvm/x86.h:209 [inline]
 vcpu_mmio_gva_to_gpa+0x9d/0x540 arch/x86/kvm/x86.c:6125
 emulator_read_write_onepage+0xfd/0x490 arch/x86/kvm/x86.c:6250
 emulator_read_write+0x173/0x310 arch/x86/kvm/x86.c:6310
 emulator_read_emulated+0x37/0x40 arch/x86/kvm/x86.c:6337
 read_emulated arch/x86/kvm/emulate.c:1457 [inline]
 segmented_read arch/x86/kvm/emulate.c:1481 [inline]
 emulate_pop+0x210/0x420 arch/x86/kvm/emulate.c:1909
 em_pop_sreg+0x47/0x320 arch/x86/kvm/emulate.c:2020
 x86_emulate_insn+0xa0e/0x2c30 arch/x86/kvm/emulate.c:5708
 x86_emulate_instruction+0x76f/0x2a10 arch/x86/kvm/x86.c:7417
 kvm_mmu_page_fault+0x315/0x3c0 arch/x86/kvm/mmu/mmu.c:5112
 handle_ept_misconfig+0x96/0x150 arch/x86/kvm/vmx/vmx.c:5355
 vmx_handle_exit+0x2fd/0x800 arch/x86/kvm/vmx/vmx.c:6048
 vcpu_enter_guest+0x1a2b/0x2470 arch/x86/kvm/x86.c:9081
 vcpu_run+0x24e/0x690 arch/x86/kvm/x86.c:9147
 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

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 6355 Comm: syz-executor.1 Not tainted 5.11.0-rc6-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/02/01 13:53 upstream 1048ba83fb1c e6b95f32 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa
* Struck through repros no longer work on HEAD.