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

5 views
Skip to first unread message

syzbot

unread,
Dec 7, 2020, 6:50:12 AM12/7/20
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 9dbc1c03 Merge tag 'xfs-5.10-fixes-3' of git://git.kernel...
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=16921f32500000
kernel config: https://syzkaller.appspot.com/x/.config?x=31a046454060d678
dashboard link: https://syzkaller.appspot.com/bug?extid=c6da4365afd3f07abdc3
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project.git 913f6005669cfb590c99865a90bc51ed0983d09d)
CC: [k...@vger.kernel.org linux-...@vger.kernel.org pbon...@redhat.com]

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+c6da43...@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in kvm_set_memslot / vcpu_mmio_gva_to_gpa

write to 0xffff888024d55000 of 8 bytes by task 6237 on cpu 0:
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 0xffff888024d55000 of 8 bytes by task 6221 on cpu 1:
vcpu_match_mmio_gen arch/x86/kvm/x86.h:189 [inline]
vcpu_match_mmio_gpa arch/x86/kvm/x86.h:217 [inline]
vcpu_is_mmio_gpa arch/x86/kvm/x86.c:6038 [inline]
vcpu_mmio_gva_to_gpa+0x2c8/0x540 arch/x86/kvm/x86.c:6072
emulator_read_write_onepage+0xfd/0x490 arch/x86/kvm/x86.c:6183
emulator_read_write+0x173/0x310 arch/x86/kvm/x86.c:6243
emulator_read_emulated+0x37/0x40 arch/x86/kvm/x86.c:6270
read_emulated arch/x86/kvm/emulate.c:1457 [inline]
segmented_read arch/x86/kvm/emulate.c:1481 [inline]
emulate_pop+0x214/0x410 arch/x86/kvm/emulate.c:1909
em_ret_far+0x9d/0x2b0 arch/x86/kvm/emulate.c:2311
em_ret_far_imm+0x2c/0x1c0 arch/x86/kvm/emulate.c:2334
x86_emulate_insn+0x9d9/0x3060 arch/x86/kvm/emulate.c:5702
x86_emulate_instruction+0x74f/0x2ac0 arch/x86/kvm/x86.c:7350
kvm_mmu_page_fault+0x315/0x3c0 arch/x86/kvm/mmu/mmu.c:5095
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:8987
vcpu_run+0x26e/0x730 arch/x86/kvm/x86.c:9052
kvm_arch_vcpu_ioctl_run+0x362/0x660 arch/x86/kvm/x86.c:9269
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: 1 PID: 6221 Comm: syz-executor.1 Not tainted 5.10.0-rc2-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================


---
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,
Dec 21, 2020, 6:51:09 AM12/21/20
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