================================================================== BUG: KASAN: slab-out-of-bounds in handle_vmptrld arch/x86/kvm/vmx/nested.c:4789 [inline] BUG: KASAN: slab-out-of-bounds in handle_vmptrld+0x777/0x800 arch/x86/kvm/vmx/nested.c:4749 Read of size 4 at addr ffff8880588dc000 by task syz-executor.0/20853 CPU: 0 PID: 20853 Comm: syz-executor.0 Not tainted 5.3.0-rc7+ #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.cold+0xd4/0x306 mm/kasan/report.c:351 __kasan_report.cold+0x1b/0x36 mm/kasan/report.c:482 kasan_report+0x12/0x17 mm/kasan/common.c:618 __asan_report_load_n_noabort+0xf/0x20 mm/kasan/generic_report.c:142 handle_vmptrld arch/x86/kvm/vmx/nested.c:4789 [inline] handle_vmptrld+0x777/0x800 arch/x86/kvm/vmx/nested.c:4749 vmx_handle_exit+0x299/0x15e0 arch/x86/kvm/vmx/vmx.c:5886 vcpu_enter_guest+0x1087/0x5e90 arch/x86/kvm/x86.c:8088 vcpu_run arch/x86/kvm/x86.c:8152 [inline] kvm_arch_vcpu_ioctl_run+0x464/0x1750 arch/x86/kvm/x86.c:8360 kvm_vcpu_ioctl+0x4dc/0xfd0 arch/x86/kvm/../../../virt/kvm/kvm_main.c:2765 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:509 [inline] do_vfs_ioctl+0xdb6/0x13e0 fs/ioctl.c:696 ksys_ioctl+0xab/0xd0 fs/ioctl.c:713 __do_sys_ioctl fs/ioctl.c:720 [inline] __se_sys_ioctl fs/ioctl.c:718 [inline] __x64_sys_ioctl+0x73/0xb0 fs/ioctl.c:718 do_syscall_64+0xfd/0x6a0 arch/x86/entry/common.c:296 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x4598e9 Code: fd b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 cb b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f86362a3c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00000000004598e9 RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000005 RBP: 000000000075bfc8 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f86362a46d4 R13: 00000000004c2c68 R14: 00000000004d6330 R15: 00000000ffffffff Allocated by task 20895: save_stack+0x23/0x90 mm/kasan/common.c:69 set_track mm/kasan/common.c:77 [inline] __kasan_kmalloc mm/kasan/common.c:493 [inline] __kasan_kmalloc.constprop.0+0xcf/0xe0 mm/kasan/common.c:466 kasan_kmalloc+0x9/0x10 mm/kasan/common.c:507 __do_kmalloc mm/slab.c:3655 [inline] __kmalloc+0x163/0x770 mm/slab.c:3664 kmalloc include/linux/slab.h:557 [inline] hcd_buffer_alloc+0x1c6/0x260 drivers/usb/core/buffer.c:132 usb_alloc_coherent+0x62/0x90 drivers/usb/core/usb.c:910 usbdev_mmap+0x1ce/0x790 drivers/usb/core/devio.c:224 call_mmap include/linux/fs.h:1875 [inline] mmap_region+0xc35/0x1760 mm/mmap.c:1788 do_mmap+0x82e/0x1090 mm/mmap.c:1561 do_mmap_pgoff include/linux/mm.h:2374 [inline] vm_mmap_pgoff+0x1c5/0x230 mm/util.c:391 ksys_mmap_pgoff+0x4aa/0x630 mm/mmap.c:1611 __do_sys_mmap arch/x86/kernel/sys_x86_64.c:100 [inline] __se_sys_mmap arch/x86/kernel/sys_x86_64.c:91 [inline] __x64_sys_mmap+0xe9/0x1b0 arch/x86/kernel/sys_x86_64.c:91 do_syscall_64+0xfd/0x6a0 arch/x86/entry/common.c:296 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 14286: save_stack+0x23/0x90 mm/kasan/common.c:69 set_track mm/kasan/common.c:77 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:455 kasan_slab_free+0xe/0x10 mm/kasan/common.c:463 __cache_free mm/slab.c:3425 [inline] kfree+0x10a/0x2c0 mm/slab.c:3756 kvfree+0x61/0x70 mm/util.c:488 ptr_ring_cleanup include/linux/ptr_ring.h:670 [inline] __tun_detach+0x9d3/0x1040 drivers/net/tun.c:727 tun_detach drivers/net/tun.c:740 [inline] tun_chr_close+0xe0/0x180 drivers/net/tun.c:3442 __fput+0x2ff/0x890 fs/file_table.c:280 ____fput+0x16/0x20 fs/file_table.c:313 task_work_run+0x145/0x1c0 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:188 [inline] exit_to_usermode_loop+0x316/0x380 arch/x86/entry/common.c:163 prepare_exit_to_usermode arch/x86/entry/common.c:194 [inline] syscall_return_slowpath arch/x86/entry/common.c:274 [inline] do_syscall_64+0x5a9/0x6a0 arch/x86/entry/common.c:299 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff8880588dc700 which belongs to the cache kmalloc-8k of size 8192 The buggy address is located 1792 bytes to the left of 8192-byte region [ffff8880588dc700, ffff8880588de700) The buggy address belongs to the page: page:ffffea0001623700 refcount:2 mapcount:0 mapping:ffff8880aa4021c0 index:0x0 compound_mapcount: 0 flags: 0x1fffc0000010200(slab|head) raw: 01fffc0000010200 ffffea00011b0a08 ffff8880aa401b48 ffff8880aa4021c0 raw: 0000000000000000 ffff8880588dc700 0000000200000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880588dbf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880588dbf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff8880588dc000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880588dc080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880588dc100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================