================================================================== BUG: KASAN: null-ptr-deref in memset include/linux/string.h:332 [inline] BUG: KASAN: null-ptr-deref in kvm_write_guest_virt_system+0x64/0x90 arch/x86/kvm/x86.c:4730 Write of size 24 at addr (null) by task syz-executor.5/11087 CPU: 1 PID: 11087 Comm: syz-executor.5 Not tainted 4.14.146 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x138/0x197 lib/dump_stack.c:53 kasan_report_error mm/kasan/report.c:349 [inline] kasan_report mm/kasan/report.c:409 [inline] kasan_report.cold+0x127/0x2af mm/kasan/report.c:393 check_memory_region_inline mm/kasan/kasan.c:260 [inline] check_memory_region+0x123/0x190 mm/kasan/kasan.c:267 memset+0x24/0x40 mm/kasan/kasan.c:285 memset include/linux/string.h:332 [inline] kvm_write_guest_virt_system+0x64/0x90 arch/x86/kvm/x86.c:4730 handle_vmread+0x548/0x730 arch/x86/kvm/vmx.c:8027 vmx_handle_exit+0x20d/0x1330 arch/x86/kvm/vmx.c:9203 vcpu_enter_guest+0xf28/0x5210 arch/x86/kvm/x86.c:7247 vcpu_run arch/x86/kvm/x86.c:7310 [inline] kvm_arch_vcpu_ioctl_run+0x318/0x1000 arch/x86/kvm/x86.c:7477 kvm_vcpu_ioctl+0x401/0xd10 arch/x86/kvm/../../../virt/kvm/kvm_main.c:2611 audit: type=1800 audit(1570064827.784:98): pid=11104 uid=0 auid=4294967295 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 op="collect_data" cause="failed(directio)" comm="syz-executor.3" name="file0" dev="sda1" ino=17539 res=0 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:500 [inline] do_vfs_ioctl+0x7ae/0x1060 fs/ioctl.c:684 SYSC_ioctl fs/ioctl.c:701 [inline] SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692 do_syscall_64+0x1e8/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x459a29 RSP: 002b:00007fb420b4ac78 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 0000000000459a29 RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000009 RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007fb420b4b6d4 R13: 00000000004c2ddb R14: 00000000004d68f8 R15: 00000000ffffffff ==================================================================